Skip to content

Commit e3cef21

Browse files
committed
feature: docker: io: apt-get upgrade
1 parent 582b742 commit e3cef21

1 file changed

Lines changed: 8 additions & 4 deletions

File tree

docker/Dockerfile.io

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ COPY package.json /usr/src/cloudcmd/
99

1010
ENV DEBIAN_FRONTEND=noninteractive
1111
ENV PATH=/usr/local/src/cargo/bin:$PATH
12+
ENV NIX_NO_SANDBOX=1
1213

1314
ARG GO_VERSION=1.21.2
1415

@@ -21,12 +22,15 @@ RUN apt-get update && apt-get upgrade -y && apt-get autoremove && \
2122
rm -rf /var/lib/apt/lists/* && \
2223
echo "> install nix" && \
2324
useradd -m -s /bin/bash nixuser && \
24-
echo "nixuser ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/nixuser && \
25-
chmod 0440 /etc/sudoers.d/nixuser && \
26-
su - nixuser -c "curl -L https://nixos.org/nix/install | sh -s -- --no-daemon --no-sendbox" && \
25+
mkdir /nix && \
26+
chown nixuser /nix && \
27+
su - nixuser && \
28+
mkdir -p ~/.config/nix && \
29+
echo "sandbox = false" > ~/.config/nix/nix.conf && \
30+
sh <(curl -L https://nixos.org/nix/install) --no-daemon && \
31+
exit && \
2732
mv /home/nixuser/.nix-profile /usr/local/src/nix-profile && \
2833
mv /home/nixuser/.nix-defexpr /usr/local/src/nix-defexpr && \
29-
rm -rf /etc/sudoers.d/nixuser && \
3034
userdel -r nixuser && \
3135
echo "> install nvm" && \
3236
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.4/install.sh | bash && \

0 commit comments

Comments
 (0)