-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathdocker-compose.yml
45 lines (41 loc) · 1.13 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
version: "3.7"
services:
postgres:
env_file:
- .env
image: postgres:12.2-alpine
volumes:
- ./postgres:/docker-entrypoint-initdb.d
rabbitmq:
image: rabbitmq:3.8.3-alpine
redis:
image: redis:5.0.8-alpine
web:
build: .
command: data_subscriptions run --host=0.0.0.0 --port=5500
depends_on:
- postgres
env_file:
- ./.env
environment:
- DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/${POSTGRES_USER}
- TEST_DATABASE_URL=postgresql://test:test@postgres:5432/test
ports:
- "5500:5500"
volumes:
- ./data_subscriptions:/code/data_subscriptions
- ./migrations:/code/migrations
- ./tests:/code/tests
worker:
build: .
command: celery -A data_subscriptions.worker.tasks worker -B --loglevel=INFO --schedule=/tmp/celerybeat-schedule
depends_on:
- postgres
- redis
- rabbitmq
env_file:
- ./.env
environment:
- DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/${POSTGRES_USER}
volumes:
- ./data_subscriptions:/code/data_subscriptions