Skip to content

Commit

Permalink
Fix not to check FQDN when setting up repos
Browse files Browse the repository at this point in the history
  • Loading branch information
iliajie committed Jul 6, 2023
1 parent f524373 commit a0bfa73
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions virtualmin-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -814,16 +814,18 @@ log_debug "Product: Virtualmin $PRODUCT"
log_debug "virtualmin-install.sh version: $VER"

# Check for a fully qualified hostname
log_debug "Checking for fully qualified hostname .."
name="$(hostname -f)"
if [ -n "$forcehostname" ]; then
set_hostname "$forcehostname"
elif ! is_fully_qualified "$name"; then
set_hostname
else
# Hostname is already FQDN, yet still set it
# again to make sure to have it updated everywhere
set_hostname "$name"
if [ -z "$setup_only" ]; then
log_debug "Checking for fully qualified hostname .."
name="$(hostname -f)"
if [ -n "$forcehostname" ]; then
set_hostname "$forcehostname"
elif ! is_fully_qualified "$name"; then
set_hostname
else
# Hostname is already FQDN, yet still set it
# again to make sure to have it updated everywhere
set_hostname "$name"
fi
fi

# Insert the serial number and password into /etc/virtualmin-license
Expand Down

0 comments on commit a0bfa73

Please sign in to comment.