-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yaml
62 lines (56 loc) · 1.25 KB
/
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# Docker compose configuration file
#
# SERVICES:
# - db: PostgreSQL database
# - pgadmin: Web administration interface of PostgreSQL database
# - web: Web application (moliuWeb) powered by Django
# - nginx: Nginx web server used in production environment
version: "3.9"
services:
db:
image: postgres
volumes:
- pgdata:/var/lib/postgresql/data
environment:
- POSTGRES_DB=${POSTGRES_DB_NAME}
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
restart: always
pgadmin:
image: dpage/pgadmin4
volumes:
- pgadmindata:/var/lib/pgadmin
ports:
- "8101:80"
environment:
PGADMIN_DEFAULT_EMAIL: ${PGADMIN_DEFAULT_EMAIL}
PGADMIN_DEFAULT_PASSWORD: ${PGADMIN_DEFAULT_PASSWORD}
depends_on:
- db
restart: unless-stopped
web:
build: .
image: moliuweb
volumes:
- webstaticdata:/app/static
- webmediadata:/app/media
depends_on:
- db
env_file:
- .env
restart: always
nginx:
build: ./nginx
volumes:
- webstaticdata:/nginx/static
- webmediadata:/nginx/media
ports:
- "8100:8000"
depends_on:
- web
restart: always
volumes:
pgdata:
pgadmindata:
webstaticdata:
webmediadata: