-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Nix Installer: "cannot set host name: Operation not permitted" in WSL2 + podman + QEMU while building alpine-based minimal nix image #11810
Comments
The error stack in your output is from Nix itself, so I'm fairly sure the answer is that the installer itself isn't directly doing this. It looks like the error comes from here: nix/src/libstore/unix/build/local-derivation-goal.cc Lines 1840 to 1843 in dfd0033
|
Thanks a lot for this hint. When I omit the If it would be "installing 'nix-2.24.10'
error:
… while setting up the build environment
error: cannot set host name: Operation not permitted
---- oh no! --------------------------------------------------------------------
Oh no, something went wrong. If you can take all the output and open
an issue, we'd love to fix the problem so nobody else has this issue.
:(
We'd love to help if you need it.
You can open an issue at
https://github.com/NixOS/nix/issues/new?labels=installer&template=installer.md
Or get in touch with the community: https://nixos.org/community
Error: building at STEP "RUN sh <(curl -L https://nixos.org/nix/install) --daemon --yes": while running runtime: exit status 1" |
For some more context and a repo with reproducible example, https://github.com/rstats-on-nix/r-minimal-alpine |
Platform
Additional information
While trying to build a minimal alpine container with multiuser and nix-daemon setup via podman,
the official installer fails when I try to build this image on WSL2 Ubuntu via QEMU, but not on aarch64-darwin via vfkit, where it perfectly builds until the installer step (only nix-shell currently doesn't run because of permissions issue, but that is not relevant here).
I have this
nix-shell
env:Part of this build script.
build_container.sh
This is the image I'm trying to build:
entrypoint.sh
nix-daemon.sh
Output
Output
Linux HYBDk5ilQDH1in3 5.15.153.1-microsoft-standard-WSL2 #1 SMP Fri Mar 29 23:14:13 UTC 2024 x86_64 GNU/Linux
Windows 10 Enterprise
Version 10.0.19045 Build 19045
Guesses
Priorities
Add 👍 to issues you find important.
The text was updated successfully, but these errors were encountered: