-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose.prod.yml
54 lines (49 loc) · 1.11 KB
/
docker-compose.prod.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
42
43
44
45
46
47
48
49
50
51
52
53
54
# Development docker compose.
version: "3"
services:
db:
container_name: sklecvis-db
image: postgres
restart: unless-stopped
environment:
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
volumes:
- sklec_vis_db:/var/lib/postgresql/data
ports:
- "5432:5432"
server:
container_name: sklecvis-server
build:
context: ./server
dockerfile: Dockerfile
command: docker/django-start-prod.sh
environment:
DJANGO_SETTINGS_MODULE: sklecvis.settings
DB_HOST: db
DB_PORT: 5432
DB_USERNAME: postgres
DB_PASSWORD: ${POSTGRES_PASSWORD}
DB_NAME: sklecvis
PYTHONPATH: /app
expose:
- "8000"
volumes:
- ./server:/app
depends_on:
- db
nginx:
container_name: sklecvis-nginx-prod
build:
context: ./client
dockerfile: Dockerfile
ports:
- "8061:80"
volumes:
- ./server/static/:/srv/server_static
- ./server/media/:/srv/server_media
# 监听文件夹
- /home/public/sklecvis-autoupload:/data/autoupload
depends_on:
- server
volumes:
sklec_vis_db: {}