From 51e937c02f357e193d78040813915868d96b010b Mon Sep 17 00:00:00 2001 From: ashisgreat22 Date: Wed, 18 Mar 2026 19:27:21 +0100 Subject: [PATCH] fix(adguard): add empty clients list when no clients configured AdGuard Home fails with empty persistent list. Co-Authored-By: Claude Opus 4.6 --- modules/adguard.nix | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/modules/adguard.nix b/modules/adguard.nix index b8cb16a..c0eba2a 100644 --- a/modules/adguard.nix +++ b/modules/adguard.nix @@ -97,7 +97,8 @@ in querylog_enabled: true querylog_file_enabled: true statistics_enabled: true - '' + lib.optionalString (cfg.clients != []) '' + + ${lib.optionalString (cfg.clients != []) '' clients: persistent: ${lib.concatStringsSep "\n " ( @@ -107,6 +108,11 @@ in - ${config.sops.placeholder.${client.idSecret}} '') cfg.clients )} + '' + '' + + lib.optionalString (cfg.clients == []) '' + clients: + persistent: [] + '' + '' filtering: