-
Notifications
You must be signed in to change notification settings - Fork 3
/
docker-compose.yml
151 lines (142 loc) · 3.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
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
version: "3.8"
services:
api:
build:
context: .
dockerfile: Dockerfile
restart: always
depends_on:
- meilisearch
env_file:
- .env
labels:
- "traefik.enable=true"
- "traefik.http.routers.api.middlewares=default-headers@file"
- "traefik.http.routers.api.rule=Host(`api.kinopoisk.dev`) && (PathPrefix(`/v1/`) || PathPrefix(`/v1.`))"
- "traefik.http.routers.api.priority=10"
- "traefik.http.routers.api.entrypoints=https"
- "traefik.http.routers.api.tls.certresolver=certbot"
- "traefik.http.services.api.loadbalancer.server.port=3000"
logging:
driver: fluentd
options:
fluentd-async: "true"
fluentd-address: localhost:24224
tag: api
networks:
- traefik
deploy:
replicas: 4
cloud-api:
build:
context: .
dockerfile: Dockerfile
restart: always
depends_on:
- meilisearch
env_file:
- .env
labels:
- "traefik.enable=true"
- "traefik.http.routers.cloud-api.middlewares=default-headers@file"
- "traefik.http.routers.cloud-api.rule=Host(`cloud-api.kinopoisk.dev`) && (PathPrefix(`/v1/`) || PathPrefix(`/v1.`))"
- "traefik.http.routers.cloud-api.priority=10"
- "traefik.http.routers.cloud-api.entrypoints=https"
- "traefik.http.routers.cloud-api.tls.certresolver=certbot"
- "traefik.http.services.cloud-api.loadbalancer.server.port=3000"
logging:
driver: fluentd
options:
fluentd-async: "true"
fluentd-address: localhost:24224
tag: api
networks:
- traefik
deploy:
replicas: 2
sync-api:
build:
context: .
dockerfile: Dockerfile
restart: always
depends_on:
- meilisearch
env_file:
- .env
logging:
driver: fluentd
options:
fluentd-async: "true"
fluentd-address: localhost:24224
tag: api
networks:
- traefik
deploy:
replicas: 1
api_old:
build:
context: ../kinopoiskdev_old
dockerfile: Dockerfile
restart: always
env_file:
- ../kinopoiskdev_old/.env
labels:
- "traefik.enable=true"
- "traefik.http.routers.api-old.middlewares=default-headers@file"
- "traefik.http.routers.api-old.rule=Host(`api.kinopoisk.dev`) && PathPrefix(`/`)"
- "traefik.http.routers.api-old.priority=1"
- "traefik.http.routers.api-old.entrypoints=https"
- "traefik.http.routers.api-old.tls.certresolver=certbot"
- "traefik.http.services.api-old.loadbalancer.server.port=5000"
logging:
driver: fluentd
options:
fluentd-async: "true"
fluentd-address: localhost:24224
tag: api_old
networks:
- traefik
deploy:
replicas: 2
cloud-api_old:
build:
context: ../kinopoiskdev_old
dockerfile: Dockerfile
restart: always
env_file:
- ../kinopoiskdev_old/.env
labels:
- "traefik.enable=true"
- "traefik.http.routers.cloud-api-old.middlewares=default-headers@file"
- "traefik.http.routers.cloud-api-old.rule=Host(`cloud-api.kinopoisk.dev`) && PathPrefix(`/`)"
- "traefik.http.routers.cloud-api-old.priority=1"
- "traefik.http.routers.cloud-api-old.entrypoints=https"
- "traefik.http.routers.cloud-api-old.tls.certresolver=certbot"
- "traefik.http.services.cloud-api-old.loadbalancer.server.port=5000"
logging:
driver: fluentd
options:
fluentd-async: "true"
fluentd-address: localhost:24224
tag: api_old
networks:
- traefik
deploy:
replicas: 2
meilisearch:
image: getmeili/meilisearch
user: root
volumes:
- meili_data:/meili_data/
restart: always
environment:
MEILISEARCH_HOST: http://meilisearch:7700
MEILI_MASTER_KEY: ${MEILI_API_KEY}
networks:
- traefik
volumes:
meili_data:
networks:
traefik:
name: traefik_proxy
external: true