CHOICE=$(whiptail --title "SOURCES" --menu "The package manager will use the correct sources to update and install packages on your Proxmox VE 8 server.\n \nCorrect Proxmox VE 8 sources?"14582\
CHOICE=$(whiptail --title "PVE-ENTERPRISE" --menu "The 'pve-enterprise' repository is only available to users who have purchased a Proxmox VE subscription.\n \nDisable 'pve-enterprise' repository?"14582\
CHOICE=$(whiptail --title "PVE-NO-SUBSCRIPTION" --menu "The 'pve-no-subscription' repository provides access to all of the open-source components of Proxmox VE.\n \nEnable 'pve-no-subscription' repository?"14582\
CHOICE=$(whiptail --title "CEPH PACKAGE REPOSITORIES" --menu "The 'Ceph Package Repositories' provides access to both the 'no-subscription' and 'enterprise' repositories.\n \nEnable 'ceph package repositories?"14582\
"yes"" "\
"no"" " 3>&2 2>&1 1>&3)
case$CHOICE in
yes)
msg_info "Enabling 'ceph package repositories'"
cat <<EOF >/etc/apt/sources.list.d/ceph.list
# deb http://download.proxmox.com/debian/ceph-quincy bookworm enterprise
deb http://download.proxmox.com/debian/ceph-quincy bookworm no-subscription
EOF
msg_ok "Enabled 'ceph package repositories'"
;;
no)
msg_error "Selected no to Enabling 'ceph package repositories'"
CHOICE=$(whiptail --title "PVETEST" --menu "The 'pvetest' repository can give advanced users access to new features and updates before they are officially released.\n \nAdd (Disabled) 'pvetest' repository?"14582\
"yes"" "\
"no"" " 3>&2 2>&1 1>&3)
case$CHOICE in
yes)
msg_info "Adding 'pvetest' repository and set disabled"
CHOICE=$(whiptail --title "SUBSCRIPTION NAG" --menu "This will disable the nag message reminding you to purchase a subscription every time you log in to the web interface.\n \nDisable subscription nag?"14582\
whiptail --msgbox --title "Support Subscriptions""Supporting the software's development team is essential. Check their official website's Support Subscriptions for pricing. Without their dedicated work, we wouldn't have this exceptional software."1058
whiptail --msgbox --title "Support Subscriptions""Supporting the software's development team is essential. Check their official website's Support Subscriptions for pricing. Without their dedicated work, we wouldn't have this exceptional software."1058
msg_error "Selected no to Disabling subscription nag"
;;
esac
fi
if systemctl is-active --quiet pve-ha-lrm;then
CHOICE=$(whiptail --title "HIGH AVAILABILITY" --menu "If you plan to utilize a single node instead of a clustered environment, you can disable unnecessary high availability (HA) services, thus reclaiming system resources.\n\nIf HA becomes necessary at a later stage, the services can be re-enabled.\n\nDisable high availability?"18582\
"yes"" "\
"no"" " 3>&2 2>&1 1>&3)
case$CHOICE in
yes)
msg_info "Disabling high availability"
systemctl stop pve-ha-lrm
systemctl disable pve-ha-lrm &>/dev/null
systemctl stop pve-ha-crm
systemctl disable pve-ha-crm &>/dev/null
systemctl stop corosync
systemctl disable corosync &>/dev/null
msg_ok "Disabled high availability"
;;
no)
msg_error "Selected no to Disabling high availability"
;;
esac
fi
CHOICE=$(whiptail --title "UPDATE" --menu "\nUpdate Proxmox VE 8 now?"11582\
"yes"" "\
"no"" " 3>&2 2>&1 1>&3)
case$CHOICE in
yes)
msg_info "Updating Proxmox VE 8 (Patience)"
apt-get update &>/dev/null
apt-get -y dist-upgrade &>/dev/null
msg_ok "Updated Proxmox VE 8"
;;
no)
msg_error "Selected no to Updating Proxmox VE 8"
;;
esac
CHOICE=$(whiptail --title "REBOOT" --menu "\nReboot Proxmox VE 8 now? (recommended)"11582\
"yes"" "\
"no"" " 3>&2 2>&1 1>&3)
case$CHOICE in
yes)
msg_info "Rebooting Proxmox VE 8"
sleep 2
msg_ok "Completed Post Install Routines"
reboot
;;
no)
msg_error "Selected no to Rebooting Proxmox VE 8 (Reboot recommended)"
msg_ok "Completed Post Install Routines"
;;
esac
}
header_info
echo -e "\nThis script will Perform Post Install Routines.\n"
while true;do
read -p "Start the Proxmox VE 8 Post Install Script (y/n)?" yn