Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@zubair1024
Created December 21, 2019 21:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zubair1024/ef819324bc16c8428f53817d548c37fd to your computer and use it in GitHub Desktop.
Save zubair1024/ef819324bc16c8428f53817d548c37fd to your computer and use it in GitHub Desktop.

Setup Nominatim using Docker

  • Download map layer

wget https://download.geofabrik.de/asia/gcc-states-latest.osm.pbf

  • Clone Repo

git clone https://github.com/zubair1024/dockerized-nominatim.git

  • Build the docker image

docker build -t nominatim .

  • Init postgres database with data

docker run -t -v /home/me/nominatimdata:/data nominatim sh /app/init.sh /data/gcc-states-latest.osm.pbf postgresdata 4

Note: Where 4 is the number of threads to use during import. This process usually takes hours/days.

  • Run the server

docker run --restart=always -p 6432:5432 -p 7070:8080 -d --name nominatim -v /home/me/nominatimdata/postgresdata:/var/lib/postgresql/11/main nominatim bash /app/start.sh
Voila! You're done.

Happy Grizzly Coding!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment