From 0515216cefe35b8ed9b68cd65afad66d66b5faea Mon Sep 17 00:00:00 2001 From: sternenseemann Date: Mon, 14 Jul 2025 15:41:05 +0200 Subject: [PATCH] nixos/inspircd: sync with upstream systemd.service file We could in theory just re-use the upstream one, but it sets User=root which I'm not entirely comfortable with. Instead, add the settings we were missing from that file here. Sadly, upstream doesn't configure a syscall filter or similar. --- nixos/modules/services/networking/inspircd.nix | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/nixos/modules/services/networking/inspircd.nix b/nixos/modules/services/networking/inspircd.nix index 315a327bc36e..dbc587e0a4f1 100644 --- a/nixos/modules/services/networking/inspircd.nix +++ b/nixos/modules/services/networking/inspircd.nix @@ -53,14 +53,22 @@ in config = lib.mkIf cfg.enable { systemd.services.inspircd = { description = "InspIRCd - the stable, high-performance and modular Internet Relay Chat Daemon"; + unitConfig.Documentation = "https://docs.inspircd.org"; wantedBy = [ "multi-user.target" ]; - requires = [ "network.target" ]; + + after = [ + "network.target" + "network-online.target" + ]; + wants = [ "network-online.target" ]; serviceConfig = { Type = "simple"; ExecStart = '' ${lib.getBin cfg.package}/bin/inspircd --config ${configFile} --nofork --nopid ''; + ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID"; + Restart = "on-failure"; DynamicUser = true; }; };