revert changes that shouldnt be in this pr

This commit is contained in:
Greg 2022-02-18 02:00:55 +00:00
parent 99dc08768e
commit 69dac2c4bf
3 changed files with 4 additions and 13 deletions

View File

@ -153,8 +153,6 @@ RUN chmod +x /usr/bin/openstreetmap-tiles-update-expire \
&& mkdir /var/log/tiles \
&& chmod a+rw /var/log/tiles \
&& ln -s /home/renderer/src/mod_tile/osmosis-db_replag /usr/bin/osmosis-db_replag \
&& echo "SHELL=/bin/bash" > /etc/crontab \
&& echo "BASH_ENV=/container.env" >> /etc/crontab \
&& echo "* * * * * renderer openstreetmap-tiles-update-expire\n" >> /etc/crontab
RUN mkdir /nodes \

View File

@ -59,10 +59,6 @@ EXPIRY_TOUCHFROM=13
EXPIRY_DELETEFROM=19
EXPIRY_MAXZOOM=20
REPLICATION_URL=${REPLICATION_URL:="https://planet.openstreetmap.org/replication/hour/"}
MAX_INTERVAL_SECONDS=${MAX_INTERVAL_SECONDS:="3600"}
#*************************************************************************
#*************************************************************************
@ -111,11 +107,10 @@ freelock()
if [ $# -eq 1 ] ; then
m_info "Initialising Osmosis replication system to $1"
mkdir -p $WORKOSM_DIR
$OSMOSIS_BIN -v 5 --read-replication-interval-init workingDirectory=$WORKOSM_DIR 1>&2 2> "$OSMOSISLOG"
init_seq=$(pyosmium-get-changes --server https://planet.openstreetmap.org/replication/minute/ -D $1)
url_dynamicPart=$(printf %09d $init_seq | sed 's_\([0-9][0-9][0-9]\)\([0-9][0-9][0-9]\)\([0-9][0-9][0-9]\)_\1/\2/\3_')
wget https://planet.openstreetmap.org/replication/minute/$url_dynamicPart.state.txt -O $WORKOSM_DIR/state.txt
$OSMOSIS_BIN --read-replication-interval-init workingDirectory=$WORKOSM_DIR 1>&2 2> "$OSMOSISLOG"
wget "https://replicate-sequences.osm.mazdermind.de/?"$1"T00:00:00Z" -O $WORKOSM_DIR/state.txt
mv $WORKOSM_DIR/configuration.txt $WORKOSM_DIR/configuration_orig.txt
sed "s!baseUrl=http://planet.openstreetmap.org/replication/minute!baseUrl=https://planet.openstreetmap.org/replication/minute!" $WORKOSM_DIR/configuration_orig.txt > $WORKOSM_DIR/configuration.txt
@ -149,7 +144,7 @@ fi
/bin/cp $WORKOSM_DIR/state.txt $WORKOSM_DIR/last.state.txt
m_ok "downloading diff"
if ! $OSMOSIS_BIN -v 5 --read-replication-interval workingDirectory=$WORKOSM_DIR --simplify-change --write-xml-change $CHANGE_FILE 1>&2 2> "$OSMOSISLOG"; then
if ! $OSMOSIS_BIN --read-replication-interval workingDirectory=$WORKOSM_DIR --simplify-change --write-xml-change $CHANGE_FILE 1>&2 2> "$OSMOSISLOG"; then
m_error "Osmosis error"
fi

2
run.sh
View File

@ -2,8 +2,6 @@
set -euo pipefail
declare -p | grep -Ev 'BASHOPTS|BASH_VERSINFO|EUID|PPID|SHELLOPTS|UID' > /container.env
function createPostgresConfig() {
cp /etc/postgresql/12/main/postgresql.custom.conf.tmpl /etc/postgresql/12/main/conf.d/postgresql.custom.conf
sudo -u postgres echo "autovacuum = $AUTOVACUUM" >> /etc/postgresql/12/main/conf.d/postgresql.custom.conf