-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
41 lines (39 loc) · 936 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
version: "3"
services:
db:
image: mysql:latest
container_name: meetiadb
environment:
MYSQL_ROOT_PASSWORD: f82ldKX7591b
MYSQL_DATABASE: meetia
MYSQL_USER: admin
MYSQL_PASSWORD: v3oS9c83rZmD
volumes:
- mysql_data:/var/lib/mysql
hostname: meetiadb
networks:
- mynet
appserver:
depends_on:
- db
build:
context: .
dockerfile: Dockerfile
image: meetia-app:latest
container_name: meetiaappserver
ports:
- "8000:8000"
environment:
MYSQL_ROOT_PASSWORD: f82ldKX7591b
hostname: meetiaappserver
command: /bin/bash -c "sleep 20 && source myenv/bin/activate && python3.6 manage.py makemigrations && python3.6 manage.py migrate && python3 manage.py runserver 0.0.0.0:8000"
volumes:
- media-volume:/app/media
networks:
- mynet
volumes:
mysql_data:
media-volume:
networks:
mynet:
driver: bridge