fix: mount the traefik data directory instead of the acme.json file when starting traefik

Without this change, Docker - at least on arm64 - appears to mount the file as 0755 instead of 0600. We can trick docker by mounting the folder and then referencing _that_ instead.
This commit is contained in:
Jose Diaz-Gonzalez
2023-07-01 19:37:47 -04:00
parent bbbe0e763d
commit f7c46a46f4

View File

@@ -21,7 +21,7 @@ services:
{{ if $.TRAEFIK_LETSENCRYPT_EMAIL }}
- --certificatesresolvers.leresolver.acme.caserver={{ $.TRAEFIK_LETSENCRYPT_SERVER }}
- --certificatesresolvers.leresolver.acme.email={{ $.TRAEFIK_LETSENCRYPT_EMAIL }}
- --certificatesresolvers.leresolver.acme.storage=/acme.json
- --certificatesresolvers.leresolver.acme.storage=/data/acme.json
- --certificatesresolvers.leresolver.acme.tlschallenge=true
{{ end }}
@@ -59,4 +59,4 @@ services:
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
- "{{ $.TRAEFIK_DATA_DIR }}/traefik-acme.json:/acme.json"
- "{{ $.TRAEFIK_DATA_DIR }}:/data"