From 2a2b630d21306a5b0751f8bb07dfbc96b48bde75 Mon Sep 17 00:00:00 2001 From: dramforever Date: Sun, 1 Mar 2026 15:31:44 +0800 Subject: [PATCH] nixos/ergochat: Use Type=notify-reload The ergochat server has supported this for a long time, so use it instead of a full restart every time. --- nixos/modules/services/networking/ergochat.nix | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/nixos/modules/services/networking/ergochat.nix b/nixos/modules/services/networking/ergochat.nix index 0ad9a2c41c75..5a72d3666c6d 100644 --- a/nixos/modules/services/networking/ergochat.nix +++ b/nixos/modules/services/networking/ergochat.nix @@ -145,14 +145,10 @@ in systemd.services.ergochat = { description = "Ergo IRC daemon"; wantedBy = [ "multi-user.target" ]; - # reload is not applying the changed config. further investigation is needed - # at some point this should be enabled, since we don't want to restart for - # every config change - # reloadIfChanged = true; - restartTriggers = [ cfg.configFile ]; + reloadTriggers = [ cfg.configFile ]; serviceConfig = { + Type = "notify-reload"; ExecStart = "${pkgs.ergochat}/bin/ergo run --conf /etc/ergo.yaml"; - ExecReload = "${pkgs.util-linux}/bin/kill -HUP $MAINPID"; DynamicUser = true; StateDirectory = "ergo"; LimitNOFILE = toString cfg.openFilesLimit;