mirror of
https://github.com/community-scripts/ProxmoxVE
synced 2025-01-11 11:25:08 +00:00
Update build.func
This commit is contained in:
parent
02ded1ee47
commit
63be70cc25
@ -575,25 +575,39 @@ advanced_settings() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
install_script() {
|
install_script() {
|
||||||
|
# Vorbereitende Checks
|
||||||
pve_check
|
pve_check
|
||||||
shell_check
|
shell_check
|
||||||
root_check
|
root_check
|
||||||
arch_check
|
arch_check
|
||||||
ssh_check
|
ssh_check
|
||||||
|
|
||||||
|
# Stoppen des ping-instances Dienstes, falls aktiv
|
||||||
if systemctl is-active -q ping-instances.service; then
|
if systemctl is-active -q ping-instances.service; then
|
||||||
systemctl -q stop ping-instances.service
|
systemctl -q stop ping-instances.service
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Initiale Variablen
|
||||||
NEXTID=$(pvesh get /cluster/nextid)
|
NEXTID=$(pvesh get /cluster/nextid)
|
||||||
timezone=$(cat /etc/timezone)
|
timezone=$(cat /etc/timezone)
|
||||||
header_info
|
|
||||||
|
# Optionen für das Menü
|
||||||
|
MENU_OPTIONS=(
|
||||||
|
"1" "Default Settings"
|
||||||
|
"2" "Default Settings (Verbose)"
|
||||||
|
"3" "Advanced Settings"
|
||||||
|
"4" "Exit"
|
||||||
|
)
|
||||||
|
MENU_HEIGHT=$(( ${#MENU_OPTIONS[@]} / 2 + 7 )) # Höhe basierend auf Anzahl Optionen
|
||||||
|
MENU_WIDTH=50 # Feste Breite
|
||||||
|
CHOICE_WIDTH=25 # Breite der Auswahlliste
|
||||||
|
|
||||||
while true; do
|
while true; do
|
||||||
CHOICE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SETTINGS" --menu "Choose an option:" \
|
CHOICE=$(whiptail --backtitle "Proxmox VE Helper Scripts" \
|
||||||
15 60 4 \
|
--title "SETTINGS" \
|
||||||
"1" "Default Settings" \
|
--menu "Choose an option:" \
|
||||||
"2" "Default Settings (with verbose)" \
|
"$MENU_HEIGHT" "$MENU_WIDTH" "$CHOICE_WIDTH" \
|
||||||
"3" "Advanced Settings" \
|
"${MENU_OPTIONS[@]}" 3>&1 1>&2 2>&3)
|
||||||
"4" "Exit" 3>&1 1>&2 2>&3)
|
|
||||||
|
|
||||||
case $CHOICE in
|
case $CHOICE in
|
||||||
1)
|
1)
|
||||||
@ -629,6 +643,7 @@ install_script() {
|
|||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
check_container_resources() {
|
check_container_resources() {
|
||||||
# Check actual RAM & Cores
|
# Check actual RAM & Cores
|
||||||
current_ram=$(free -m | awk 'NR==2{print $2}')
|
current_ram=$(free -m | awk 'NR==2{print $2}')
|
||||||
|
Loading…
Reference in New Issue
Block a user