-
Notifications
You must be signed in to change notification settings - Fork 8
/
docker-compose.yml
38 lines (36 loc) · 970 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
# Docker-compose.yml file for kagxin/django_project_template project
version: "3"
services:
mysql:
image: mysql:5.6
container_name: mysqldb
environment:
- MYSQL_ROOT_PASSWORD=root
- MYSQL_DATABASE=django_template
restart: always
command: [
'--character-set-server=utf8mb4',
'--collation-server=utf8mb4_unicode_ci',
'--default-time-zone=+8:00'
]
redis:
image: redis
container_name: redisdb
restart: always
django_template:
container_name: django_template_app
build:
context: .
dockerfile: Dockerfile
ports:
- "7000:8000"
environment:
- mysqlhost=mysqldb
- redishost=redisdb
depends_on:
- mysql
- redis
links:
- "mysql:mysqldb"
- "redis:redisdb"
restart: always