forked from cdchushig/drscratchv3
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
39 lines (39 loc) · 883 Bytes
/
docker-compose.yml
File metadata and controls
39 lines (39 loc) · 883 Bytes
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
version: '2.1'
services:
db:
image: mysql:5.7
container_name: drscratchv3_database
ports:
- "3306:3306"
environment:
- MYSQL_DATABASE=${DRSCRATCH_DATABASE_NAME}
#- MYSQL_USER=${DRSCRATCH_DATABASE_USER}
- MYSQL_ROOT_PASSWORD=${DRSCRATCH_DATABASE_ROOT_PASSWORD}
healthcheck:
test: "/etc/init.d/mysql status"
timeout: 40s
retries: 10
volumes:
- dbdata:/var/run/mysqld
getsb3:
build: ./scratchapi
ports:
- "3000:3000"
web:
build: .
volumes:
- .:/var/www
command: bash -c "python manage.py migrate && python manage.py runserver 0.0.0.0:8000"
container_name: drscratchv3_django
user: "1000:1000"
ports:
- "8000:8000"
env_file:
- ./.env
stdin_open: true
tty: true
depends_on:
db:
condition: service_healthy
volumes:
dbdata: