From 8a8e0e2e010f2c6ee6341fef5d9f49668851957d Mon Sep 17 00:00:00 2001 From: Friedjoff Trautwein Date: Mon, 27 Apr 2020 15:59:14 +0200 Subject: [PATCH] feat: add tile index file --- lib/.gitignore | 1 + lib/data/spatial/3-tile.sh | 3 ++- lib/data/spatial/tiles/_headers | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/.gitignore b/lib/.gitignore index 81ea8c79..cb1c7dbc 100644 --- a/lib/.gitignore +++ b/lib/.gitignore @@ -5,6 +5,7 @@ node_modules data/spatial/export/*.geojson data/spatial/tiles/fonts data/spatial/tiles/forest-type +data/spatial/tiles/tiles.txt data/spatial/tiles/tree data/spatial/altitudinal_zones_1995 data/spatial/altitudinal_zones_2085_dry diff --git a/lib/data/spatial/3-tile.sh b/lib/data/spatial/3-tile.sh index 25301931..94d7046e 100755 --- a/lib/data/spatial/3-tile.sh +++ b/lib/data/spatial/3-tile.sh @@ -15,4 +15,5 @@ _tile "silver_fir_areas" echo "Joining tiles ..." cd /data/spatial/tiles tile-join --force --maximum-zoom=12 --no-tile-size-limit -e "tree" altitudinal_zones_1995.mbtiles altitudinal_zones_2085_dry.mbtiles altitudinal_zones_2085_less_dry.mbtiles cantonal_boundaries.mbtiles forest_ecoregions.mbtiles forest_types.mbtiles silver_fir_areas.mbtiles -rm altitudinal_zones_1995.mbtiles altitudinal_zones_2085_dry.mbtiles altitudinal_zones_2085_less_dry.mbtiles cantonal_boundaries.mbtiles forest_ecoregions.mbtiles forest_types.mbtiles silver_fir_areas.mbtiles \ No newline at end of file +rm altitudinal_zones_1995.mbtiles altitudinal_zones_2085_dry.mbtiles altitudinal_zones_2085_less_dry.mbtiles cantonal_boundaries.mbtiles forest_ecoregions.mbtiles forest_types.mbtiles silver_fir_areas.mbtiles +find tree -name '*.pbf' > tiles.txt \ No newline at end of file diff --git a/lib/data/spatial/tiles/_headers b/lib/data/spatial/tiles/_headers index 44cf0f70..680ca015 100644 --- a/lib/data/spatial/tiles/_headers +++ b/lib/data/spatial/tiles/_headers @@ -2,5 +2,7 @@ Access-Control-Allow-Origin: * /*.pbf Access-Control-Allow-Origin: * +/*.txt + Access-Control-Allow-Origin: * /tree/*.pbf Content-Encoding: gzip \ No newline at end of file