Skip to content

Setup your own OHDM Server

BdmRt edited this page Sep 18, 2020 · 3 revisions

Prerequisites

Docker

We built a docker-compose file for linux systems. Installation of docker and docker-compose is mandatory, you can do it with the command: sudo snap install docker If you don't have snap on your system, you can install it before with the command: sudo apt install snapd

Other

You will need the function unzip, so install it this way: sudo apt install unzip

Docker Compose Files

You need the following files:

  • ohdm_master.yml
  • ohdm_geoserver.yml
  • ohdm_init.sh
  • postgres-init.sql
  • .env

Explanation of the files

ohdm_master.yml: > Here you can find the basic software which is needed for at least both attempts with geoserver/mapnik. It includes the postgis Image, the definition of a mapserver(its left empty for to overwrite/not start this on it's own), as well as the webapp, which starts a tomcat for the previously build webapp. ohdm_geoserver.yml: > This yaml file overwrites the mapserver definition with the geoserver image. ohdm_init.sh: > This is a small script we wrote to make the setup easier. It will download the geoserver zip file, unzip it and move it to the correct location. Otherwise the geoserver will not show up it's webpage. Also it will download the latest ohdm.war file from the other project, rename it and move it into the volume of the tomcat image. postgres-init.sql: > It's the general setup for postgis. This will be bound to the postgis image as an init script and initialize right after startup.(If it has been already initialized after the first time it will be ignored, so no worries). .env: > This includes the environment variables which will be placed inside the yaml files automatically. You can set it up as you wish(like location of the volumes, specific image versions,..)

Run the compose files

Right now there is the default process like the following: sudo docker-compose -f ohdm_master.yml -f ohdm_geoserver.yml up -d && sudo ./ohdm_init.sh After this, docker will load all necessary dependencies automatically and after the startup the initialization will load necessary files so the geoserver and the frontend is working.

Clone this wiki locally