This commit is contained in:
Yax 2020-06-28 15:50:51 +02:00
parent 3485aea5ef
commit fa2983199d
2 changed files with 8 additions and 2 deletions

View file

@ -1,4 +1,5 @@
DOMAIN=localhost.localdomain
HOST_TRAEFIK=traefik
HOST_GLANCES=glances
HOST_PORTAINER=portainer
HOST_MAIL=mail

View file

@ -15,7 +15,11 @@ services:
- --certificatesresolvers.letsencrypt.acme.tlschallenge=true
labels:
- traefik.enable=true
- traefik.http.services.traefik.loadbalancer.server.port=80
- traefik.http.routers.dashboard.rule=Host(`${HOST_TRAEFIK}.${DOMAIN}`)
- traefik.http.routers.dashboard.entrypoints=websecure
- traefik.http.routers.dashboard.tls=true
- traefik.http.routers.dashboard.tls.certresolver=letsencrypt
- traefik.http.services.dashboard.loadbalancer.server.port=8080
# global redirect to https
- traefik.http.routers.http-catchall.rule=hostregexp(`{host:.+}`)
- traefik.http.routers.http-catchall.entrypoints=web
@ -31,7 +35,8 @@ services:
ports:
- 80:80
- 443:443
- 8080:8080
expose:
- 8080
networks:
- srv
restart: unless-stopped