forked from geoserver/docker
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcompose.yaml
54 lines (53 loc) · 1.78 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
52
53
54
version: '3'
services:
geoserver:
build:
context: .
args:
- GEOSERVER_VERSION=2.26.0
- CORS_ENABLED=true
- CORS_ALLOWED_METHODS=GET,POST,PUT,HEAD,OPTIONS
ports:
- "${GEOSERVER_PORT}:8080"
environment:
- RUN_UNPRIVILEGED=true
- RUN_WITH_USER_UID=${RUN_WITH_USER_UID}
- RUN_WITH_USER_GID=${RUN_WITH_USER_GID}
- INSTALL_EXTENSIONS=true
- STABLE_EXTENSIONS=wps,csw
- EXTRA_JAVA_OPTS=-Xms1G -Xmx2G
- POSTGRES_JNDI_ENABLED=true
- POSTGRES_JNDI_RESOURCE_NAME=jdbc/postgres
- POSTGRES_HOST=postgis
- POSTGRES_PORT=${POSTGIS_PORT}
- POSTGRES_DB=geoserver
- POSTGRES_USERNAME=geoserver
- POSTGRES_PASSWORD=geoserver
- HTTPS_ENABLED=${HTTPS_ENABLED}
# - HTTPS_KEYSTORE_FILE=${HTTPS_KEYSTORE_FILE}
- HTTPS_KEYSTORE_PASSWORD=${HTTPS_KEYSTORE_PASSWORD}
- HTTPS_KEY_ALIAS=${HTTPS_KEY_ALIAS}
volumes:
- ./geoserver_data:/opt/geoserver_data/:Z
- ./additional_libs:/opt/additional_libs:Z
healthcheck:
test: curl --fail "http://localhost:8080/geoserver/web/wicket/resource/org.geoserver.web.GeoServerBasePage/img/logo.png" || exit 1
interval: 1m
retries: 3
timeout: 20s
postgis:
image: postgis/postgis:17-3.4-alpine@sha256:5a1dbedac34e0e6663f8b7190d393339571f1cb3ecb2ab2f724524b4f3c7956e
ports:
- "${POSTGIS_PORT}:${POSTGIS_PORT}"
environment:
- POSTGRES_USERNAME=geoserver
- POSTGRES_PASSWORD=geoserver
- POSTGRES_DB=geoserver
- POSTGRES_PORT=${POSTGRES_PORT}
volumes:
- ./postgis/postgresql_data:/var/lib/postgresql/data:Z
healthcheck:
test: pg_isready -U geoserver -h localhost -p ${POSTGIS_PORT} -t 5 || exit 1
interval: 10s
retries: 5
timeout: 10s