forked from mirrors/nixpkgs
nixos/home-assistant: make service reloadable
This allows quick reloads using the following trick: $(nix-build --show-trace --no-out-link \ -E '(with import <nixpkgs/nixos> {}; pkgs.writeScript "update-hass-config" config.systemd.services.home-assistant.preStart)') systemctl reload home-assistant
This commit is contained in:
parent
e0ece5aebe
commit
26e9a3498b
|
@ -240,6 +240,7 @@ in {
|
|||
'');
|
||||
serviceConfig = {
|
||||
ExecStart = "${package}/bin/hass --config '${cfg.configDir}'";
|
||||
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
|
||||
User = "hass";
|
||||
Group = "hass";
|
||||
Restart = "on-failure";
|
||||
|
|
Loading…
Reference in a new issue