-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
77 lines (70 loc) · 2.17 KB
/
docker-compose.yaml
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
version: '3.8'
services:
reverse-proxy:
image: traefik:v2.3
command:
- --providers.docker
- --providers.file.directory=/etc/traefik/dynamic
- --entryPoints.http.address=:80
- --entryPoints.https.address=:443
labels:
#Redirect HTTP -> HTTPS
- "traefik.enable=true"
- "traefik.http.routers.https-redirect.entrypoints=http"
- "traefik.http.routers.https-redirect.rule=HostRegexp(`{any:.*}`)"
- "traefik.http.routers.https-redirect.middlewares=https-redirect"
- "traefik.http.middlewares.https-redirect.redirectscheme.scheme=https"
ports:
- 80:80
- 443:443
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /etc/letsencrypt/live/embedd.ml/cert.pem:/secrets/cert.pem
- /etc/letsencrypt/live/embedd.ml/privkey.pem:/secrets/key.pem
- ./certs-traefik.yaml:/etc/traefik/dynamic/certs-traefik.yaml
api:
image: piotrgramacki/sma-backend:0.16
labels:
- "traefik.http.routers.api.entrypoints=https"
- "traefik.http.routers.api.tls=true"
- "traefik.http.routers.api.rule=Host(`api-politicians.embedd.ml`)"
- "traefik.http.services.api-service.loadbalancer.server.port=80"
env_file:
- env_files/twitter_credentials.env
- env_files/celery.env
environment:
- MAX_WORKERS=1
volumes:
- ./data/:/app/data/
embedding-worker:
image: piotrgramacki/sma-celery:processing
command: [ celery, --app=embedding.app, worker, --pool=solo, -Q, embedding ]
env_file:
- env_files/celery.env
depends_on:
- redis
volumes:
- ./models:/app/models/
processing-worker:
image: piotrgramacki/sma-celery:processing
command: [ celery, --app=processing.app, worker, -Q, processing ]
env_file:
- env_files/celery.env
depends_on:
- redis
volumes:
- ./models:/app/models/
cleaning-worker:
image: piotrgramacki/sma-celery:processing
command: [ celery, --app=cleaning.app, worker, -Q, cleaning ]
env_file:
- env_files/celery.env
depends_on:
- redis
- krnnt
krnnt:
image: djstrong/krnnt:1.0.0
redis:
image: redis:6.0.10
ports:
- 35672:6379