mirror of
https://github.com/tteck/Proxmox.git
synced 2024-12-27 07:21:59 +00:00
Update turnkey.sh
change whiptail variables
This commit is contained in:
parent
7b7619aaa7
commit
5d40a203e6
@ -57,12 +57,12 @@ if systemctl is-active -q ping-instances.service; then
|
|||||||
fi
|
fi
|
||||||
header_info
|
header_info
|
||||||
whiptail --backtitle "Proxmox VE Helper Scripts" --title "TurnKey LXCs" --yesno "This will allow for the creation of one of the many TurnKey LXC Containers. Proceed?" 10 68 || exit
|
whiptail --backtitle "Proxmox VE Helper Scripts" --title "TurnKey LXCs" --yesno "This will allow for the creation of one of the many TurnKey LXC Containers. Proceed?" 10 68 || exit
|
||||||
CTID_MENU=()
|
TURNKEY_MENU=()
|
||||||
MSG_MAX_LENGTH=0
|
MSG_MAX_LENGTH=0
|
||||||
while read -r TAG ITEM; do
|
while read -r TAG ITEM; do
|
||||||
OFFSET=2
|
OFFSET=2
|
||||||
((${#ITEM} + OFFSET > MSG_MAX_LENGTH)) && MSG_MAX_LENGTH=${#ITEM}+OFFSET
|
((${#ITEM} + OFFSET > MSG_MAX_LENGTH)) && MSG_MAX_LENGTH=${#ITEM}+OFFSET
|
||||||
CTID_MENU+=("$TAG" "$ITEM " "OFF")
|
TURNKEY_MENU+=("$TAG" "$ITEM " "OFF")
|
||||||
done < <(
|
done < <(
|
||||||
cat <<EOF
|
cat <<EOF
|
||||||
ansible Ansible
|
ansible Ansible
|
||||||
@ -87,7 +87,7 @@ wordpress Wordpress
|
|||||||
zoneminder ZoneMinder
|
zoneminder ZoneMinder
|
||||||
EOF
|
EOF
|
||||||
)
|
)
|
||||||
turnkey=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "TurnKey LXCs" --radiolist "\nSelect a TurnKey LXC to create:\n" 16 $((MSG_MAX_LENGTH + 58)) 6 "${CTID_MENU[@]}" 3>&1 1>&2 2>&3 | tr -d '"') || exit
|
turnkey=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "TurnKey LXCs" --radiolist "\nSelect a TurnKey LXC to create:\n" 16 $((MSG_MAX_LENGTH + 58)) 6 "${TURNKEY_MENU[@]}" 3>&1 1>&2 2>&3 | tr -d '"') || exit
|
||||||
[ -z "$turnkey" ] && {
|
[ -z "$turnkey" ] && {
|
||||||
whiptail --backtitle "Proxmox VE Helper Scripts" --title "No TurnKey LXC Selected" --msgbox "It appears that no TurnKey LXC container was selected" 10 68
|
whiptail --backtitle "Proxmox VE Helper Scripts" --title "No TurnKey LXC Selected" --msgbox "It appears that no TurnKey LXC container was selected" 10 68
|
||||||
msg "Done"
|
msg "Done"
|
||||||
|
Loading…
Reference in New Issue
Block a user