Skip to content

Commit

Permalink
[docker] fix for devbox docker image root-user build (#1811)
Browse files Browse the repository at this point in the history
## Summary
This fix is due to customer message in discord mentioning the launcher
having old version.
Nix installation in `docker-image-build-publish` workflow was failing
for root-user mode.
This PR fixes it.
The fix was based on recommendation from
LnL7/nix-docker#41 (comment)

## How was it tested?
https://github.com/jetpack-io/devbox/actions/runs/7893709911
  • Loading branch information
mohsenari authored Feb 15, 2024
1 parent 821906b commit caba63c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion internal/devbox/generate/tmpl/DevboxImageDockerfileRootUser
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ RUN apt-get update
RUN apt-get -y install bash binutils git xz-utils wget sudo

# Step 2: Installing Nix
RUN wget --output-document=/dev/stdout https://nixos.org/nix/install | sh -s -- --daemon
RUN mkdir -p /etc/nix/
RUN echo "filter-syscalls = false" >> /etc/nix/nix.conf && wget --output-document=/dev/stdout https://nixos.org/nix/install | sh -s -- --daemon
RUN . ~/.nix-profile/etc/profile.d/nix.sh

ENV PATH="/root/.nix-profile/bin:$PATH"
Expand Down

0 comments on commit caba63c

Please sign in to comment.