NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum

Hi everyone. I have used Nominatim on my machine already through a docker installation: installed docker image and installed PostgreSQL + postgis on my machine. My next goal is to make Nominatim independent of my machine and install both the database it is using and the nominatim instance itself in a docker container / or two separate containers.

So I'm thinking either of having two docker containers: one having nominatim and one having the database. Then tell nominatim that it can find the database in the docker container. Both containers have to be started and run at the same time.

So when I installed Nominatim on my machine, I used this guide: https://hub.docker.com/r/stefanreuter/nominatim

Now the main question would be how to change this part: docker run -t -v /home/me/nominatimdata:/data nominatim sh /app/init.sh /data/merged.osm.pbf postgresdata 4. The italic part is where I specify where to save the data that will be created for nominatim. I want this to be in the docker image of the database.

Has anyone tried combining the db and Nominatim using docker compose?

Has anyone ever tried this and can share information on how to do this or is this not possible because of some reasons?

I would love to hear your thoughts! Arusha

asked 09 Aug '21, 09:07

Arusha29's gravatar image

Arusha29
11114
accept rate: 0%

edited 09 Aug '21, 11:35


https://github.com/mediagis/nominatim-docker is well maintained and you can ask questions in their issue tracker. https://github.com/mediagis/nominatim-docker/issues?q=docker-compose It's much easier to have a separate database container.

In your docker compose configuration file you'd do something like

services: nominatim: image: ... ... depends_on: - db db: image: ... ...

permanent link

answered 09 Aug '21, 13:30

mtmail's gravatar image

mtmail
4.8k1574
accept rate: 27%

Thanks for your reply, I hadn't seen there were issues already open for docker-compose on GitHub (Google didn't direct me there..) I will try this!

permanent link

answered 12 Aug '21, 09:05

Arusha29's gravatar image

Arusha29
11114
accept rate: 0%

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×689
×34
×11
×10
×1

question asked: 09 Aug '21, 09:07

question was seen: 5,767 times

last updated: 12 Aug '21, 09:05

NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum