diff options
| author | quentin@aristote.fr <quentin@aristote.fr> | 2025-02-06 08:10:39 +0100 |
|---|---|---|
| committer | quentin@aristote.fr <quentin@aristote.fr> | 2025-02-06 08:10:39 +0100 |
| commit | 0bc5299815401c3add9d81da766fb021e628e5e4 (patch) | |
| tree | 49def6ec8003b7058e192e4c1ef43c8203e461a5 /modules/nixos/personal | |
| parent | a983cf12cddd0afe07af35d6e17ad8f4a1f75b09 (diff) | |
nixos: upgrade: checkHosts: host -> ping
host does not resolve local hosts
Diffstat (limited to 'modules/nixos/personal')
| -rw-r--r-- | modules/nixos/personal/nix.nix | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/nixos/personal/nix.nix b/modules/nixos/personal/nix.nix index 99496fa..27f3c2b 100644 --- a/modules/nixos/personal/nix.nix +++ b/modules/nixos/personal/nix.nix @@ -8,9 +8,9 @@ hasFlake = cfg.flake != null; hasFlakeInputs = cfg.autoUpgrade.autoUpdateInputs != []; checkNetwork = { - path = [pkgs.host]; + path = [pkgs.unixtools.ping]; # Check network connectivity - preStart = "(${lib.concatMapStringsSep " && " (host: "host ${host}") cfg.autoUpgrade.checkHosts}) || kill -s SIGUSR1 $$"; + preStart = "(${lib.concatMapStringsSep " && " (host: "ping -c 1 ${host}") cfg.autoUpgrade.checkHosts}) || kill -s SIGUSR1 $$"; unitConfig = { StartLimitIntervalSec = 300; StartLimitBurst = 5; |
