summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Klink <flokli@flokli.de>2025-08-10 16:24:13 +0200
committerFlorian Klink <flokli@flokli.de>2025-08-10 16:30:52 +0200
commit73582e4158a1d365ae11ee504075efb6759a89bd (patch)
treedccfa36192eacbe1a62342173b6d98c46798428c
parentnixosTests.tayga: set hostName (diff)
downloadnixpkgs-73582e4158a1d365ae11ee504075efb6759a89bd.tar.gz
nixos/tayga: fix config reload
Use a trampoline at /etc/tayga.conf for the config, so reload actually picks up a changed config file.
-rw-r--r--nixos/modules/services/networking/tayga.nix5
1 files changed, 4 insertions, 1 deletions
diff --git a/nixos/modules/services/networking/tayga.nix b/nixos/modules/services/networking/tayga.nix
index 062d8fe52317..bac0005781b2 100644
--- a/nixos/modules/services/networking/tayga.nix
+++ b/nixos/modules/services/networking/tayga.nix
@@ -171,13 +171,16 @@ in
};
};
+ environment.etc."tayga.conf".source = configFile;
+
systemd.services.tayga = {
description = "Stateless NAT64 implementation";
wantedBy = [ "multi-user.target" ];
after = [ "network.target" ];
+ reloadTriggers = [ configFile ];
serviceConfig = {
- ExecStart = "${cfg.package}/bin/tayga -d --nodetach --config ${configFile}";
+ ExecStart = "${cfg.package}/bin/tayga -d --nodetach --config /etc/tayga.conf";
ExecReload = "${pkgs.coreutils}/bin/kill -SIGHUP $MAINPID";
Restart = "always";