summary refs log tree commit diff
path: root/nixos
diff options
context:
space:
mode:
authorMilan Pässler <me@pbb.lc>2019-01-26 03:08:23 +0100
committerMilan Pässler <me@pbb.lc>2019-01-26 03:12:09 +0100
commit24d5e30b5fcbcd27121047ed210f506273755832 (patch)
tree6a9cd892ea8afa350b1388e11698b99b183b3bac /nixos
parent9310fc3e1345d35afec56e2ba3261f5f627576c6 (diff)
downloadnixpkgs-24d5e30b5fcbcd27121047ed210f506273755832.tar
nixpkgs-24d5e30b5fcbcd27121047ed210f506273755832.tar.gz
nixpkgs-24d5e30b5fcbcd27121047ed210f506273755832.tar.bz2
nixpkgs-24d5e30b5fcbcd27121047ed210f506273755832.tar.lz
nixpkgs-24d5e30b5fcbcd27121047ed210f506273755832.tar.xz
nixpkgs-24d5e30b5fcbcd27121047ed210f506273755832.tar.zst
nixpkgs-24d5e30b5fcbcd27121047ed210f506273755832.zip
nixos/prosody: add ExecReload
Add an ExecReload command to the prosody service, to allow reloading
prosody by sending SIGHUP to the main process, for example to update
certificates without restarting the server. This is exactly how the
`prosodyctl` tool does it.

Note: Currently there is a bug which prevents mod_http from reloading the
certificates properly: https://issues.prosody.im/1216.
Diffstat (limited to 'nixos')
-rw-r--r--nixos/modules/services/networking/prosody.nix1
1 files changed, 1 insertions, 0 deletions
diff --git a/nixos/modules/services/networking/prosody.nix b/nixos/modules/services/networking/prosody.nix
index 25b7d6dbeba..de316e5f466 100644
--- a/nixos/modules/services/networking/prosody.nix
+++ b/nixos/modules/services/networking/prosody.nix
@@ -513,6 +513,7 @@ in
         RuntimeDirectory = [ "prosody" ];
         PIDFile = "/run/prosody/prosody.pid";
         ExecStart = "${cfg.package}/bin/prosodyctl start";
+        ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
       };
     };