swarm-nats gateway cert reloads nginx without blocking the switch
nixos-rebuild switch no longer hangs when nginx is (re)started in the same transaction: the cert unit is Before=nginx, so its synchronous reload and nginx's queued start job waited on each other. The reload is now queued with --no-block try-reload-or-restart, as the nixpkgs ACME module does.
This commit is contained in:
parent
f864ffba1b
commit
b4dbd7d1c3
3 changed files with 8 additions and 4 deletions
|
|
@ -434,6 +434,9 @@ let
|
|||
&& !(lib.elem "nginx.service" (copy.requiredBy or [ ]))
|
||||
&& lib.hasInfix "throwaway self-signed" copy.script
|
||||
&& lib.hasInfix "chgrp nginx" copy.script
|
||||
&& lib.hasInfix "systemctl --no-block try-reload-or-restart nginx.service" copy.script
|
||||
&& !(lib.hasInfix "systemctl reload" copy.script)
|
||||
&& !(lib.hasInfix "is-active" copy.script)
|
||||
&& lib.hasInfix "systemctl start swarm-nats-gateway-cert.service" s.swarm-bao-nats-tls.script;
|
||||
}
|
||||
];
|
||||
|
|
|
|||
Loading…
Reference in a new issue