mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-04-28 03:20:11 +00:00
Refresh container sensor proxy installer
This commit is contained in:
parent
3fe6b4fe9b
commit
fb1e44300b
1 changed files with 18 additions and 0 deletions
18
install.sh
18
install.sh
|
|
@ -1709,6 +1709,8 @@ fi'; then
|
|||
fi
|
||||
fi
|
||||
|
||||
refresh_container_proxy_installer "$CTID"
|
||||
|
||||
write_install_summary
|
||||
|
||||
# Clean final output
|
||||
|
|
@ -1733,6 +1735,22 @@ fi'; then
|
|||
exit 0
|
||||
}
|
||||
|
||||
refresh_container_proxy_installer() {
|
||||
local target_ctid="$1"
|
||||
if [[ "$IN_CONTAINER" == true ]]; then
|
||||
return
|
||||
fi
|
||||
if [[ -z "$target_ctid" ]]; then
|
||||
return
|
||||
fi
|
||||
|
||||
local installer_url="https://raw.githubusercontent.com/${GITHUB_REPO}/${SOURCE_BRANCH:-main}/scripts/install-sensor-proxy.sh"
|
||||
print_info "Refreshing sensor proxy installer inside container ${target_ctid}..."
|
||||
if ! pct exec "$target_ctid" -- bash -c "set -euo pipefail; mkdir -p /usr/local/share/pulse; tmp=\$(mktemp); curl -fsSL --connect-timeout 10 --max-time 45 '${installer_url}' -o \$tmp && install -m 0755 \$tmp /usr/local/share/pulse/install-sensor-proxy.sh && rm -f \$tmp"; then
|
||||
print_warn "Unable to refresh container installer; continuing with bundled version"
|
||||
fi
|
||||
}
|
||||
|
||||
# Compare two version strings
|
||||
# Returns: 0 if equal, 1 if first > second, 2 if first < second
|
||||
compare_versions() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue