diff --git a/extras/README.md b/extras/README.md new file mode 100644 index 0000000..2c3e1c7 --- /dev/null +++ b/extras/README.md @@ -0,0 +1,6 @@ +# Extras +These are extra files that might not be needed on NixOS, but help using Nix on +other Linux distrubutions. + +Included files: +- `systemd/`: `systemd` units relating to the proper initialization of Nix on other distributions diff --git a/extras/systemd/nix-daemon-symlink-reload.service b/extras/systemd/nix-daemon-symlink-reload.service new file mode 100644 index 0000000..e5a1b87 --- /dev/null +++ b/extras/systemd/nix-daemon-symlink-reload.service @@ -0,0 +1,14 @@ +[Unit] +Description=Reload nix-daemon after mounting /nix +After=mount.nix +Requires=nix.mount +DefaultDependencies=no + +[Service] +Type=oneshot +RemainAfterExit=yes +ExecStart=/usr/bin/systemctl daemon-reload +ExecStart=/usr/bin/systemctl restart --no-block nix-daemon.socket + +[Install] +WantedBy=sysinit.target