mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-07 17:52:46 +01:00
Fix reinstall logic
This commit is contained in:
@@ -137,7 +137,7 @@ fi
|
||||
title "Checking to see if install has run before"
|
||||
if [[ -f /root/accept_changes ]]; then
|
||||
is_reinstall=true
|
||||
|
||||
whiptail_reinstall
|
||||
info "Old setup detected. Moving the last setup.log to setup.log.bak"
|
||||
mv "$setup_log" "$setup_log.bak"
|
||||
[ -f "$error_log" ] && mv "$error_log" "$error_log.bak"
|
||||
@@ -485,11 +485,6 @@ if ! [[ -f $install_opt_file ]]; then
|
||||
info "Setting Paths"
|
||||
# Set the paths
|
||||
set_path
|
||||
info "Checking if this is a re-install"
|
||||
# Check to see if its a reinstall. THIS NEEDS REVIEW
|
||||
if [[ $is_reinstall ]]; then
|
||||
reinstall_init
|
||||
fi
|
||||
echo "Disable auto start of setup"
|
||||
# Disable the setup from prompting at login
|
||||
disable_auto_start
|
||||
|
||||
@@ -1104,6 +1104,15 @@ whiptail_proxy_auth_pass() {
|
||||
whiptail_check_exitstatus $exitstatus
|
||||
}
|
||||
|
||||
whiptail_reinstall() {
|
||||
[ -n "$TESTING" ] && return
|
||||
|
||||
whiptail --title "$whiptail_title" --yesno "Setup has detected a previous install. Do you want to continue? Continuing will overwrite the previos install. " 7 44
|
||||
|
||||
local exitstatus=$?
|
||||
whiptail_check_exitstatus $exitstatus
|
||||
}
|
||||
|
||||
whiptail_requirements_error() {
|
||||
|
||||
local requirement_needed=$1
|
||||
|
||||
Reference in New Issue
Block a user