fix: skip auto-update prompt for source builds
Source builds use commit hashes (0.0.0-main-44ef8b6) not semantic versions (v4.23.0), so auto-updates don't make sense. The auto-updater would download release binaries, replacing the user's source build. Changes: - Skip auto-update question when BUILD_FROM_SOURCE=true - Show informational message instead - Applies to both Quick and Advanced modes This prevents confusion when users explicitly choose --source to get the latest main branch code instead of stable releases.
This commit is contained in:
parent
4c1ac06cdb
commit
0e0661eb68
1 changed files with 26 additions and 16 deletions
42
install.sh
42
install.sh
|
|
@ -424,15 +424,20 @@ create_lxc_container() {
|
||||||
frontend_port=7655
|
frontend_port=7655
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo
|
|
||||||
# Ask about auto-updates
|
|
||||||
echo "Enable automatic updates?"
|
|
||||||
echo "Pulse can automatically install stable updates daily (between 2-6 AM)"
|
|
||||||
safe_read_with_default "Enable auto-updates? [y/N]: " enable_updates "n"
|
|
||||||
auto_updates_flag=""
|
auto_updates_flag=""
|
||||||
if [[ "$enable_updates" =~ ^[Yy]$ ]]; then
|
if [[ "$BUILD_FROM_SOURCE" == "true" ]]; then
|
||||||
auto_updates_flag="--enable-auto-updates"
|
echo
|
||||||
ENABLE_AUTO_UPDATES=true # Set the global variable for host installations
|
print_info "Skipping auto-update configuration: source builds don't support automatic release updates."
|
||||||
|
else
|
||||||
|
echo
|
||||||
|
# Ask about auto-updates
|
||||||
|
echo "Enable automatic updates?"
|
||||||
|
echo "Pulse can automatically install stable updates daily (between 2-6 AM)"
|
||||||
|
safe_read_with_default "Enable auto-updates? [y/N]: " enable_updates "n"
|
||||||
|
if [[ "$enable_updates" =~ ^[Yy]$ ]]; then
|
||||||
|
auto_updates_flag="--enable-auto-updates"
|
||||||
|
ENABLE_AUTO_UPDATES=true # Set the global variable for host installations
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -z "$PROXY_MODE" ]]; then
|
if [[ -z "$PROXY_MODE" ]]; then
|
||||||
|
|
@ -551,15 +556,20 @@ create_lxc_container() {
|
||||||
print_info "Using default: 7655"
|
print_info "Using default: 7655"
|
||||||
frontend_port=7655
|
frontend_port=7655
|
||||||
fi
|
fi
|
||||||
# Quick mode should ask about auto-updates too
|
|
||||||
echo
|
|
||||||
echo "Enable automatic updates?"
|
|
||||||
echo "Pulse can automatically install stable updates daily (between 2-6 AM)"
|
|
||||||
safe_read_with_default "Enable auto-updates? [y/N]: " enable_updates "n"
|
|
||||||
auto_updates_flag=""
|
auto_updates_flag=""
|
||||||
if [[ "$enable_updates" =~ ^[Yy]$ ]]; then
|
if [[ "$BUILD_FROM_SOURCE" == "true" ]]; then
|
||||||
auto_updates_flag="--enable-auto-updates"
|
echo
|
||||||
ENABLE_AUTO_UPDATES=true # Set the global variable for host installations
|
print_info "Skipping auto-update configuration: source builds don't support automatic release updates."
|
||||||
|
else
|
||||||
|
# Quick mode should ask about auto-updates too
|
||||||
|
echo
|
||||||
|
echo "Enable automatic updates?"
|
||||||
|
echo "Pulse can automatically install stable updates daily (between 2-6 AM)"
|
||||||
|
safe_read_with_default "Enable auto-updates? [y/N]: " enable_updates "n"
|
||||||
|
if [[ "$enable_updates" =~ ^[Yy]$ ]]; then
|
||||||
|
auto_updates_flag="--enable-auto-updates"
|
||||||
|
ENABLE_AUTO_UPDATES=true # Set the global variable for host installations
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -z "$PROXY_MODE" ]]; then
|
if [[ -z "$PROXY_MODE" ]]; then
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue