Updated Traefik container to expose api + doashboard, as well as setup entrypoints
This commit is contained in:
parent
df275b5e46
commit
8c59c826e3
@ -6,24 +6,50 @@ services:
|
||||
traefik:
|
||||
image: 'traefik:latest'
|
||||
container_name: traefik
|
||||
ports:
|
||||
# These ports are in format <host-port>:<container-port>
|
||||
- '80:80' # Public HTTP Port
|
||||
- '443:443' # Public HTTPS Port
|
||||
- '8080:8080' # Dashboard Port
|
||||
volumes:
|
||||
- ./nginx/data:/data
|
||||
- ./nginx/letsencrypt:/etc/letsencrypt
|
||||
restart: unless-stopped
|
||||
|
||||
- ./letsencrypt:/letsencrypt
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
- ./dynamic.yaml:/dynamic.yaml
|
||||
networks:
|
||||
## Traefik is sat on every network to allow exposure ##
|
||||
- traefik
|
||||
- frontend
|
||||
- development
|
||||
- backend
|
||||
- bitwarden
|
||||
- services
|
||||
ports:
|
||||
## These ports are in format <host-port>:<container-port> ##
|
||||
- '80:80' # Public HTTP Port
|
||||
- '443:443' # Public HTTPS Port
|
||||
- '8080:8080' # Dashboard Port
|
||||
command:
|
||||
## General Settings ##
|
||||
- --api.insecure=true
|
||||
- --api.dashboard=true
|
||||
- --api.debug=true
|
||||
## Log Settings ##
|
||||
- --log.level=DEBUG # <== Setting the level of the logs from traefik
|
||||
## Provider Settings ##
|
||||
- --providers.docker=true
|
||||
- --providers.docker.exposedbydefault=false
|
||||
- --providers.file.filename=/dynamic.yaml
|
||||
## Entrypoints Settings ##
|
||||
- --entrypoints.http.address=:80
|
||||
- --entrypoints.https.address=:443
|
||||
## Certificate Settings ##
|
||||
- --certificatesresolvers.mytlschallenge.acme.tlschallenge=true
|
||||
- --certificatesresolvers.mytlschallenge.acme.email=contact@luke-else.co.uk
|
||||
- --certificatesresolvers.mytlschallenge.acme.storage=/letsencrypt/acme.json
|
||||
labels:
|
||||
## Exposing API Dashboard Service ##
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.api.rule=Host(traefik.luke-else.co.uk)"
|
||||
- "traefik.http.routers.api.service=api@internal"
|
||||
restart: unless-stopped
|
||||
|
||||
|
||||
## All Networks for child containers - All containers depend on this container being spun up ##
|
||||
networks:
|
||||
traefik:
|
||||
name: traefik
|
||||
|
Loading…
Reference in New Issue
Block a user