From b9031dbd7c363c54be8e721fd631ebd4e9bbb392 Mon Sep 17 00:00:00 2001 From: teutat3s Date: Thu, 16 Mar 2023 11:49:36 +0100 Subject: [PATCH] core: reload caddy instead of always restarting when config file changes --- modules/core/networking.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/modules/core/networking.nix b/modules/core/networking.nix index afba8b25..435dc959 100644 --- a/modules/core/networking.nix +++ b/modules/core/networking.nix @@ -55,6 +55,11 @@ in { ++ lib.optionals cfg.enableHelp ["help.local"]; }; + # Changing the Caddyfile should only trigger a reload, not a restart + systemd.services.caddy.reloadTriggers = [ + config.services.caddy.configFile + ]; + # Caddy reverse proxy for local services like cups services.caddy = { enable = cfg.enableCaddy;