mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-25 07:00:43 +00:00
consul service: Restart on failure.
Consul is a service you typically want to have running all the time; it's not supposed to quit by itself.
This commit is contained in:
parent
597c9864b5
commit
f4c53f1940
|
@ -183,6 +183,7 @@ in
|
|||
ExecReload = "${cfg.package.bin}/bin/consul reload";
|
||||
PermissionsStartOnly = true;
|
||||
User = if cfg.dropPrivileges then "consul" else null;
|
||||
Restart = "on-failure";
|
||||
TimeoutStartSec = "0";
|
||||
} // (optionalAttrs (cfg.leaveOnStop) {
|
||||
ExecStop = "${cfg.package.bin}/bin/consul leave";
|
||||
|
|
Loading…
Reference in a new issue