forked from saule1508/pgcluster
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose-single.yml
More file actions
68 lines (65 loc) · 2.18 KB
/
docker-compose-single.yml
File metadata and controls
68 lines (65 loc) · 2.18 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
version: '3.2'
services:
pg01:
image: pg:${pg_version:-0.7.4}
environment:
NODE_ID: 1
NODE_NAME: pg01
INITIAL_NODE_TYPE: single
REPMGRPWD: rep123
MSLIST: "asset,ingest,playout"
# for each micro-service two db users are created, for ex. asset_owner and asset_user, etc.
MSOWNERPWDLIST: "asset_owner,ingest_owner,playout_owner"
MSUSERPWDLIST: "asset_user,ingest_user,playout_user"
ports:
- 5432:5432 # postgres port
networks:
- pgcluster_network
volumes:
- pg01db:/u01/pg10/data
- pg01arc:/u02/archive
- pg01backup:/u02/backup
pgpool:
image: pgpool:${pg_version:-0.7.4}
command: tail -f /etc/hosts
environment:
PG_BACKEND_NODE_LIST: 0:pg01:5432:1:/u01/pg10/data:ALLOW_TO_FAILOVER
# csv list of backend postgres databases, each backend db contains (separated by :)
# number (start with 0):host name:pgpool port (default 9999):data dir (default /u01/pg96/data):flag ALLOW_TO_FAILOVER or DISALLOW_TO_FAILOVER
REPMGRPWD: rep123
PGPOOL_FAIL_OVER_ON_BACKEND_ERROR: "no"
PGPOOL_LOAD_BALANCE_MODE: "no"
#DELEGATE_IP: 172.18.0.100
#TRUSTED_SERVERS: 172.23.1.250
#PGP_HEARTBEATS: "0:pgpool01:9694,1:pgpool02:9694"
#PGP_OTHERS: "0:pgpool02:9999"
# csv list of other pgpool nodes, each node contains (separated by :)
# number (start with 0):host name:pgpool port (default 9999)
# not needed when there is a single pgpool node
ports:
- 9999:9999
networks:
- pgcluster_network
depends_on:
- pg01
manager:
image: manager:${pg_version:-0.7.4}
ports:
- 8080:8080
# to test the nodejs app, uncomment next line. Then once the container is running, exec into it and start node manually.
#command: tail -f /etc/passwd
environment:
PG_BACKEND_NODE_LIST: 0:pg01:5432:1:/u01/pg10/data:ALLOW_TO_FAILOVER
REPMGRPWD: rep123
DBHOST: pgpool
networks:
- pgcluster_network
volumes:
- /var/run/docker.sock:/var/run/docker.sock
volumes:
pg01db:
pg01arc:
pg01backup:
networks:
pgcluster_network:
external: true