forked from clan/clan-core
Merge pull request 'fix fake-etc build on machines without sandbox' (#1645) from fix-macos-deploy into main
This commit is contained in:
commit
f4283982b3
@ -123,13 +123,23 @@
|
|||||||
|
|
||||||
# prepare sandbox user
|
# prepare sandbox user
|
||||||
mkdir -p /etc
|
mkdir -p /etc
|
||||||
cp ${
|
|
||||||
pkgs.runCommand "fake-etc" { } ''
|
cat > /etc/group <<EOF
|
||||||
export PATH="${pkgs.coreutils}/bin"
|
root:x:0:
|
||||||
mkdir -p $out
|
nixbld:!:$(id -g):
|
||||||
cp /etc/* $out/
|
nogroup:x:65534:
|
||||||
''
|
EOF
|
||||||
}/* /etc/
|
|
||||||
|
cat > /etc/passwd <<EOF
|
||||||
|
root:x:0:0:Nix build user:/build:/noshell
|
||||||
|
nixbld:x:$(id -u):$(id -g):Nix build user:/build:/noshell
|
||||||
|
nobody:x:65534:65534:Nobody:/:/noshell
|
||||||
|
EOF
|
||||||
|
|
||||||
|
cat > /etc/hosts <<EOF
|
||||||
|
127.0.0.1 localhost
|
||||||
|
::1 localhost
|
||||||
|
EOF
|
||||||
|
|
||||||
${config.script}
|
${config.script}
|
||||||
'';
|
'';
|
||||||
|
Loading…
Reference in New Issue
Block a user