-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
41 lines (39 loc) · 1.1 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
version: '3'
# http://pawamoy.github.io/2018/02/01/docker-compose-django-postgres-nginx.html
# https://testdriven.io/blog/dockerizing-flask-with-postgres-gunicorn-and-nginx/
services:
django:
build: ./django
command: gunicorn --bind :8000 mysite.wsgi:application --capture-output
environment:
- MYSQL_HOST=db
- MYSQL_PORT=3306
- MODE=PROD
- DJANGO_LOGLEVEL=DEBUG
env_file:
- production.env
expose:
- 8000
restart: always
db:
image: mysql:8.0
command: --default-authentication-plugin=mysql_native_password
environment:
- MYSQL_RANDOM_ROOT_PASSWORD=yes
env_file:
- production.env
expose:
- 3306
restart: always
app:
build:
context: ./
args:
- VUE_APP_API_BASE_URL=http://ivanya.com/chelatase/api/
ports:
- 80:80
volumes:
- ./nginx/conf.d:/etc/nginx/conf.d
depends_on:
- django
restart: always