nftables: revamp to declarative configuration
[sourcephile-nix.git] / hosts / losurdo / switch
index 138759db80be782150cde0ae171774ddfaffffa7..68382478b5157a0951ba4b56d13a660848691035 100755 (executable)
@@ -1,3 +1,8 @@
 #!/bin/sh -eux
 cd "${0%/*}"/../..
-nix -L run .#losurdo.switch "$@"
+host=losurdo
+chmod -R g-rwx,o-rwx "$PWD"/private/hosts/*/root
+#ln -sfn "$PWD/private/hosts/$host/root" /root/private
+trap 'git reset private/hosts/*/root' EXIT
+git rm -rf --cached --ignore-unmatch private/hosts/*/root # prevent copying to /nix/store
+nix -L run .#$host.switch "$@"