A custom PostgreSQL Docker image based off GEOS 3.6.0 and PostGIS 2.3.1.
Run a PostgreSQL container and mount it to a persistent data directory outside.
In this example we start up the container and create a database openmaptiles
with the owner openmaptiles
and password openmaptiles
and mount our local directory ./data
as storage.
docker run \
-v $(pwd)/data:/var/lib/postgresql/data \
-e POSTGRES_DB="openmaptiles" \
-e POSTGRES_USER="openmaptiles" \
-e POSTGRES_PASSWORD="openmaptiles" \
-d openmaptiles/postgis
Unlike all other OpenMapTiles repositories, this repo uses a different set of environment variables to initialize the database - POSTGRES_*
. See (full documentation](https://hub.docker.com/_/postgres/).
docker build -t openmaptiles/postgis .