From 663a79bfa9529c0d20df017d2aab03f327a88c5f Mon Sep 17 00:00:00 2001 From: Hannes Happle Date: Fri, 31 Jul 2020 14:32:41 +0200 Subject: [PATCH] all aliases in same server block (don't split >=3) --- nginx.tmpl | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/nginx.tmpl b/nginx.tmpl index 4209be2..1f8c926 100644 --- a/nginx.tmpl +++ b/nginx.tmpl @@ -402,9 +402,8 @@ server { {{ end }} # VIRTUAL_HOST_ALIAS -{{ range $host_alias, $containers := groupByMulti $ "Env.VIRTUAL_HOST_ALIAS" "," }} - -{{ $host_alias := trim $host_alias }} +{{ range $host_alias, $containers := groupBy $ "Env.VIRTUAL_HOST_ALIAS" }} +{{ $host_alias := replace $host_alias "," " " 99 }} {{ $first_host := (first (groupByKeys $containers "Env.VIRTUAL_HOST")) }} {{ $first_host := trim $first_host }}