6
[solved] nix build error /homeless-shelter
(lemmy.one)
Either pick a build image that doesn't have /homeless-shelter
, like nixos/nix, or remove it with something like:
# UNTESTED
RUN rmdir /homeless-shelter
The root cause is that your build filesystem is dirty. When Nix sandboxes a build, it runs the builders as nobody
, a permissionless user with no home directory. On Linux, users with no home directory get their $HOME
set to /homeless-shelter
, and Nix relies on this directory not existing.
That's the weird thing I've run up the image and the directory isn't there. I did try a similar command in my ci.yml but it didn't work.
Do you know why that directory exists? Is there a reason you can't just delete it?
Nope but I've loaded up the image it's running and the directory isn't there.