Coder Social home page Coder Social logo

openstreetmap-tiles-docker's Introduction

OpenStreetMap Tile Server Container

This repository contains instructions for building a Docker image containing the OpenStreetMap tile serving software stack. It is based on the Switch2OSM instructions.

As well as providing an easy way to set up and run the tile serving software it also provides instructions for managing the back end database, allowing you to:

  • Create the database
  • Import OSM data into the database
  • Drop the database

Run docker run homme/openstreetmap-tiles for usage instructions.

About

The container runs Ubuntu 14.04 (Trusty) and is based on the phusion/baseimage-docker. It includes:

  • Postgresql 9.3
  • Apache 2.2
  • The latest Osm2pgsql code (at the time of image creation)
  • The latest Mapnik code (at the time of image creation)
  • The latest Mod_Tile code (at the time of image creation)

Issues

This is a work in progress and although generally adequate it could benefit from improvements. Please submit issues on GitHub. Pull requests are very welcome!

Usage

** install the docker context from git and build your own docker image

** run the bare map server, load the data and services, and save the image

  • docker run -it -v /docker/data/osm-postgresql:/var/lib/postgresql --name twstd twstd:v0 /bin/bash

  • docker attach twstd

  • cd /usr/local/sbin/

  • ./run initdb

  • ./run startdb

  • ./run createuser

  • ./run createdb

  • wget -O /data/import.pbf http://download.geofabrik.de/asia/taiwan-latest.osm.pbf

  • ./run import

  • Ctrl-p + Ctrl-q

  • docker commit -m full_loaded twstd twstd:v1

** launch the map server and test on the browser

  • docker run -it -p 80:80 -v /docker/data/osm-postgresql:/var/lib/postgresql --name twstd twstd:v1

  • cd /usr/local/sbin/

  • ./run startservices

  • use a browser to access the URL: http://localhost/

  • click the item '本地街圖 localstreetmap'

** update the map

  • docker attach twstd
  • cd /usr/local/sbin/
  • ./run updatemap
  • Ctrl-p + Ctrl-q

openstreetmap-tiles-docker's People

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.