Skip to content
This repository has been archived by the owner on May 19, 2020. It is now read-only.

Commit

Permalink
Make more configurable via environment variables
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasmartinelli committed Nov 1, 2016
1 parent ef48213 commit 7ef1434
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions export-local.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,19 @@ readonly RENDER_SCHEME=${RENDER_SCHEME:-pyramid}
readonly MIN_ZOOM=${MIN_ZOOM:-0}
readonly MAX_ZOOM=${MAX_ZOOM:-14}
readonly BBOX=${BBOX:-"-180,-85.0511,180,85.0511"}
readonly COPY_CONCURRENCY=${COPY_CONCURRENCY:-10}
readonly TILE_TIMEOUT=${TILE_TIMEOUT:-1800000}
readonly MBTILES_NAME=${MBTILES_NAME:-tiles.mbtiles}

function export_local_mbtiles() {
local mbtiles_name="tiles.mbtiles"
exec tilelive-copy \
--scheme=pyramid \
--bounds="$BBOX" \
--timeout=1800000 \
--timeout="$TILE_TIMEOUT" \
--concurrency="$COPY_CONCURRENCY" \
--minzoom="$MIN_ZOOM" \
--maxzoom="$MAX_ZOOM" \
"tmsource://$DEST_PROJECT_DIR" "mbtiles://$EXPORT_DIR/$mbtiles_name"
"tmsource://$DEST_PROJECT_DIR" "mbtiles://$EXPORT_DIR/$MBTILES_NAME"
}

function main() {
Expand Down

0 comments on commit 7ef1434

Please sign in to comment.