-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.production.yml
119 lines (114 loc) · 8.15 KB
/
docker-compose.production.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
version: "3.4"
services:
redis:
volumes:
- /data/redis:/data
mongo:
volumes:
- /data/mongo:/data/db
worker:
environment:
- API_TOKEN=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiIsImtpZCI6IjI4YTMxOGY3LTAwMDAtYTFlYi03ZmExLTJjNzQzM2M2Y2NhNSJ9.eyJpc3MiOiJzdXBlcmNlbGwiLCJhdWQiOiJzdXBlcmNlbGw6Z2FtZWFwaSIsImp0aSI6ImM1MWE5ZWE5LWNhOGYtNDE2Ni1hYTU2LTU4ZGI3OTEyMDJhYSIsImlhdCI6MTY2MTg4NTAxMSwic3ViIjoiZGV2ZWxvcGVyLzJhZmZkZDVkLTM5Y2QtMDEyOC1lMjAyLTE4ZGRlMzk5ODlhNyIsInNjb3BlcyI6WyJjbGFzaCJdLCJsaW1pdHMiOlt7InRpZXIiOiJkZXZlbG9wZXIvc2lsdmVyIiwidHlwZSI6InRocm90dGxpbmcifSx7ImNpZHJzIjpbIjY0LjIyNy4xMDMuMTM3Il0sInR5cGUiOiJjbGllbnQifV19.NQ6NNDpRsUYFQFvL6Bx_zSkhyreBjqo52IL7Fcvs_mOFuLbnpW5oV9tSroOcC0k31ZkaGB9GxXV0L10toHfzyg,eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiIsImtpZCI6IjI4YTMxOGY3LTAwMDAtYTFlYi03ZmExLTJjNzQzM2M2Y2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API_KEY=cdb173414b6d879639165cedcc730d73
- WORKER_OFFSET={{.Task.Slot}}
deploy:
replicas: 3
resources:
limits:
memory: 400m
rq_calculation_worker:
environment:
- API_TOKEN=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiIsImtpZCI6IjI4YTMxOGY3LTAwMDAtYTFlYi03ZmExLTJjNzQzM2M2Y2NhNSJ9.eyJpc3MiOiJzdXBlcmNlbGwiLCJhdWQiOiJzdXBlcmNlbGw6Z2FtZWFwaSIsImp0aSI6IjUwZDVkMDg1LTViZGItNDhmZC04ZmJiLTUzM2IzY2YwOTZmMCIsImlhdCI6MTY2MTg4NTA1MSwic3ViIjoiZGV2ZWxvcGVyLzJhZmZkZDVkLTM5Y2QtMDEyOC1lMjAyLTE4ZGRlMzk5ODlhNyIsInNjb3BlcyI6WyJjbGFzaCJdLCJsaW1pdHMiOlt7InRpZXIiOiJkZXZlbG9wZXIvc2lsdmVyIiwidHlwZSI6InRocm90dGxpbmcifSx7ImNpZHJzIjpbIjY0LjIyNy4xMDMuMTM3Il0sInR5cGUiOiJjbGllbnQifV19.s95KRTGVtF1AEZu0ivpEHy2B9_5MQLfo-CoWLWS3-a1lBL_Ww6tqIVlYQ2q6t9gRUvyVZV0cPgSXw4OmeQwCGA
- BUGSNAG_API_KEY=cdb173414b6d879639165cedcc730d73
deploy:
resources:
limits:
memory: 200m
rq_war_worker:
environment:
- API_TOKEN=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiIsImtpZCI6IjI4YTMxOGY3LTAwMDAtYTFlYi03ZmExLTJjNzQzM2M2Y2NhNSJ9.eyJpc3MiOiJzdXBlcmNlbGwiLCJhdWQiOiJzdXBlcmNlbGw6Z2FtZWFwaSIsImp0aSI6IjUwZDVkMDg1LTViZGItNDhmZC04ZmJiLTUzM2IzY2YwOTZmMCIsImlhdCI6MTY2MTg4NTA1MSwic3ViIjoiZGV2ZWxvcGVyLzJhZmZkZDVkLTM5Y2QtMDEyOC1lMjAyLTE4ZGRlMzk5ODlhNyIsInNjb3BlcyI6WyJjbGFzaCJdLCJsaW1pdHMiOlt7InRpZXIiOiJkZXZlbG9wZXIvc2lsdmVyIiwidHlwZSI6InRocm90dGxpbmcifSx7ImNpZHJzIjpbIjY0LjIyNy4xMDMuMTM3Il0sInR5cGUiOiJjbGllbnQifV19.s95KRTGVtF1AEZu0ivpEHy2B9_5MQLfo-CoWLWS3-a1lBL_Ww6tqIVlYQ2q6t9gRUvyVZV0cPgSXw4OmeQwCGA
- BUGSNAG_API_KEY=cdb173414b6d879639165cedcc730d73
deploy:
replicas: 1
resources:
limits:
memory: 400m
cron:
environment:
- API_TOKEN=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiIsImtpZCI6IjI4YTMxOGY3LTAwMDAtYTFlYi03ZmExLTJjNzQzM2M2Y2NhNSJ9.eyJpc3MiOiJzdXBlcmNlbGwiLCJhdWQiOiJzdXBlcmNlbGw6Z2FtZWFwaSIsImp0aSI6IjUwZDVkMDg1LTViZGItNDhmZC04ZmJiLTUzM2IzY2YwOTZmMCIsImlhdCI6MTY2MTg4NTA1MSwic3ViIjoiZGV2ZWxvcGVyLzJhZmZkZDVkLTM5Y2QtMDEyOC1lMjAyLTE4ZGRlMzk5ODlhNyIsInNjb3BlcyI6WyJjbGFzaCJdLCJsaW1pdHMiOlt7InRpZXIiOiJkZXZlbG9wZXIvc2lsdmVyIiwidHlwZSI6InRocm90dGxpbmcifSx7ImNpZHJzIjpbIjY0LjIyNy4xMDMuMTM3Il0sInR5cGUiOiJjbGllbnQifV19.s95KRTGVtF1AEZu0ivpEHy2B9_5MQLfo-CoWLWS3-a1lBL_Ww6tqIVlYQ2q6t9gRUvyVZV0cPgSXw4OmeQwCGA
- BUGSNAG_API_KEY=cdb173414b6d879639165cedcc730d73
imgproxy:
environment:
- IMGPROXY_KEY=15c1f2542afea936263aaf8a5244e0f2edf7bfb54dec26fb19b12133ad02869b254d71587227d3a58e43fb6885f1290cb158ab31e62d4f6361c50f21e089883a
- IMGPROXY_SALT=95490c60f0bba290a0ae56e897ad5a9a7845ca375ca9922d07bbfacb62453c05165048c75fb3488018f34115c98ec2fb7a1c7e1a4508cd20233ad9b2190986e5
imgproxy-cache:
deploy:
labels:
- traefik.enable=true
- traefik.http.routers.imgproxy.rule=Host(`i.clashleaders.com`)
- traefik.http.routers.imgproxy.tls.certresolver=myresolver
- traefik.http.routers.imgproxy.middlewares=i_headers
- traefik.http.services.imgproxy.loadbalancer.server.port=80
- traefik.http.middlewares.i_headers.headers.browserXssFilter=true
- traefik.http.middlewares.i_headers.headers.contentTypeNosniff=true
- traefik.http.middlewares.i_headers.headers.forceSTSHeader=true
- traefik.http.middlewares.i_headers.headers.stsSeconds=315360000
- traefik.http.middlewares.i_headers.headers.sslredirect=true
- traefik.http.middlewares.i_headers.headers.sslForceHost=true
networks:
- web
- default
web:
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost/healthcheck"]
volumes:
- /data/caddy:/root/.caddy
deploy:
replicas: 1
resources:
limits:
memory: 700m
update_config:
parallelism: 1
order: start-first
failure_action: rollback
delay: 10s
restart_policy:
condition: any
delay: 5s
max_attempts: 3
window: 120s
labels:
- traefik.enable=true
- traefik.http.routers.nowww.rule=Host(`clashleaders.com`)
- traefik.http.routers.nowww.entrypoints=web
- traefik.http.routers.nowww.middlewares=web_headers
- traefik.http.routers.web.rule=Host(`www.clashleaders.com`)
- traefik.http.routers.web.entrypoints=web
- traefik.http.routers.web.middlewares=web_headers
- traefik.http.routers.websecured.rule=Host(`www.clashleaders.com`)
- traefik.http.routers.websecured.entrypoints=websecure
- traefik.http.routers.websecured.tls.certresolver=myresolver
- traefik.http.routers.websecured.middlewares=web_headers
- traefik.http.services.websecured.loadbalancer.server.port=80
- traefik.http.middlewares.web_headers.headers.browserXssFilter=true
- traefik.http.middlewares.web_headers.headers.contentTypeNosniff=true
- traefik.http.middlewares.web_headers.headers.frameDeny=true
- traefik.http.middlewares.web_headers.headers.forceSTSHeader=true
- traefik.http.middlewares.web_headers.headers.stsSeconds=315360000
- traefik.http.middlewares.web_headers.headers.sslredirect=true
- traefik.http.middlewares.web_headers.headers.sslForceHost=true
- traefik.http.middlewares.web_headers.headers.sslHost=www.clashleaders.com
- traefik.http.middlewares.web_headers.headers.stsPreload=true
environment:
- API_TOKEN=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiIsImtpZCI6IjI4YTMxOGY3LTAwMDAtYTFlYi03ZmExLTJjNzQzM2M2Y2NhNSJ9.eyJpc3MiOiJzdXBlcmNlbGwiLCJhdWQiOiJzdXBlcmNlbGw6Z2FtZWFwaSIsImp0aSI6IjRlNWU1MTBlLTNiZmMtNDMzNy1iNGZlLTI4MzUzYThiODI2YyIsImlhdCI6MTY2MTg4NTAwMSwic3ViIjoiZGV2ZWxvcGVyLzJhZmZkZDVkLTM5Y2QtMDEyOC1lMjAyLTE4ZGRlMzk5ODlhNyIsInNjb3BlcyI6WyJjbGFzaCJdLCJsaW1pdHMiOlt7InRpZXIiOiJkZXZlbG9wZXIvc2lsdmVyIiwidHlwZSI6InRocm90dGxpbmcifSx7ImNpZHJzIjpbIjY0LjIyNy4xMDMuMTM3Il0sInR5cGUiOiJjbGllbnQifV19.yUDhzgXjrvcjalZ6Q41wSz7jc9XEVdeh3ckskWQ35Aveqmwk5v-pH6EP_1FxkXdfFP1VcCAS6MXEMYc5wU6BCQ
- BUGSNAG_API_KEY=cdb173414b6d879639165cedcc730d73
- IMGPROXY_KEY=15c1f2542afea936263aaf8a5244e0f2edf7bfb54dec26fb19b12133ad02869b254d71587227d3a58e43fb6885f1290cb158ab31e62d4f6361c50f21e089883a
- IMGPROXY_SALT=95490c60f0bba290a0ae56e897ad5a9a7845ca375ca9922d07bbfacb62453c05165048c75fb3488018f34115c98ec2fb7a1c7e1a4508cd20233ad9b2190986e5
- IMGPROXY_BASE=https://i.clashleaders.com/
networks:
- web
- default
networks:
web:
external: true