fix(adguard): handle empty clients list
Only render clients section when clients are configured. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
23696e7e79
commit
294b556542
1 changed files with 10 additions and 9 deletions
|
|
@ -98,15 +98,16 @@ in
|
||||||
querylog_file_enabled: true
|
querylog_file_enabled: true
|
||||||
statistics_enabled: true
|
statistics_enabled: true
|
||||||
|
|
||||||
clients:
|
${lib.optionalString (cfg.clients != []) ''
|
||||||
persistent:
|
clients:
|
||||||
${lib.concatStringsSep "\n " (
|
persistent:
|
||||||
map (client: ''
|
${lib.concatStringsSep "\n " (
|
||||||
- name: ${client.name}
|
map (client: ''
|
||||||
ids:
|
- name: ${client.name}
|
||||||
- ${config.sops.placeholder.${client.idSecret}}
|
ids:
|
||||||
'') cfg.clients
|
- ${config.sops.placeholder.${client.idSecret}}
|
||||||
)}
|
'') cfg.clients
|
||||||
|
)}
|
||||||
|
|
||||||
filtering:
|
filtering:
|
||||||
protection_enabled: true
|
protection_enabled: true
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue