about summary refs log tree commit diff
path: root/nixos
diff options
context:
space:
mode:
authorSymphorien Gibol <symphorien+git@xlumurb.eu>2021-04-24 17:12:51 +0200
committerSymphorien Gibol <symphorien+git@xlumurb.eu>2021-04-24 17:12:51 +0200
commitddf567cd5a26eefab925ebc2e50d15d61e82257a (patch)
tree1fd571c4d7ff3014794c79831abc1090e4a87b75 /nixos
parente4e75149fd5564a633a56af4a6c21a9d2f68c7ba (diff)
downloadnixlib-ddf567cd5a26eefab925ebc2e50d15d61e82257a.tar
nixlib-ddf567cd5a26eefab925ebc2e50d15d61e82257a.tar.gz
nixlib-ddf567cd5a26eefab925ebc2e50d15d61e82257a.tar.bz2
nixlib-ddf567cd5a26eefab925ebc2e50d15d61e82257a.tar.lz
nixlib-ddf567cd5a26eefab925ebc2e50d15d61e82257a.tar.xz
nixlib-ddf567cd5a26eefab925ebc2e50d15d61e82257a.tar.zst
nixlib-ddf567cd5a26eefab925ebc2e50d15d61e82257a.zip
nixos/nagios: use the correct option to restart on config change
X-ReloadIfChanged is incorrect, apparently https://github.com/NixOS/nixpkgs/pull/120324#discussion_r619472321
We restart instead of reloading because nagios unit file has no
ExecReload.
Diffstat (limited to 'nixos')
-rw-r--r--nixos/modules/services/monitoring/nagios.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/nixos/modules/services/monitoring/nagios.nix b/nixos/modules/services/monitoring/nagios.nix
index 9ac6869068f2..61214508a9c6 100644
--- a/nixos/modules/services/monitoring/nagios.nix
+++ b/nixos/modules/services/monitoring/nagios.nix
@@ -192,6 +192,7 @@ in
       path     = [ pkgs.nagios ] ++ cfg.plugins;
       wantedBy = [ "multi-user.target" ];
       after    = [ "network.target" ];
+      restartTriggers = [ nagiosCfgFile ];
 
       serviceConfig = {
         User = "nagios";
@@ -201,7 +202,6 @@ in
         LogsDirectory = "nagios";
         StateDirectory = "nagios";
         ExecStart = "${pkgs.nagios}/bin/nagios /etc/nagios.cfg";
-        X-ReloadIfChanged = nagiosCfgFile;
       };
     };