Customizing the application for your environment

Most settings can and should be overridden to match your environment by including an in the server classpath for example in Jetty you can add the custom properties as {JETTY_HOME}/resources/


The default values for properties used in the map application is found in oskari-server/servlet-map/src/main/resources/ To override all or any of these you can add an file in your classpath.

Any existing property will be overridden and any new ones will be available through PropertyUtil methods in the application (for example PropertyUtil.get("propertyName")).


# set to true to get database populated with initial demo content

# true all ssl certs/hosts for debugging! configure certs on the server for production

# url path to call for ajax requests/action routes

# Supported locales, comma separated and default first

The properties also setup various url links for search service, GIS metadata, GeoServer myplaces, print service, etc that needs to be modified to match the server environment.

Environment variables

Environment variables can also be used to append or override any property set in properties files. Any set environment variable will take precedence over a property in properties files following the two rules:

  • To avoid issues with casing and dots with environment variables all environment variables have to be uppercased and use underscores (_) instead of dots (.)
  • To avoid conflicts with environment variables meant for other processes Oskari expects all environment variables to be prefixed with OSKARI_



# Using environment variables to override the configuration (bash example)
export OSKARI_DB_URL=jdbc:postgresql://localhost:2345/oskaridb
export OSKARI_DB_USERNAME=oskari2
export OSKARI_DB_PASSWORD=my-password

Last modified: Fri Mar 15 2024 14:11:33 GMT+0200 (Eastern European Standard Time)