-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
49 lines (43 loc) · 1.36 KB
/
docker-compose.yml
File metadata and controls
49 lines (43 loc) · 1.36 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
# docker-compose build
# docker-compose up -d
version: '2'
volumes:
dbbackups:
postgis-data:
services:
db:
image: maxboh/postgis_pgrepack_kmeans_plpythonu:${PG_MAJOR}-${POSTGIS_VERSION}-${PGROUTING_VERSION}
volumes:
- '${LOCAL_DATA_DIR}:/var/lib/postgresql/${PG_MAJOR}/main'
- '${LOCAL_CONFIG_DIR}:/etc/postgresql/${PG_MAJOR}/main'
- '${LOCAL_BACKUPDATA_DIR}:/backups'
environment:
- POSTGRES_DB=${POSTGRES_DB}
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASS=${POSTGRES_PASS}
#- ALLOW_IP_RANGE=0.0.0.0/0
- DESTROY_DATABASE_ON_RESTART=False
ports:
- ${LOCAL_POSTGRES_PORT}:5432
# for the initialization of a new database
# and creating new postgresql.config and pg_hba.conf files,
# uncomment the following entrypoint:
#entrypoint: /docker-entrypoint.sh
restart: unless-stopped
## uncomment, if you want to start the replication database
# dbbackups:
# image: maxboh/postgis_pgrepack_kmeans_plpythonu:latest
# hostname: pg-backups
# volumes:
# - '${LOCAL_CONFIG_DIR}:/etc/postgresql/${PG_MAJOR}/main'
# - '${LOCAL_BACKUPDATA_DIR}:/backups'
# links:
# - db:db
# environment:
# - DUMPPREFIX=demo
# - PGUSER=docker
# - PGPASSWORD=docker
# - PGDATABASE=gis
# - PGPORT=5432
# - PGHOST=db
# restart: unless-stopped