Update build.func

This commit is contained in:
CanbiZ 2025-03-12 08:55:23 +01:00
parent 522fd2b0eb
commit 64a4842e86

View File

@ -330,7 +330,7 @@ base_settings() {
VERBOSE="${1:-no}" VERBOSE="${1:-no}"
PW="" PW=""
CT_ID=$NEXTID CT_ID=$NEXTID
HN="dev_${NSAPP}" HN=$NSAPP
BRG="vmbr0" BRG="vmbr0"
NET="dhcp" NET="dhcp"
IPv6="auto" IPv6="auto"
@ -602,12 +602,11 @@ advanced_settings() {
exit exit
fi fi
if CT_NAME=$(whiptail --backtitle "[dev] Proxmox VE Helper Scripts" --inputbox "Set Hostname" 8 58 "dev_${NSAPP}" --title "HOSTNAME" 3>&1 1>&2 2>&3); then if CT_NAME=$(whiptail --backtitle "[dev] Proxmox VE Helper Scripts" --inputbox "Set Hostname" 8 58 $NSAPP --title "HOSTNAME" 3>&1 1>&2 2>&3); then
if [ -z "$CT_NAME" ]; then if [ -z "$CT_NAME" ]; then
HN="dev_${NSAPP}" HN="$NSAPP"
else else
HN=$(echo ${CT_NAME,,} | tr -d ' ') HN=$(echo ${CT_NAME,,} | tr -d ' ')
[[ $HN != dev_* ]] && HN="dev_${HN}"
fi fi
echo -e "${HOSTNAME}${BOLD}${DGN}Hostname: ${BGN}$HN${CL}" echo -e "${HOSTNAME}${BOLD}${DGN}Hostname: ${BGN}$HN${CL}"
else else