-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgnaf_docker_compose.yaml
39 lines (38 loc) · 1.46 KB
/
gnaf_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
services:
db:
build:
context: .
dockerfile: ./gnaf_dockerfile
restart: "no"
container_name: gnaf_pg_service
hostname: gnaf_pg_db
image: gnaf_postgis:v1
shm_size: 1gb
user: postgres
group_add:
- "1000" # On Linux, change this to the group on ./data & ./scripts folders to avoid permissions issues with bind mounts, also host folders should have write/execute permission (774, 754) for the group, middle number should be either 7 or 5!! OR if host folder has 777, then no need for group_add...
environment:
POSTGRES_DB: geo # used in entrypoint script
POSTGRES_USER: postgres # used in entrypoint script
POSTGRES_PASSWORD: geogeo!
PGDATA: /var/lib/postgresql/data
GNAF_SCHEMA: gnaf # used in entrypoint script
USER_SCRIPTS: /scripts # used in entrypoint script
volumes:
- type: volume
source: db-data
target: /var/lib/postgresql/data
- type: bind
source: ./entrypoint_scripts/90_gnaf_db_setup.sh
target: /docker-entrypoint-initdb.d/90_gnaf_db_setup.sh
- type: bind
source: ./data # Extract GNAF data to this folder
target: /gnaf_data
- type: bind
source: ./scripts
target: /scripts
ports:
- "5432:5432"
volumes:
db-data:
name: "geo_db_volume"