Skip to content

Commit 164589b

Browse files
committed
Bump version to 0.5.9 and update logging for planet file download and conversion process
1 parent cf99b9c commit 164589b

File tree

2 files changed

+4
-24
lines changed

2 files changed

+4
-24
lines changed

charts/overpass-api-chart/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@ keywords:
1414
- api
1515

1616
type: application
17-
version: 0.5.8
17+
version: 0.5.9
1818
appVersion: "0.7.62.6" # The last number is the Dockerfile version for that overpass-api version

charts/overpass-api-chart/templates/configmap.yaml

Lines changed: 3 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ data:
4545
4646
log "INFO" "Downloading planet file: ${file_name}"
4747
48-
wget --progress=dot -e dotbytes=30M -O "${planet_file}" "$OVERPASS_PLANET_URL"
48+
wget -nv --show-progress --progress=dot -e dotbytes=30M -O "${planet_file}" "$OVERPASS_PLANET_URL"
4949
5050
if [ ! -f "${planet_file}" ]; then
5151
log "ERROR" "Failed to download ${file_name}"
@@ -65,7 +65,7 @@ data:
6565
fi
6666
6767
if [[ "$planet_file" == *.osm.pbf ]]; then
68-
log "INFO" "Converting PBF to OSM format using osmium with progress..."
68+
log "INFO" "Converting PBF to BZ2 format using osmium with progress..."
6969
local osm_file="${WORK_DIR}/planet.osm.bz2"
7070
7171
# Check if osmium is available
@@ -74,27 +74,7 @@ data:
7474
exit 1
7575
fi
7676
77-
# Use pv to show progress
78-
# Run osmium and capture its stderr
79-
set +e
80-
81-
stdbuf -oL osmium cat "${planet_file}" -o "${osm_file}" --verbose \
82-
2> "${WORK_DIR}/osmium_error.log" | \
83-
pv -i 60 --format "%t %p%%\n" > /dev/null
84-
85-
# Capture the exit status of osmium using PIPESTATUS
86-
exit_status=${PIPESTATUS[0]}
87-
88-
set -e
89-
90-
# If osmium failed, display the error log
91-
if [ $exit_status -ne 0 ]; then
92-
log "ERROR" "osmium failed with exit status $exit_status"
93-
log "ERROR" "Error output from osmium:"
94-
cat "${WORK_DIR}/osmium_error.log" >&2
95-
sleep 5
96-
exit $exit_status
97-
fi
77+
osmium cat "${planet_file}" -o "${osm_file}" --verbose
9878
9979
if [ ! -f "${osm_file}" ]; then
10080
log "ERROR" "OSM file not created: ${osm_file}"

0 commit comments

Comments
 (0)