Compare commits
2 Commits
4d4a578b78
...
4633927204
Author | SHA1 | Date | |
---|---|---|---|
4633927204 | |||
64e726391a |
@ -1,6 +1,4 @@
|
||||
---
|
||||
version: "3"
|
||||
|
||||
services:
|
||||
traefik:
|
||||
image: traefik:${TRAEFIK_VERSION}
|
||||
@ -13,7 +11,7 @@ services:
|
||||
- --api.dashboard=true
|
||||
# configure Let's Encrypt automatic certificates
|
||||
- --certificatesresolvers.${TRAEFIK_CERTRESOLVER}.acme.dnschallenge=true
|
||||
- --certificatesresolvers.${TRAEFIK_CERTRESOLVER}.acme.dnschallenge.provider=hetzner
|
||||
- --certificatesresolvers.${TRAEFIK_CERTRESOLVER}.acme.dnschallenge.provider=${TRAEFIK_DNSPROVIDER}
|
||||
- --certificatesresolvers.${TRAEFIK_CERTRESOLVER}.acme.email=${LETSENCRYPT_EMAIL}
|
||||
- --certificatesresolvers.${TRAEFIK_CERTRESOLVER}.acme.keytype=RSA4096
|
||||
- --certificatesresolvers.${TRAEFIK_CERTRESOLVER}.acme.storage=/certs.json
|
||||
@ -32,8 +30,8 @@ services:
|
||||
# should not need, but just in case, a folder for dynamic config files is also configured
|
||||
- --providers.file.directory=/config
|
||||
- --providers.file.watch=true
|
||||
environment:
|
||||
- HETZNER_API_KEY=${HETZNER_API_KEY}
|
||||
env_file:
|
||||
- ${TRAEFIK_DNSPROVIDER_ENVFILE}
|
||||
labels:
|
||||
# expose Træfik using Træfik (dashboard)
|
||||
- traefik.enable=${TRAEFIK_ENABLED}
|
||||
|
1
env.dnsprovider.example
Normal file
1
env.dnsprovider.example
Normal file
@ -0,0 +1 @@
|
||||
HETZNER_API_KEY=
|
@ -11,7 +11,8 @@ TRAEFIK_PILOT_TOKEN=
|
||||
TRAEFIK_TLSENABLED=true
|
||||
|
||||
# Certificate provider
|
||||
HETZNER_API_KEY=
|
||||
TRAEFIK_DNSPROVIDER=hetzner
|
||||
TRAEFIK_DNSPROVIDER_ENVFILE=./.env.dnsprovider
|
||||
LETSENCRYPT_EMAIL=admin@mydomain.com
|
||||
|
||||
# Debugging
|
||||
|
Loading…
Reference in New Issue
Block a user