From ad55e1a1efc768c1638a49e86072caca32270b32 Mon Sep 17 00:00:00 2001 From: Andreas Fuchs Date: Wed, 8 Jan 2025 13:38:04 -0500 Subject: [PATCH] Make systemd-resolved's config file a reload trigger It is documented to re-read its configuration file upon reload, so we can simply reload it instead of restarting the whole daemon. --- nixos/modules/system/boot/resolved.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/system/boot/resolved.nix b/nixos/modules/system/boot/resolved.nix index f6d76d727aa95..44d13a6fdd982 100644 --- a/nixos/modules/system/boot/resolved.nix +++ b/nixos/modules/system/boot/resolved.nix @@ -193,7 +193,7 @@ in systemd.services.systemd-resolved = { wantedBy = [ "sysinit.target" ]; aliases = [ "dbus-org.freedesktop.resolve1.service" ]; - restartTriggers = [ config.environment.etc."systemd/resolved.conf".source ]; + reloadTriggers = [ config.environment.etc."systemd/resolved.conf".source ]; stopIfChanged = false; };