From 25a661e3da27c1fc91d5b586eed09cb088f49ab9 Mon Sep 17 00:00:00 2001 From: galewis2 <62433564+galewis2@users.noreply.github.com> Date: Fri, 22 Jul 2022 09:18:24 -0400 Subject: [PATCH] Actually allow modifying the replication URL (#297) --- Dockerfile | 3 +++ openstreetmap-tiles-update-expire.sh | 4 ---- run.sh | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index f249f0a..d016d1b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -34,6 +34,9 @@ FROM ubuntu:22.04 AS final ENV DEBIAN_FRONTEND=noninteractive ENV AUTOVACUUM=on ENV UPDATES=disabled +ENV REPLICATION_URL=https://planet.openstreetmap.org/replication/hour/ +ENV MAX_INTERVAL_SECONDS=3600 + RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone # Get packages diff --git a/openstreetmap-tiles-update-expire.sh b/openstreetmap-tiles-update-expire.sh index e64c150..2d2a9f2 100755 --- a/openstreetmap-tiles-update-expire.sh +++ b/openstreetmap-tiles-update-expire.sh @@ -61,10 +61,6 @@ EXPIRY_TOUCHFROM=${EXPIRY_TOUCHFROM:="13"} EXPIRY_DELETEFROM=${EXPIRY_DELETEFROM:="19"} EXPIRY_MAXZOOM=${EXPIRY_MAXZOOM:="20"} - -REPLICATION_URL=${REPLICATION_URL:="https://planet.openstreetmap.org/replication/hour/"} -MAX_INTERVAL_SECONDS=${MAX_INTERVAL_SECONDS:="3600"} - #************************************************************************* #************************************************************************* diff --git a/run.sh b/run.sh index 25ad24a..69d54a1 100755 --- a/run.sh +++ b/run.sh @@ -81,7 +81,7 @@ if [ "$1" == "import" ]; then REPLICATION_TIMESTAMP=`osmium fileinfo -g header.option.osmosis_replication_timestamp /data/region.osm.pbf` # initial setup of osmosis workspace (for consecutive updates) - sudo -u renderer openstreetmap-tiles-update-expire.sh $REPLICATION_TIMESTAMP + sudo -E -u renderer openstreetmap-tiles-update-expire.sh $REPLICATION_TIMESTAMP fi # copy polygon file if available