-
Notifications
You must be signed in to change notification settings - Fork 26
/
Copy pathdocker-compose.secure.yml
171 lines (158 loc) · 6.36 KB
/
docker-compose.secure.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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
version: "3.7"
services:
plex:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.plex.tls.certresolver: prod
traefik.http.routers.plex.rule: Host(`${PLEX_HOST}`)
traefik.http.services.plex.loadbalancer.server.port: 32400
traefik.http.services.plex.loadbalancer.server.scheme: http
ports:
- "127.0.0.1:32400:32400/tcp"
jellyfin:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.jellyfin.tls.certresolver: prod
traefik.http.routers.jellyfin.rule: Host(`${JELLYFIN_HOST}`)
traefik.http.services.jellyfin.loadbalancer.server.port: 8096
traefik.http.services.jellyfin.loadbalancer.server.scheme: http
ports:
- "127.0.0.1:8096:8096/tcp"
- "127.0.0.1:7359:7359/udp"
nzbhydra:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.nzbhydra.tls.certresolver: prod
traefik.http.routers.nzbhydra.rule: Host(`${NZBHYDRA_HOST}`)
traefik.http.routers.nzbhydra.middlewares: hsts-header
ports:
- "127.0.0.1:5076:5076/tcp"
ombi:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.ombi.tls.certresolver: prod
traefik.http.routers.ombi.rule: Host(`${OMBI_HOST}`)
traefik.http.routers.ombi.middlewares: hsts-header
ports:
- "127.0.0.1:3579:3579/tcp"
prowlarr:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.prowlarr.tls.certresolver: prod
traefik.http.routers.prowlarr.rule: Host(`${PROWLARR_HOST}`)
traefik.http.routers.prowlarr.middlewares: hsts-header, ipallowlist
ports:
- "127.0.0.1:9696:9696/tcp"
nzbget:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.nzbget.tls.certresolver: prod
traefik.http.routers.nzbget.rule: Host(`${NZBGET_HOST}`)
traefik.http.routers.nzbget.middlewares: hsts-header, ipallowlist
ports:
- "127.0.0.1:6789:6789/tcp"
sonarr:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.sonarr.tls.certresolver: prod
traefik.http.routers.sonarr.rule: Host(`${SONARR_HOST}`)
traefik.http.routers.sonarr.middlewares: hsts-header, ipallowlist
ports:
- "127.0.0.1:8989:8989/tcp"
radarr:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.radarr.tls.certresolver: prod
traefik.http.routers.radarr.rule: Host(`${RADARR_HOST}`)
traefik.http.routers.radarr.middlewares: hsts-header, ipallowlist
ports:
- "127.0.0.1:7878:7878/tcp"
duplicati:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.duplicati.tls.certresolver: prod
traefik.http.routers.duplicati.rule: Host(`${DUPLICATI_HOST}`)
traefik.http.routers.duplicati.middlewares: hsts-header, basicauth, ipallowlist
ports:
- "127.0.0.1:8200:8200/tcp"
netdata:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.netdata.tls.certresolver: prod
traefik.http.routers.netdata.rule: Host(`${NETDATA_HOST}`)
traefik.http.routers.netdata.middlewares: hsts-header, basicauth, ipallowlist
ports:
- "127.0.0.1:19999:19999/tcp"
overseerr:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.overseerr.tls.certresolver: prod
traefik.http.routers.overseerr.rule: Host(`${OVERSEERR_HOST}`)
traefik.http.routers.overseerr.middlewares: hsts-header, ipallowlist
ports:
- "127.0.0.1:5055:5055/tcp"
syncthing:
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.syncthing.tls.certresolver: prod
traefik.http.routers.syncthing.rule: Host(`${SYNCTHING_HOST}`)
traefik.http.routers.syncthing.middlewares: hsts-header, basicauth, ipallowlist
ports:
- "127.0.0.1:8384:8384/tcp"
- "22000:22000/tcp"
- "22000:22000/udp"
- "21027:21027/udp"
# https://hub.docker.com/_/traefik/
traefik:
image: traefik:v3.1.4@sha256:6215528042906b25f23fcf51cc5bdda29e078c6e84c237d4f59c00370cb68440
restart: unless-stopped
environment:
TZ: "${TZ}"
networks:
- default
ports:
- 80:80/tcp
- 443:443/tcp
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- ${CONFIG_DIR}/traefik:/etc/traefik:rw
command:
- "--log.level=INFO"
- "--api=true"
- "--providers.docker=true"
- "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:80"
- "--entrypoints.web.http.redirections.entrypoint.to=websecure"
- "--entrypoints.web.http.redirections.entrypoint.scheme=https"
- "--entrypoints.websecure.address=:443"
- "--certificatesResolvers.prod.acme.tlschallenge=true"
- "--certificatesresolvers.prod.acme.storage=/etc/traefik/acme.json"
- "--certificatesresolvers.prod.acme.email=${ACME_EMAIL}"
- "--certificatesresolvers.prod.acme.caserver=https://acme-v02.api.letsencrypt.org/directory"
- "--certificatesResolvers.staging.acme.tlschallenge=true"
- "--certificatesresolvers.staging.acme.storage=/etc/traefik/acme.json"
- "--certificatesresolvers.staging.acme.email=${ACME_EMAIL}"
- "--certificatesresolvers.staging.acme.caserver=https://acme-staging-v02.api.letsencrypt.org/directory"
labels:
traefik.enable: "true"
traefik.docker.network: mediaserver_default
traefik.http.routers.traefik.tls.certresolver: prod
traefik.http.routers.traefik.rule: Host(`${TRAEFIK_HOST}`)
traefik.http.routers.traefik.middlewares: hsts-header, basicauth
traefik.http.routers.traefik.service: api@internal
traefik.http.middlewares.test-auth.basicauth.users: "${BASICAUTH_USERS}"
traefik.http.middlewares.basicauth.basicauth.usersfile: /etc/traefik/.htpasswd
traefik.http.middlewares.ipallowlist.ipwhitelist.sourcerange: "${IPALLOWLIST}"
traefik.http.middlewares.hsts-header.headers.customResponseHeaders.Strict-Transport-Security: "max-age=63072000"