https://github.com/missinglink/wof-spatialite
docker container to load whosonfirst in to spatialite.
https://github.com/missinglink/wof-spatialite
Last synced: about 1 year ago
JSON representation
docker container to load whosonfirst in to spatialite.
- Host: GitHub
- URL: https://github.com/missinglink/wof-spatialite
- Owner: missinglink
- Created: 2017-01-27T00:27:08.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2018-03-11T13:32:09.000Z (over 8 years ago)
- Last Synced: 2025-03-24T10:11:23.692Z (about 1 year ago)
- Language: Shell
- Homepage: https://pip.synergy.io
- Size: 3.74 MB
- Stars: 6
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
docker container to load [whosonfirst](https://github.com/whosonfirst-data/whosonfirst-data) in to spatialite.
#### quick start
```bash
./example.sh
```
#### how can run this container?
first you need to fetch the whosonfirst data and put it in a directory on disk, the directory should have one or more subdirectories containing the .geojson files you wish to import:
```bash
$ ls /tmp/inputdir
data meta
```
create another directory where you would like to store the output sqlite database:
```bash
$ mkdir -p /tmp/outputdir
```
initialize the database:
```bash
$ docker run -e 'DB=/out/wof.sqlite' -v '/tmp/outputdir:/out' 'missinglink/wof-spatialite' init
```
make sure that worked:
```bash
$ ls /tmp/outputdir
wof.sqlite
```
import all the things:
```bash
$ docker run -e 'DB=/out/wof.sqlite' -v '/tmp/inputdir:/in' -v '/tmp/outputdir:/out' 'missinglink/wof-spatialite' index_all '/in'
```
see ./spatialite.sh in this repo for a full list of supported commands
#### how can I rebuild the image?
clone this repository, cd in the directory and run:
```bash
docker build -t 'missinglink/wof-spatialite' .
```