summary refs log tree commit diff
diff options
context:
space:
mode:
authorRory& <root@rory.gay>2026-01-21 07:52:02 +0100
committerRory& <root@rory.gay>2026-01-21 07:52:02 +0100
commit278b62a809ff7664d4accd88a9016e8a067b2fdb (patch)
tree77f8f5ae0c7be7b80e3e4717d3857e644d78e914
parentUpdate flake inputs (diff)
downloadRory-Open-Architecture-278b62a809ff7664d4accd88a9016e8a067b2fdb.tar.xz
Stricter ordening for spacebar container, kill shells
-rwxr-xr-xhost/Rory-ovh/configuration.nix13
1 files changed, 13 insertions, 0 deletions
diff --git a/host/Rory-ovh/configuration.nix b/host/Rory-ovh/configuration.nix

index 2d86b19..d6d3461 100755 --- a/host/Rory-ovh/configuration.nix +++ b/host/Rory-ovh/configuration.nix
@@ -128,6 +128,19 @@ spacebar ; }; + + # prevent a hang on rebuild with forgotten shells... + systemd.services."container@spacebar" = { + # dependency on postgres for good measure... + after = [ "postgresql.service" ]; + wants = [ "postgresql.service" ]; + preStop = '' + for pid in $(pgrep -f "nixos-container root-login spacebar"); do + echo "Killing shell with PID $pid" + kill -9 $pid + done + ''; + }; #containers."syntest1" = import ./services/containers/syntest1/container.nix { # inherit