-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.test_example.yml
77 lines (70 loc) · 1.67 KB
/
docker-compose.test_example.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
services:
rabbitmq:
container_name: "rabbitmq"
image: "dp3_rabbitmq"
build: "docker/rabbitmq"
ports:
- "5672:5672"
- "15672:15672"
environment:
DP3_APP_NAME: test
DP3_WORKER_NUM: 1
mongo:
image: mongo:latest
ports:
- "27017:27017"
environment:
MONGO_INITDB_ROOT_USERNAME: test
MONGO_INITDB_ROOT_PASSWORD: test
redis:
container_name: "redis"
image: redis
ports:
- "6379:6379"
command: [ "redis-server", "--appendonly", "yes" ]
receiver_api:
container_name: "dp3_api"
image: "dp3_interpreter"
build:
context: .
dockerfile: "docker/python/Dockerfile"
target: "base"
ports:
- "5000:5000"
working_dir: "/dp3/dp3/api"
environment:
HOST: "0.0.0.0"
APP_NAME: "test"
CONF_DIR: "/dp3/tests/test_example/config"
command: ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "5000" ]
worker:
container_name: "dp3_worker"
image: "dp3_interpreter"
build:
context: .
dockerfile: "docker/python/Dockerfile"
target: "base"
working_dir: "/dp3/"
command: [ "dp3", "worker", "test", "/dp3/tests/test_example/config", "0", "-v" ]
depends_on:
- rabbitmq
- mongo
- redis
insert_datapoints:
container_name: "dp3_datapoints_inserter"
image: "dp3_interpreter"
build:
context: .
dockerfile: "docker/python/Dockerfile"
target: "base"
working_dir: "/dp3"
network_mode: "host"
command:
- /bin/sh
- -c
- |
sleep 10
python tests/test_example/dps_gen_realtime.py
depends_on:
- receiver_api
- worker