-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
42 lines (39 loc) · 992 Bytes
/
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
version: "3.5"
services:
trovi:
container_name: trovi_web
image: ${DOCKER_IMAGE_LATEST}
restart: on-failure
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:${TROVI_PORT}/artifacts/?limit=1"]
timeout: 60s
retries: 3
env_file:
- .env
volumes:
- .:/project
- ./media:/media
- static:/static
ports:
- "127.0.0.1:${TROVI_PORT}:${TROVI_PORT}"
entrypoint: ["python3", "manage.py"]
command: ["runserver", "0.0.0.0:${TROVI_PORT}"]
depends_on:
- db
db:
container_name: trovi_db
image: mariadb:${DB_IMG_TAG}
restart: on-failure
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
timeout: 10s
retries: 10
environment:
MYSQL_ROOT_PASSWORD: ${DB_ROOT_PASSWORD}
MYSQL_DATABASE: ${DB_NAME}
MYSQL_USER: ${DB_USER}
MYSQL_PASSWORD: ${DB_PASSWORD}
volumes:
- ./db:/docker-entrypoint-initdb.d
volumes:
static: