Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/2.4/dev' into issue/11229
Browse files Browse the repository at this point in the history
  • Loading branch information
m0duspwnens committed Sep 8, 2023
2 parents e814a34 + 55847c7 commit 02c54a2
Showing 1 changed file with 14 additions and 12 deletions.
26 changes: 14 additions & 12 deletions setup/so-functions
Original file line number Diff line number Diff line change
Expand Up @@ -398,20 +398,22 @@ collect_mngr_hostname() {
sed -i "/$MSRV/d" /etc/hosts
fi

if ! getent hosts "$MSRV"; then
whiptail_manager_ip
if [[ -z "$MSRVIP" ]]; then
if ! getent hosts "$MSRV"; then
whiptail_manager_ip

while ! valid_ip4 "$MSRVIP" || [[ $MSRVIP == "$MAINIP" || $MSRVIP == "127.0.0.1" ]]; do
whiptail_invalid_input
whiptail_manager_ip "$MSRVIP"
done
else
MSRVIP=$(getent hosts "$MSRV" | awk 'NR==1{print $1}')
whiptail_manager_ip "$MSRVIP"
while ! valid_ip4 "$MSRVIP" || [[ $MSRVIP == "$MAINIP" || $MSRVIP == "127.0.0.1" ]]; do
whiptail_invalid_input
while ! valid_ip4 "$MSRVIP" || [[ $MSRVIP == "$MAINIP" || $MSRVIP == "127.0.0.1" ]]; do
whiptail_invalid_input
whiptail_manager_ip "$MSRVIP"
done
else
MSRVIP=$(getent hosts "$MSRV" | awk 'NR==1{print $1}')
whiptail_manager_ip "$MSRVIP"
done
while ! valid_ip4 "$MSRVIP" || [[ $MSRVIP == "$MAINIP" || $MSRVIP == "127.0.0.1" ]]; do
whiptail_invalid_input
whiptail_manager_ip "$MSRVIP"
done
fi
fi
}

Expand Down

0 comments on commit 02c54a2

Please sign in to comment.