瀏覽代碼

fix validation errors in template

xcad 4 月之前
父節點
當前提交
b022c8a8a1

+ 2 - 2
library/compose/influxdb/compose.yaml.j2

@@ -9,10 +9,10 @@ services:
       - DOCKER_INFLUXDB_INIT_PASSWORD={{ influxdb_init_password | default('password') }}
       - DOCKER_INFLUXDB_INIT_ORG={{ influxdb_init_org | default('myorg') }}
       - DOCKER_INFLUXDB_INIT_BUCKET={{ influxdb_init_bucket | default('mybucket') }}
-      {% if influxdb_init_retention -%}
+      {% if influxdb_init_retention %}
       - DOCKER_INFLUXDB_INIT_RETENTION={{ influxdb_init_retention }}
       {% endif %}
-      {% if influxdb_init_token -%}
+      {% if influxdb_init_token %}
       - DOCKER_INFLUXDB_INIT_ADMIN_TOKEN={{ influxdb_init_token }}
       {% endif %}
     {% if ports_enabled %}

+ 4 - 4
library/compose/nextcloud/compose.yaml.j2

@@ -4,12 +4,12 @@ services:
     container_name: {{ container_name | default('nextcloud-app') }}
     environment:
       - TZ={{ container_timezone | default('UTC') }}
-      {% if database_type == 'mysql' -%}
+      {% if database_type == 'mysql' %}
       - MYSQL_PASSWORD={{ database_password | default('nextcloud') }}
       - MYSQL_DATABASE={{ database_name | default('nextcloud') }}
       - MYSQL_USER={{ database_user | default('nextcloud') }}
       - MYSQL_HOST={{ service_name | default('nextcloud') }}-db
-      {% elif database_type == 'postgres' -%}
+      {% elif database_type == 'postgres' %}
       - POSTGRES_PASSWORD={{ database_password | default('nextcloud') }}
       - POSTGRES_DB={{ database_name | default('nextcloud') }}
       - POSTGRES_USER={{ database_user | default('nextcloud') }}
@@ -43,7 +43,7 @@ services:
     restart: {{ restart_policy | default('unless-stopped') }}
 
   {{ service_name | default('nextcloud') }}-db:
-    {% if database_type == 'mysql' -%}
+    {% if database_type == 'mysql' %}
     # See compatibility matrix for Nextcloud 31
     # https://docs.nextcloud.com/server/31/admin_manual/installation/system_requirements.html
     image: docker.io/library/mariadb:10.11.14
@@ -57,7 +57,7 @@ services:
       - MYSQL_USER={{ database_user | default('nextcloud') }}
     volumes:
       - nextcloud-db:/var/lib/mysql
-    {% elif database_type == 'postgres' -%}
+    {% elif database_type == 'postgres' %}
     image: docker.io/library/postgres:17.6
     container_name: {{ service_name | default('nextcloud') }}-db
     environment:

+ 1 - 1
library/compose/pihole/compose.yaml.j2

@@ -12,7 +12,7 @@ services:
     {% endif %}
     environment:
       - TZ={{ container_timezone | default('UTC') }}
-      {% if pihole_webpassword -%}
+      {% if pihole_webpassword %}
       - FTLCONF_webserver_api_password={{ pihole_webpassword }}
       {% endif %}
       - FTLCONF_dns_upstreams={{ pihole_dns_upstreams | default('8.8.8.8;8.8.4.4') }}

+ 3 - 3
library/compose/postgres/compose.yaml.j2

@@ -4,13 +4,13 @@ services:
     container_name: {{ container_name | default('postgres') }}
     environment:
       - POSTGRES_INITDB_ARGS={{ postgres_initdb_args | default('--data-checksums') }}
-      {% if postgres_host_auth_method -%}
+      {% if postgres_host_auth_method %}
       - POSTGRES_HOST_AUTH_METHOD={{ postgres_host_auth_method }}
       {% endif %}
       - POSTGRES_USER={{ database_user | default('postgres') }}
-      {% if postgres_secrets_enabled -%}
+      {% if postgres_secrets_enabled %}
       - POSTGRES_PASSWORD_FILE=/run/secrets/postgres_password
-      {% else -%}
+      {% else %}
       - POSTGRES_PASSWORD={{ database_password | default('postgres') }}
       {% endif %}
       - POSTGRES_DB={{ database_name | default('postgres') }}