forked from codingforentrepreneurs/Django-Kubernetes
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
47 lines (45 loc) · 934 Bytes
/
docker-compose.yaml
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
version: "3.9"
services:
# web:
# depends_on:
# - postgres_db
# build:
# context: ./web
# dockerfile: Dockerfile
# image: django-k8s:v1
# environment:
# - PORT=8020
# env_file:
# - web/.env
# ports:
# - "8001:8020"
# command: sh -c "chmod +x /app/migrate.sh && sh /app/migrate.sh && /app/entrypoint.sh"
# volumes:
# - staticfiles:/app/staticfiles/
postgres_db:
image: postgres
restart: always
command: -p 5434
env_file:
- web/.env
expose:
- 5434
ports:
- "5434:5434"
volumes:
- postgres_data:/var/lib/postgresql/data/
redis_db:
image: redis
restart: always
expose:
- 6388
ports:
- "6388:6388"
volumes:
- redis_data:/data
entrypoint: redis-server --appendonly yes --port 6388
volumes:
# staticfiles:
# external: true
postgres_data:
redis_data: