-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
93 lines (86 loc) · 2.75 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
93
services:
traefik:
restart: always
image: "traefik:v3.2"
container_name: "traefik"
command:
- "--providers.docker=true"
- "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:80"
- "--entryPoints.websecure.address=:443"
- "--certificatesresolvers.myresolver.acme.tlschallenge=true"
- "--certificatesresolvers.myresolver.acme.email=${MY_EMAIL}"
- "--certificatesresolvers.myresolver.acme.storage=/letsencrypt/acme.json"
labels:
# global redirect to https
- "traefik.http.routers.http-catchall.rule=hostregexp(`{host:.+}`)"
- "traefik.http.routers.http-catchall.entrypoints=web"
- "traefik.http.routers.http-catchall.middlewares=redirect-to-https"
# middleware redirect
- "traefik.http.middlewares.redirect-to-https.redirectscheme.scheme=https"
ports:
- "80:80"
- "443:443"
volumes:
- "./letsencrypt:/letsencrypt"
- "/var/run/docker.sock:/var/run/docker.sock:ro"
redis:
restart: always
image: redis:alpine
entrypoint: redis-server --save "" --appendonly no
# publishes Redis port on the host. May be modified or disabled if another
# Redis instance is already running.
ports:
- "127.0.0.1:6379:6379"
labels:
- "traefik.enable=false"
swim-consumer:
restart: always
image: swim-consumer
build: ./swim_consumer/
volumes:
- $PWD/swim_consumer.conf:/app/swim_consumer.conf:ro
depends_on:
- redis
labels:
- "traefik.enable=false"
swim-data-processor:
restart: always
image: swim-data-processor
build: ./swim_data_processor/
depends_on:
- redis
labels:
- "traefik.enable=false"
swim-arrival-processor:
restart: always
image: swim-arrival-processor
build: ./swim_arrival_processor/
volumes:
- $PWD/swim_flight_history.sqb:/app/swim_flight_history.sqb:rw
depends_on:
- redis
labels:
- "traefik.enable=false"
swim-consumer-watchdog:
restart: always
image: swim-consumer-watchdog
build: ./swim_consumer_watchdog/
volumes:
- /var/run/docker.sock:/var/run/docker.sock
depends_on:
- redis
labels:
- "traefik.enable=false"
swim-consumer-api:
restart: always
image: swim-consumer-api
build: ./swim_consumer_api/
volumes:
- $PWD/swim_flight_history.sqb:/code/swim_flight_history.sqb:ro
labels:
- "traefik.enable=true"
- "traefik.http.routers.swim-consumer-api.rule=Host(`swim-consumer.${MY_DOMAIN}`)"
- "traefik.http.routers.swim-consumer-api.entrypoints=websecure"
- "traefik.http.routers.swim-consumer-api.tls.certresolver=myresolver"
- "traefik.http.services.swim-consumer-api.loadbalancer.server.port=80"