-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
67 lines (60 loc) · 1.65 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
version: "3.9"
services:
traefik:
image: traefik:v2.9
restart: unless-stopped
logging:
options:
max-size: "10m"
healthcheck:
test: ["CMD", "wget", "http://localhost:8082/ping", "--spider"]
interval: 10s
timeout: 2s
retries: 3
start_period: 5s
command:
- "--log.level=WARN"
- "--accesslog=true"
labels:
- "traefik.enable=true"
- "traefik.docker.network=traefik-network"
- "traefik.http.services.dashboard.loadbalancer.server.port=8080"
- "traefik.http.services.dashboard.loadbalancer.passhostheader=true"
- "traefik.http.routers.dashboard.rule=Host(`dash.example.com`)"
- "traefik.http.routers.dashboard.entrypoints=websecure"
- "traefik.http.routers.dashboard.service=api@internal"
- "traefik.http.routers.dashboard.tls=true"
- "traefik.http.routers.dashboard.tls.certresolver=letsencrypt"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./etc/traefik.toml:/etc/traefik/traefik.toml
- ./etc/dynamic.toml:/etc/traefik/dynamic.toml
- traefik-certificates:/etc/traefik/acme
networks:
- traefik-network
ports:
- target: 80
published: 80
mode: host
- target: 443
published: 443
mode: host
protocol: tcp
- target: 443
published: 443
mode: host
protocol: udp
- target: 8080
published: 8080
mode: host
protocol: tcp
networks:
traefik-network:
external: true
volumes:
traefik-certificates:
driver: local
driver_opts:
o: bind
type: none
device: ./etc/traefik/ssl/