docker-renderd-osm/README.md

47 lines
1.8 KiB
Markdown
Raw Normal View History

# docker-renderd-osm
2018-03-29 02:45:06 +03:00
A basic image for rendering/serving tiles using OpenStreetMap data from an external PostgreSQL instance.
## Build instructions
Build using
2018-03-29 02:45:06 +03:00
docker build -t vitalif/renderd-osm github.com/vitalif/docker-renderd-osm.git
## Running
2018-03-29 02:45:06 +03:00
This container is designed to work with an PostgreSQL instance
with PostGIS and osm2pgsql loaded database (for example,
[openfirmware/docker-postgres-osm](https://registry.hub.docker.com/u/openfirmware/postgres-osm/) +
[openfirmware/docker-osm2pgsql](https://registry.hub.docker.com/u/openfirmware/osm2pgsql/)).
2018-03-29 02:45:06 +03:00
To run this container with local PostgreSQL (not docker-packaged):
2018-03-29 02:45:06 +03:00
docker run --name renderd -it -d -p 8096:80 \
-v /var/run/postgresql:/var/run/postgresql \
--env PG_ENV_OSM_USER=<user> \
--env PG_ENV_OSM_DB=<database> \
--env PG_ENV_OSM_PASSWORD=<password> vitalif/renderd-osm
2018-03-29 02:45:06 +03:00
To run with postgresql from another docker container:
2018-03-29 02:45:06 +03:00
docker run --name renderd -it -d -p 8096:80 \
--link postgres-osm:pg \
--env PG_ENV_OSM_USER=<user> \
--env PG_ENV_OSM_DB=<database> \
--env PG_ENV_OSM_PASSWORD=<password> vitalif/renderd-osm
Once the container is up you should be able to see a small map of the
2018-03-29 02:45:06 +03:00
world once you point your browser to [http://127.0.0.1:8096/osm/0/0/0.png](http://127.0.0.1:8096/osm/0/0/0.png)
## Available Styles
* [openstreetmap-carto](https://github.com/gravitystorm/openstreetmap-carto),
available at [http://host/osm/0/0/0.png](http://host/osm/0/0/0.png)
* [osm-bright](https://github.com/mapbox/osm-bright)
available at [http://host/osmb/0/0/0.png](http://host/osmb/0/0/0.png)
## About
This Dockerfile has been put together using the [Debian Tileserver Install Guide](https://wiki.debian.org/OSM/tileserver/jessie)