mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 17:22:49 +01:00
[fix] Add missing append flags to tee
This commit is contained in:
@@ -522,7 +522,7 @@ compare_versions() {
|
|||||||
manager_ver=$(ssh -i /root/.ssh/so.key soremote@"$MSRV" cat /etc/soversion)
|
manager_ver=$(ssh -i /root/.ssh/so.key soremote@"$MSRV" cat /etc/soversion)
|
||||||
|
|
||||||
if [[ $manager_ver == "" ]]; then
|
if [[ $manager_ver == "" ]]; then
|
||||||
echo "Could not determine version of Security Onion running on manager $MSRV. Please check your network settings and run setup again." | tee "$setup_log"
|
echo "Could not determine version of Security Onion running on manager $MSRV. Please check your network settings and run setup again." | tee -a "$setup_log"
|
||||||
kill -SIGUSR1 "$(ps --pid $$ -oppid=)"; exit 1
|
kill -SIGUSR1 "$(ps --pid $$ -oppid=)"; exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -936,7 +936,7 @@ download_repo_tarball() {
|
|||||||
# Fail if the file doesn't download
|
# Fail if the file doesn't download
|
||||||
if ! [ -f /root/manager_setup/"$manager_ver".tar.gz ]; then
|
if ! [ -f /root/manager_setup/"$manager_ver".tar.gz ]; then
|
||||||
local message="Could not download $manager_ver.tar.gz from manager, please check your network settings and verify the file /opt/so/repo/$manager_ver.tar.gz exists on the manager."
|
local message="Could not download $manager_ver.tar.gz from manager, please check your network settings and verify the file /opt/so/repo/$manager_ver.tar.gz exists on the manager."
|
||||||
echo "$message" | tee "$setup_log"
|
echo "$message" | tee -a "$setup_log"
|
||||||
kill -SIGUSR1 "$(ps --pid $$ -oppid=)"; exit 1
|
kill -SIGUSR1 "$(ps --pid $$ -oppid=)"; exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -1655,7 +1655,7 @@ saltify() {
|
|||||||
apt-key add "$temp_install_dir"/gpg/GPG-KEY-WAZUH >> "$setup_log" 2>&1
|
apt-key add "$temp_install_dir"/gpg/GPG-KEY-WAZUH >> "$setup_log" 2>&1
|
||||||
echo "deb http://repo.saltstack.com$py_ver_url_path/ubuntu/$ubuntu_version/amd64/archive/3002.2/ $OSVER main" > /etc/apt/sources.list.d/saltstack.list 2>> "$setup_log"
|
echo "deb http://repo.saltstack.com$py_ver_url_path/ubuntu/$ubuntu_version/amd64/archive/3002.2/ $OSVER main" > /etc/apt/sources.list.d/saltstack.list 2>> "$setup_log"
|
||||||
echo "deb https://packages.wazuh.com/3.x/apt/ stable main" > /etc/apt/sources.list.d/wazuh.list 2>> "$setup_log"
|
echo "deb https://packages.wazuh.com/3.x/apt/ stable main" > /etc/apt/sources.list.d/wazuh.list 2>> "$setup_log"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
apt-get update >> "$setup_log" 2>&1
|
apt-get update >> "$setup_log" 2>&1
|
||||||
set_progress_str 8 'Installing salt-minion & python modules'
|
set_progress_str 8 'Installing salt-minion & python modules'
|
||||||
|
|||||||
@@ -115,7 +115,7 @@ case "$setup_type" in
|
|||||||
echo "Beginning Security Onion $setup_type install" >> $setup_log 2>&1
|
echo "Beginning Security Onion $setup_type install" >> $setup_log 2>&1
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
echo "Invalid install type, must be 'iso' or 'network'" | tee $setup_log
|
echo "Invalid install type, must be 'iso' or 'network'" | tee -a $setup_log
|
||||||
exit 1
|
exit 1
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
@@ -156,7 +156,7 @@ if ! [ -f /root/install_opt ]; then
|
|||||||
if (whiptail_you_sure); then
|
if (whiptail_you_sure); then
|
||||||
true
|
true
|
||||||
else
|
else
|
||||||
echo "User cancelled setup." | tee "$setup_log"
|
echo "User cancelled setup." | tee -a "$setup_log"
|
||||||
whiptail_cancel
|
whiptail_cancel
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user