use download plugin to download original data
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
parent
9824082af3
commit
9d5553f1cf
19
.drone.yml
19
.drone.yml
@ -4,17 +4,18 @@ type: docker
|
||||
name: v1
|
||||
|
||||
steps:
|
||||
- name: download-and-unzip
|
||||
image: curlimages/curl:latest
|
||||
commands:
|
||||
- curl --silent --show-error -o ./bestaddresses.zip https://ac.ngi.be/remoteclient-open/GeoBePartners-open/BOSA/ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.zip
|
||||
- unzip bestaddresses.zip
|
||||
- name: download
|
||||
image: plugins/download
|
||||
settings:
|
||||
source: https://ac.ngi.be/remoteclient-open/GeoBePartners-open/BOSA/ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.zip
|
||||
destination: bestaddresses.zip
|
||||
|
||||
- name: convert
|
||||
image: osgeo/gdal:alpine-small-latest
|
||||
commands:
|
||||
- unzip -o bestaddresses.zip
|
||||
- ogr2ogr -sql "SELECT DISTINCT COALESCE(municipality_fr, municipality_nl, municipality_de) AS municipality_name, postal_info_objectid, municipality_objectid FROM addresses_complete" postals.csv ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.gpkg
|
||||
- ogr2ogr -sql "SELECT * FROM addresses_complete" addresses.csv ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.gpkg
|
||||
- ogr2ogr -sql "SELECT * FROM addresses_complete" addresses-full.csv ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.gpkg
|
||||
- ogr2ogr -sql "SELECT * FROM addresses_complete WHERE postal_info_objectid LIKE '1%'" addresses-1xxx.csv ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.gpkg
|
||||
- ogr2ogr -sql "SELECT * FROM addresses_complete WHERE postal_info_objectid LIKE '2%'" addresses-2xxx.csv ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.gpkg
|
||||
- ogr2ogr -sql "SELECT * FROM addresses_complete WHERE postal_info_objectid LIKE '3%'" addresses-3xxx.csv ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.gpkg
|
||||
@ -27,6 +28,9 @@ steps:
|
||||
- ogr2ogr -sql "SELECT * FROM addresses_complete WHERE postal_info_objectid LIKE '1%'" addresses-1xxx.csv ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.gpkg
|
||||
- ogr2ogr -sql "SELECT * FROM addresses_complete WHERE postal_info_objectid LIKE '1%'" addresses-1xxx.csv ca0fd5c0-8146-11e9-9012-482ae30f98d9_geopackage+sqlite3_3812.gpkg
|
||||
- gzip -9 *.csv
|
||||
volumes:
|
||||
- name: mworkdir
|
||||
path: /mworkdir
|
||||
|
||||
- name: gitea_release
|
||||
image: plugins/gitea-release
|
||||
@ -37,4 +41,7 @@ steps:
|
||||
files:
|
||||
- "*.csv.gz"
|
||||
base_url: https://gitea.champs-libres.be
|
||||
volumes:
|
||||
- name: mworkdir
|
||||
path: /mworkdir
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user