-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
164 lines (162 loc) · 4.17 KB
/
docker-compose.yml
File metadata and controls
164 lines (162 loc) · 4.17 KB
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
152
153
154
155
156
157
158
159
160
161
162
163
164
services:
pyro_api:
container_name: api
image: pyronear/alert-api:latest
command: "sh -c 'python app/db.py && uvicorn app.main:app --reload --host 0.0.0.0 --port 5050 --proxy-headers'"
ports:
- 5050:5050
environment:
- DEBUG=true
- POSTGRES_URL=postgresql+asyncpg://dummy_pg_user:dummy_pg_pwd@db/dummy_pg_db
- SQLALCHEMY_SILENCE_UBER_WARNING=1
- SUPERADMIN_LOGIN=${SUPERADMIN_LOGIN}
- SUPERADMIN_PWD=${SUPERADMIN_PWD}
- SUPERADMIN_ORG=admin
- S3_ENDPOINT_URL=${S3_ENDPOINT_URL}
- S3_ACCESS_KEY=${S3_ACCESS_KEY}
- S3_SECRET_KEY=${S3_SECRET_KEY}
- S3_REGION=${S3_REGION}
healthcheck:
test: ["CMD-SHELL", "curl -X 'GET' 'http://pyro_api:5050/status' -H 'accept: application/json'"]
interval: 20s
timeout: 10s
retries: 10
depends_on:
db:
condition: service_healthy
minio:
condition: service_healthy
db:
image: postgres:15-alpine
ports:
- 5432:5432
environment:
- POSTGRES_USER=dummy_pg_user
- POSTGRES_PASSWORD=dummy_pg_pwd
- POSTGRES_DB=dummy_pg_db
healthcheck:
test: [CMD-SHELL, sh -c 'pg_isready -U dummy_pg_user -d dummy_pg_db']
interval: 20s
timeout: 10s
retries: 10
minio:
image: minio/minio:RELEASE.2025-09-07T16-13-09Z-cpuv1
container_name: minio
ports:
- "9000:9000"
- "9001:9001"
environment:
- MINIO_ROOT_USER=${S3_ACCESS_KEY}
- MINIO_ROOT_PASSWORD=${S3_SECRET_KEY}
volumes:
- minio_data:/data
command: server /data --console-address ":9001"
healthcheck:
test: ["CMD", "mc", "ready", "local"]
interval: 10s
timeout: 10s
retries: 5
pyro_camera_api:
image: pyronear/pyro-camera-api:latest
profiles:
- engine
environment:
- CAM_USER=${CAM_USER}
- CAM_PWD=${CAM_PWD}
- MEDIAMTX_SERVER_IP=${MEDIAMTX_SERVER_IP}
volumes:
- ./data:/usr/src/app/data
network_mode: host
logging:
driver: json-file
options:
max-size: 100m
max-file: '5'
engine:
image: pyronear/pyro-engine:latest
profiles:
- engine
environment:
- API_URL=http://localhost:5050
- CAM_USER=${CAM_USER}
- CAM_PWD=${CAM_PWD}
command: python run.py
volumes:
- ./data:/usr/src/app/data
network_mode: host
logging:
driver: json-file
options:
max-size: 100m
max-file: '5'
etl_scripts:
container_name: etl
image: pyronear/pyro-etl:latest
profiles:
- etl
environment:
- API_URL=${API_URL}
- SUPERADMIN_LOGIN=${SUPERADMIN_LOGIN}
- SUPERADMIN_PWD=${SUPERADMIN_PWD}
command: /bin/sh -c "python /usr/src/app/dl_images.py && python /usr/src/app/predict_load.py"
volumes:
- ./data:/usr/src/app/data
depends_on:
init_script:
condition: service_started
pyro_api:
condition: service_healthy
init_script:
container_name: init
image: pyronear/pyro-api-init:latest
environment:
- API_URL=${API_URL}
- SUPERADMIN_LOGIN=${SUPERADMIN_LOGIN}
- SUPERADMIN_PWD=${SUPERADMIN_PWD}
- SLACK_HOOK=${SLACK_HOOK}
volumes:
- ./data/:/data/
command: sh -c 'python /usr/local/bin/init_script.py && exit 0 || exit 1'
depends_on:
pyro_api:
condition: service_healthy
frontend:
image: pyronear/pyro-platform:latest
command: python index.py --host 0.0.0.0 --port 8050
profiles:
- front
ports:
- 8050:8050
environment:
- API_URL=${API_URL}
- API_LOGIN=${SUPERADMIN_LOGIN}
- API_PWD=${SUPERADMIN_PWD}
- DEBUG=FALSE
depends_on:
init_script:
condition: service_started
pyro_api:
condition: service_healthy
notebooks:
image: pyronear/notebooks:latest
profiles:
- tools
ports:
- 8889:8888
volumes:
- ./containers/notebooks/app:/app/notebooks
- ./data:/app/data
- .env:/app/.env
db-ui:
image: dpage/pgadmin4
profiles:
- tools
ports:
- "8888:80"
environment:
- PGADMIN_DEFAULT_EMAIL=${DB_UI_MAIL}
- PGADMIN_DEFAULT_PASSWORD=${DB_UI_PWD}
depends_on:
- db
volumes:
minio_data: