From 2754592d1ceea1fb3148037b70b075ab1f7758db Mon Sep 17 00:00:00 2001 From: Alexander Overvoorde Date: Sun, 26 Apr 2020 19:00:59 +0200 Subject: [PATCH] Rearrange OSM2PGSQL_EXTRA_ARGS to allow overriding of existing parameters (fixes #112) --- openstreetmap-tiles-update-expire | 2 +- run.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/openstreetmap-tiles-update-expire b/openstreetmap-tiles-update-expire index 4650b4a..6ccce9f 100644 --- a/openstreetmap-tiles-update-expire +++ b/openstreetmap-tiles-update-expire @@ -22,7 +22,7 @@ OSM2PGSQL_BIN=osm2pgsql TRIM_BIN=/home/$ACCOUNT/src/regional/trim_osc.py DBNAME=gis -OSM2PGSQL_OPTIONS="-d $DBNAME -G --hstore ${OSM2PGSQL_EXTRA_ARGS} --tag-transform-script /home/renderer/src/openstreetmap-carto/openstreetmap-carto.lua --number-processes ${THREADS:-4} -S /home/renderer/src/openstreetmap-carto/openstreetmap-carto.style" +OSM2PGSQL_OPTIONS="-d $DBNAME -G --hstore --tag-transform-script /home/renderer/src/openstreetmap-carto/openstreetmap-carto.lua --number-processes ${THREADS:-4} -S /home/renderer/src/openstreetmap-carto/openstreetmap-carto.style" ${OSM2PGSQL_EXTRA_ARGS} #------------------------------------------------------------------------------ # When using trim_osc.py we can define either a bounding box (such as this diff --git a/run.sh b/run.sh index 97663eb..9e5ee36 100755 --- a/run.sh +++ b/run.sh @@ -73,7 +73,7 @@ if [ "$1" = "import" ]; then fi # Import data - sudo -u renderer osm2pgsql -d gis --create --slim -G --hstore --tag-transform-script /home/renderer/src/openstreetmap-carto/openstreetmap-carto.lua --number-processes ${THREADS:-4} ${OSM2PGSQL_EXTRA_ARGS} -S /home/renderer/src/openstreetmap-carto/openstreetmap-carto.style /data.osm.pbf + sudo -u renderer osm2pgsql -d gis --create --slim -G --hstore --tag-transform-script /home/renderer/src/openstreetmap-carto/openstreetmap-carto.lua --number-processes ${THREADS:-4} -S /home/renderer/src/openstreetmap-carto/openstreetmap-carto.style /data.osm.pbf ${OSM2PGSQL_EXTRA_ARGS} # Create indexes sudo -u postgres psql -d gis -f indexes.sql