⚡️ force wg-quick service to restart on-failure
This commit is contained in:
parent
3d9ceca69f
commit
102d5058b5
|
@ -22,9 +22,20 @@
|
|||
publicKey = "y36/EpLUerwM6NSGsVDCkb37Wj/Z3CI0mPFGatVa0Ws=";
|
||||
allowedIPs = [ "10.0.0.1/24" ];
|
||||
endpoint = "fainsin.bzh:5553";
|
||||
persistentKeepalive = 30;
|
||||
}];
|
||||
};
|
||||
};
|
||||
systemd.services.wg-quick-wg0 = {
|
||||
serviceConfig = {
|
||||
Type = lib.mkForce "simple";
|
||||
Restart = "on-failure";
|
||||
RestartSec = "10s";
|
||||
};
|
||||
unitConfig = {
|
||||
StartLimitIntervalSec = 0; # ensure Restart= is always honoured
|
||||
};
|
||||
};
|
||||
|
||||
# This should already be here from switching to bootspec earlier.
|
||||
# It's not required anymore, but also doesn't do any harm.
|
||||
|
|
Loading…
Reference in a new issue