mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 17:22:49 +01:00
Merge pull request #6953 from Security-Onion-Solutions/issue/6492
https://github.com/Security-Onion-Solutions/securityonion/issues/6492
This commit is contained in:
@@ -92,6 +92,7 @@ add_admin_user() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
add_mngr_ip_to_hosts() {
|
add_mngr_ip_to_hosts() {
|
||||||
|
echo "Adding $MSRV to /etc/hosts with IP: $MSRVIP" >> "$setup_log" 2>&1
|
||||||
echo "$MSRVIP $MSRV" >> /etc/hosts
|
echo "$MSRVIP $MSRV" >> /etc/hosts
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -471,6 +472,13 @@ collect_mngr_hostname() {
|
|||||||
whiptail_management_server "$MSRV"
|
whiptail_management_server "$MSRV"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Remove the manager from /etc/hosts incase a user entered the wrong IP when prompted
|
||||||
|
# and they are going through the installer again
|
||||||
|
if [[ "$HOSTNAME" != "$MSRV" ]]; then
|
||||||
|
echo "Removing $MSRV from /etc/hosts if present." >> "$setup_log" 2>&1
|
||||||
|
sed -i "/$MSRV/d" /etc/hosts
|
||||||
|
fi
|
||||||
|
|
||||||
if ! getent hosts "$MSRV"; then
|
if ! getent hosts "$MSRV"; then
|
||||||
whiptail_manager_ip
|
whiptail_manager_ip
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user