daemonix approach
This commit is contained in:
parent
8d362d13b2
commit
d4e84b0e41
7 changed files with 48 additions and 38 deletions
13
files/system/usr/bin/mount-nix-overlay.sh
Executable file
13
files/system/usr/bin/mount-nix-overlay.sh
Executable file
|
|
@ -0,0 +1,13 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
mkdir -p /usr/share/nix-store /var/lib/nix-store /var/cache/nix-store /nix
|
||||
|
||||
# Skip if already mounted to avoid errors on reload.
|
||||
if mountpoint -q /nix; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
mount -t overlay overlay \
|
||||
-o lowerdir=/usr/share/nix-store,upperdir=/var/lib/nix-store,workdir=/var/cache/nix-store \
|
||||
/nix
|
||||
Loading…
Add table
Add a link
Reference in a new issue