File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ COPY package.json /usr/src/cloudcmd/
99
1010ENV DEBIAN_FRONTEND = noninteractive
1111ENV PATH =/ usr/ local/ src/ cargo/ bin:$PATH
12+ ENV NIX_NO_SANDBOX = 1
1213
1314ARG 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 && \
You can’t perform that action at this time.
0 commit comments