From 91353938af657ad6079820945632be5bd478d4c0 Mon Sep 17 00:00:00 2001 From: Akshay Mankar Date: Mon, 17 Apr 2023 20:05:42 +0200 Subject: [PATCH] modules/networking: Use mkDefault for caddy config --- modules/core/networking.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/core/networking.nix b/modules/core/networking.nix index f5bd201..fa91046 100644 --- a/modules/core/networking.nix +++ b/modules/core/networking.nix @@ -56,12 +56,12 @@ in { # Caddy reverse proxy for local services like cups services.caddy = { - enable = cfg.enableCaddy; - globalConfig = '' + enable = lib.mkDefault cfg.enableCaddy; + globalConfig = lib.mkDefault '' default_bind 127.0.0.1 auto_https off ''; - extraConfig = concatStringsSep "\n" [ + extraConfig = lib.mkDefault (concatStringsSep "\n" [ (lib.optionalString config.pub-solar.printing.enable '' @@ -79,7 +79,7 @@ in { file_server } '') - ]; + ]); }; }; }