GeoServer docker image
 
 
Go to file
Nils Bühner a03ee5ae96 Switch to OpenJDK 11 2020-12-17 16:52:53 +01:00
scripts Switch to OpenJDK 11 2020-12-17 16:52:53 +01:00
.gitignore Switch to OpenJDK 11 2020-12-17 16:52:53 +01:00
Dockerfile Switch to OpenJDK 11 2020-12-17 16:52:53 +01:00
README.md Switch to OpenJDK 11 2020-12-17 16:52:53 +01:00

README.md

Docker GeoServer image

This docker GeoServer image is based on the following proposal:

https://github.com/geoserver/geoserver/wiki/GSIP-192

Work is still in progress!

How it works

  1. The Dockerfile
    1. installs dependencies
    2. installs the GeoServer by downloading and extracting the war file
    3. defines defaults for environment variables
  2. The entrypoint.sh startup script (in a running container)
    1. executes install-extensions.sh to download and install GeoServer extensions based on the STABLE_EXTENSIONS environment variable.
    2. handles the GEOSERVER_OPTS
    3. starts the tomcat

Building

docker build -t geoserver:test .

Running

docker run -it -e STABLE_EXTENSIONS='wps,csw' -p 8080:8080 geoserver:test

The extensions will be downloaded on startup of the image (before starting the tomcat).

Configuration

Pass as environment variables. If not passed, the default values will be used.

  • GEOSERVER_DATA_DIR (default: /opt/geoserver_data)
  • INITIAL_MEMORY (default: 2G)
  • MAXIMUM_MEMORY (default: 4G)
  • JAIEXT_ENABLED (default: true)
  • STABLE_EXTENSIONS as comma separated list, will be downloaded and installed on startup (default: "")

TODOs

  • CORS
  • configuration of JNDI connections in the tomcat/custom tomcat configuration in general
  • default data for gs datadir?
  • possibility to add custom java dependencies (for example the oracle jdbc driver)
    • in this context: mount EXTENSION_DOWNLOAD_DIR and implement checks to cache extensions that have already been downloaded before?
  • log4j properties
  • add possibility to add custom fonts
  • starting from which version we want to provide geoserver images (maybe 2.15.x?)/backwards compatability
  • add a docker-compose demo environment?