Skip to content

Commit 43d23b3

Browse files
authored
Merge pull request #243 from geoserver/update-compose-demo
feat: update docker compose demo
2 parents 0e1e2fa + 8567450 commit 43d23b3

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,13 @@ Run ``docker-compose``:
228228
```shell
229229
docker-compose -f docker-compose-demo.yml up --build
230230
```
231+
232+
In case of problems try something like
233+
234+
```shell
235+
docker-compose -f docker-compose-demo.yml down --remove-orphans
236+
```
237+
231238
## Environment Variables
232239

233240
Following is the list of the all the environment variables that can be passed down to the geoserver docker image, you can check the default values for an image using `docker inspect [IMAGE_NAME]`

docker-compose-demo.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,23 +20,27 @@ services:
2020
- POSTGRES_USERNAME=geoserver
2121
- POSTGRES_PASSWORD=geoserver
2222
- POSTGRES_JNDI_RESOURCE_NAME=jdbc/postgres
23+
- RUN_UNPRIVILEGED=true
24+
- RUN_WITH_USER_UID=1000 # you may change this to match your host user id
25+
- RUN_WITH_USER_GID=1000 # you may change this to match your host group id
2326
volumes:
2427
- ./geoserver_data:/opt/geoserver_data/:Z
2528
- ./additional_libs:/opt/additional_libs:Z # by mounting this we can install libs from host on startup
29+
- ./additional_fonts:/opt/additional_fonts:Z
2630
healthcheck:
2731
test: curl --fail "http://localhost:8080/geoserver/web/wicket/resource/org.geoserver.web.GeoServerBasePage/img/logo.png" || exit 1
2832
interval: 1m
2933
retries: 3
3034
timeout: 20s
3135
postgis:
32-
image: postgis/postgis:17-3.4-alpine@sha256:5a1dbedac34e0e6663f8b7190d393339571f1cb3ecb2ab2f724524b4f3c7956e
36+
image: postgis/postgis:18-3.6-alpine
3337
ports:
3438
- "5555:5432"
3539
environment:
3640
POSTGRES_USER: geoserver
3741
POSTGRES_PASSWORD: geoserver
3842
volumes:
39-
- ./postgis/postgresql_data:/var/lib/postgresql/data:Z
43+
- ./postgis/postgresql_data:/var/lib/postgresql:Z
4044
healthcheck:
4145
test: pg_isready -U geoserver -h localhost -t 5 || exit 1
4246
interval: 10s

0 commit comments

Comments
 (0)