Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Offer suggestions when entring cities #3

Closed
finxol opened this issue Jun 6, 2022 · 6 comments
Closed

Offer suggestions when entring cities #3

finxol opened this issue Jun 6, 2022 · 6 comments
Assignees
Labels
enhancement New feature that will be implemented
Milestone

Comments

@finxol
Copy link
Member

finxol commented Jun 6, 2022

https://github.com/addok/addok

@finxol
Copy link
Member Author

finxol commented Jun 6, 2022

Deployed Addok instance using the French government's BAN and BNLC (same but for carpool points), and OpenStreetMap's BANO.

Available on addok.unicovoit.fr

@finxol finxol added the enhancement New feature that will be implemented label Jun 6, 2022
@finxol finxol self-assigned this Jun 6, 2022
@finxol finxol added this to the v1.0.0 milestone Jun 6, 2022
@finxol
Copy link
Member Author

finxol commented Jun 6, 2022

Setup instructions on github.com/etalab/addok-docker

Download the full.sjson.gz archive

Download and extract the archive at bano.openstreetmap.fr;
Then import with addok batch full.sjson

If this doesn't work, try using the following script to down all the chunks and import then to addok.

Massive bodge, auto add OpenStreetMap's BANO data with sort of dodgy script.

Download the data;

#! /bin/bash

page=$(curl -s https://bano.openstreetmap.fr/data/)
for f in  $(echo "$data" | grep -Eo "bano-[[:digit:]][[:digit:]]\.json\.gz")
do
	echo "$f"
	wget -q "https://bano.openstreetmap.fr/data/$f"
done
for f in  $(echo "$data" | grep -Eo "bano-[[:digit:]][[:digit:]][[:digit:]]\.json\.gz")
do
	echo "$f"
	wget -q "https://bano.openstreetmap.fr/data/$f"
done

Import it to addok:

for i in {1..9}
do
    addok batch "bano-0$i.json"
done

for i in {10..95}
do
    addok batch "bano-$i.json"
done

for i in {971..974}
do
    addok batch "bano-$i.json"
done

addok batch "bano-976.json"
addok batch "bano-2A.json"
addok batch "bano-2B.json"

@finxol
Copy link
Member Author

finxol commented Jun 6, 2022

Import data from BNLC

Download dataset from data.gouv.fr or github, then convert to json with custom convertion script
Then import data to addok with addok batch bnlc.json

@finxol
Copy link
Member Author

finxol commented Jun 27, 2022

Setup addok instance

Startup with the BAN dataset for addok from data.gouv.fr

Download the data from gouv.fr:

wget https://adresse.data.gouv.fr/data/ban/adresses/latest/addok/addok-france-bundle.zip

Unzip to addok-data directory:

unzip -d addok-data addok-france-bundle.zip

Get the docker-compose file from github

wget https://github.com/unicovoit/addok-data/blob/main/docker-compose.yml

Run the container

podman-compose up -d

Add other data sets

BNLC

Download the dataset in sjson from github:
https://github.com/unicovoit/addok-data/blob/main/dataparse/bnlc.sjson

(8636 entries)

BANO

Download the dataset in sjson from github:
https://bano.openstreetmap.fr/data/full.sjson.gz

(>4000000 entries)

Import the complementary data

Inside the Addok container, run addok batch bano.sjson and addok batch bnlc.sjson

@finxol
Copy link
Member Author

finxol commented Jun 28, 2022

Possible improvements:

@finxol finxol closed this as completed Jun 28, 2022
@finxol
Copy link
Member Author

finxol commented Nov 6, 2022

Move all files to separate repo (https://github.com/unicovoit/addok-data)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature that will be implemented
Projects
Status: Done
Development

No branches or pull requests

1 participant