-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
62 lines (57 loc) · 1.92 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
---
version: "3.7"
services:
thedate:
build: .
container_name: thedate
labels:
- traefik.enable=true
# http
- traefik.http.routers.thedate.entrypoints=web
- traefik.http.routers.thedate.rule=Host(`${DOMAIN}`)
# https
- traefik.http.routers.thedate-secure.entrypoints=websecure
- traefik.http.routers.thedate-secure.rule=Host(`${DOMAIN}`)
- traefik.http.routers.thedate-secure.tls.certresolver=letsencrypt
- traefik.http.routers.thedate-secure.tls=true
traefik:
image: traefik:latest
container_name: traefik
command:
# Globals
- --log.level=ERROR
- --api=false
- --global.sendAnonymousUsage=false
# Docker
- --providers.docker=true
- --providers.docker.exposedbydefault=false
- --providers.docker.endpoint=unix:///var/run/docker.sock
# Entrypoints
- --entrypoints.web.address=:80
- --entrypoints.websecure.address=:443
# LetsEncrypt
- --certificatesresolvers.letsencrypt.acme.email=${CF_API_EMAIL}
- --certificatesresolvers.letsencrypt.acme.dnschallenge.provider=cloudflare
- --certificatesresolvers.letsencrypt.acme.storage=/etc/traefik/acme.json
ports:
- 80:80
- 443:443
environment:
- CF_API_EMAIL=${CF_API_EMAIL}
- CF_API_KEY=${CF_API_KEY}
volumes:
- /docker/volumes/traefik/acme.json:/etc/traefik/acme.json
- /var/run/docker.sock:/var/run/docker.sock:ro
watchtower:
container_name: watchtower
image: containrrr/watchtower:latest
volumes:
- /var/run/docker.sock:/var/run/docker.sock
environment:
- WATCHTOWER_CLEANUP=true
- WATCHTOWER_DEBUG=true
- WATCHTOWER_POLL_INTERVAL=21600
- WATCHTOWER_LABEL_ENABLE=false
- WATCHTOWER_NOTIFICATIONS=gotify
- WATCHTOWER_NOTIFICATION_GOTIFY_URL=https://${GOTIFY}.${PDOMAIN}
- WATCHTOWER_NOTIFICATION_GOTIFY_TOKEN=${WATCHTOWER_GOTIFY_TOKEN}