Giter VIP home page Giter VIP logo

vt-map's Introduction

vt-map

GitHub Docker Cloud Automated build Docker Image Size (latest by date) Gitter

This is a simple tool to create vector tile map on Github pages.

This repository is no londer used. It has been moved to narwassco/vt!

Installation

tippecanoe

This module uses tippecanoe to convert geojson files to mbtiles. Please make sure to install it before running.

for MacOS

$ brew install tippecanoe

for Ubuntu

$ git clone https://github.com/mapbox/tippecanoe.git
$ cd tippecanoe
$ make -j
$ make install

main module

git clone https://github.com/narwassco/vt-map.git
npm install

Configuration

All the settings are in config.js, so please make sure your own settings on this file before producing vector tile.

Please create app-docker.env file under project root directory to put environment variable for database settings.

export_dir=/tmp/src/vt-map

db_user=postgres
db_password=Your password
db_host=host.docker.internal
db_post=5432
db_name=narwassco

The stylefile style.json under this repository is just for checking the vector tile data.

We are managing Mapbox Stylefile in narwassco/mapbox-stylefiles.

Create vector tile from your PostGIS database by using Docker

Build Docker Image

docker build -t narwassco/vt-map .

Create Vector Tile and sprite files under public directory.

docker-compose up

Create vector tile from your PostGIS database by using local Nodejs

It will retrieve the data from PostGIS as mbtiles format, then vector tiles (.mvt) were extracted under public/tiles folder.

npm run build

Deploy to gh-pages

It will push all of website contents under public folder to Github pages.

npm run deploy

License

This source code under the repository is licensed by MIT license. You can use it freely for your purposes.

However, these data under public is owned and maintained by Narok Water and Sewerage Services Company (NARWASSCO) in Kenya. It is under a Creative Commons Attribution 4.0 International License, which is different from main repository. You can use this data freely, but please mention our credit ©NARWASSCO,Ltd. on attribution of your web application.


Copyright (c) 2020 Narok Water and Sewerage Services Co., Ltd.

vt-map's People

Contributors

dependabot[bot] avatar ronoh2019 avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Forkers

wasac

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.