-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
92 lines (91 loc) · 2.74 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
services:
traefik:
environment:
HOSTINGDE_API_KEY_FILE: /run/secrets/hostingde_api_key
secrets:
- hostingde_api_key
container_name: l0pb-traefik
hostname: l0pb-traefik
image: traefik:v3.0
networks:
proxy:
ipv4_address: 172.30.255.254
ports:
- mode: host
target: 80
published: "80"
protocol: tcp
- mode: host
target: 443
published: "443"
protocol: tcp
restart: unless-stopped
security_opt:
- no-new-privileges:true
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- /var/log/traefik/:/var/log/traefik/
- ./config/traefik/service/traefik.yml:/traefik.yml:ro
- ./config/traefik/service/dynamic_conf.yml:/dynamic_conf.yml
- ./config/traefik/service/dns_letsencrypt.json:/dns_letsencrypt.json
certdumper:
container_name: l0pb-certdumper
hostname: l0pb-certdumper
image: ghcr.io/kereis/traefik-certs-dumper:latest
restart: unless-stopped
network_mode: none
volumes:
- ./config/traefik/service:/traefik:ro
- /var/run/docker.sock:/var/run/docker.sock:ro
- ./html/certs:/output:rw
- ./hook.sh:/hook/hook.sh:ro
environment:
ACME_FILE_PATH: "/traefik/dns_letsencrypt.json"
OVERRIDE_UID: "33"
OVERRIDE_GID: "33"
healthcheck:
test: ["CMD", "/usr/bin/healthcheck"]
interval: 30s
timeout: 10s
retries: 5
nginx:
container_name: l0pb-nginx
hostname: l0pb-nginx
image: nginx:latest
labels:
traefik.docker.network: proxy
traefik.enable: "true"
traefik.http.routers.l0pb.entrypoints: websecure
traefik.http.routers.l0pb.middlewares: default@file
traefik.http.routers.l0pb.rule: Host(`l0pb.me`) || Host(`l0pb.dev`)
traefik.http.routers.l0pb.service: l0pb
traefik.http.routers.l0pb.tls: "true"
traefik.http.routers.l0pb.tls.certresolver: hosting
traefik.http.routers.l0pb.tls.domains[0].main: "l0pb.me"
traefik.http.routers.l0pb.tls.domains[0].sans: "*.l0pb.me"
traefik.http.routers.l0pb.tls.domains[1].main: "l0pb.dev"
traefik.http.routers.l0pb.tls.domains[1].sans: "*.l0pb.dev"
traefik.http.services.l0pb.loadbalancer.server.port: "80"
networks:
default: null
proxy: null
restart: always
healthcheck:
test: ["CMD", "curl", "--fail", "http://localhost"]
interval: 30s
timeout: 10s
retries: 3
volumes:
- ./config/nginx/default.conf:/etc/nginx/conf.d/default.conf
- ./html:/var/www/l0pb/html
networks:
proxy:
name: proxy
driver: bridge
ipam:
config:
- subnet: 172.30.0.0/16
attachable: true
secrets:
hostingde_api_key:
file: ./secrets/hostingde_api_key.txt