diff options
author | Pascal Bach <pascal.bach@nextrem.ch> | 2020-05-15 13:41:19 +0200 |
---|---|---|
committer | Pascal Bach <pascal.bach@nextrem.ch> | 2020-07-03 22:34:29 +0200 |
commit | 3e7d650bcca2fb18cc05468878cbccfb06096f7b (patch) | |
tree | 3929f84d874f53a8f506d0cb34167f4938f29017 /nixos/modules/services/networking/unifi.nix | |
parent | 2a9765e26522900f5c2e0a97a93d7284b9a38c52 (diff) |
nixos/unifi: restart service on package update
Currently the service doesn't detect if on of the packages is updated and doesn't restart. By manually adding a trigger we make sure the service restarts if any of the involved packages update.
Diffstat (limited to 'nixos/modules/services/networking/unifi.nix')
-rw-r--r-- | nixos/modules/services/networking/unifi.nix | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/nixos/modules/services/networking/unifi.nix b/nixos/modules/services/networking/unifi.nix index 4bdfa8143dce0..62bcf7a149726 100644 --- a/nixos/modules/services/networking/unifi.nix +++ b/nixos/modules/services/networking/unifi.nix @@ -162,6 +162,8 @@ in unitConfig.RequiresMountsFor = stateDir; # This a HACK to fix missing dependencies of dynamic libs extracted from jars environment.LD_LIBRARY_PATH = with pkgs.stdenv; "${cc.cc.lib}/lib"; + # Make sure package upgrades trigger a service restart + restartTriggers = [ cfg.unifiPackage cfg.mongodbPackage ]; serviceConfig = { Type = "simple"; |