-
Notifications
You must be signed in to change notification settings - Fork 0
/
compose.yaml
51 lines (48 loc) · 1.26 KB
/
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
services:
postgres:
container_name: postgres
image: postgres:latest
volumes:
- ./initdb:/docker-entrypoint-initdb.d
- ./pgdata:/var/lib/postgresql/data
- ./pgbackup:/var/lib/postgresql/backup
- ./config/postgresql/postgresql.conf:/etc/postgresql/postgresql.conf
- ./config/postgresql/pg_hba.conf:/etc/postgresql/pg_hba.conf
ports:
- "5432:5432"
environment:
POSTGRES_PASSWORD_FILE: /run/secrets/postgres_pw
PYBOSSA_PASSWORD_FILE: /run/secrets/pybossa_pw
restart: always
secrets:
- postgres_pw
- pybossa_pw
networks:
- postgres-net
pgadmin:
container_name: pgadmin
image: dpage/pgadmin4:latest
volumes:
- ./config/pgadmin/servers.json:/pgadmin4/servers.json
environment:
PGADMIN_DEFAULT_PASSWORD_FILE: /run/secrets/pgadmin_pw
PGADMIN_LISTEN_PORT: 8080
ports:
- "8080:8080"
restart: always
secrets:
- pgadmin_pw
networks:
- postgres-net
env_file:
- ./config/pgadmin/.env
secrets:
postgres_pw:
file: ./config/secrets/postgres_pw.txt
pybossa_pw:
file: ./config/secrets/pybossa_pw.txt
pgadmin_pw:
file: ./config/secrets/pgadmin_pw.txt
networks:
postgres-net:
name: pybossa-postgres-net