-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
executable file
·87 lines (70 loc) · 2.01 KB
/
docker-compose.yml
File metadata and controls
executable file
·87 lines (70 loc) · 2.01 KB
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
version: '2'
services:
backend_blog_sv:
restart: unless-stopped
container_name: backend-blog
# This is for pulling image from docker hub
image : krishna2808/backend-blog:V1
# build is take the context and dockerfile location
# build:
# context: .
# dockerfile: Dockerfiles/Dockerfile_backend
volumes:
- backend_container_data:/app/backend/
ports:
- 8000:8000
environment:
DEBUG: "True"
CELERY_BROKER_URL: "redis://redis:6379/0"
CELERY_RESULT_BACKEND: "redis://redis:6379/0"
DJANGO_DB: blog
MYSQL_HOST: mysql-blog
MYSQL_NAME: mysql
MYSQL_USER: root
MYSQL_PASSWORD: password
MYSQL_PORT: 3306
depends_on:
- mysql_blog_sv
frontend_blog_sv:
container_name: frontend-blog
image : krishna2808/frontend-blog:V1
# build:
# context: .
# dockerfile: Dockerfiles/Dockerfile_frontend
ports:
- "3000:3000"
volumes:
- frontend_container_data:/app/frontend/
stdin_open: true
tty: true
# redis_blog:
# container_name: redis_blog
# restart: unless-stopped
# image: redis:7.0.5-alpine
# expose:
# - 6379
mysql_blog_sv:
# image: mysql:8
image: krishna2808/mysql-blog:V1
container_name: mysql-blog
environment:
MYSQL_ROOT_PASSWORD: password
MYSQL_DATABASE: blog
ports:
- 3306:3306
volumes:
- mysql_container_data:/var/lib/mysql
nginx_blog_sv:
# image: nginx:alpine
image: krishna2808/nginx-blog:V1
container_name: nginx-blog
build: nginx/
ports:
- 80:80
- 443:443
depends_on:
- backend_blog_sv
volumes:
mysql_container_data:
backend_container_data:
frontend_container_data: