Update alpine-gitea.sh

This commit is contained in:
CanbiZ 2025-03-26 16:29:25 +01:00
parent 6d3a08eaf8
commit bfecf04ffd

View File

@ -20,20 +20,34 @@ color
catch_errors catch_errors
function update_script() { function update_script() {
if ! apk -e info newt >/dev/null 2>&1; then
apk add -q newt
fi
while true; do
CHOICE=$(
whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --menu "Select option" 11 58 2 \
"1" "Update Alpine" \
"2" "Update Gitea" 3>&2 2>&1 1>&3
)
exit_status=$?
if [ $exit_status == 1 ]; then
clear
exit-script
fi
header_info header_info
msg_info "Updating Alpine Packages" case $CHOICE in
apk update 1)
apk upgrade apk update && apk upgrade
msg_ok "Updated Alpine Packages" exit
;;
msg_info "Updating Gitea" 2)
apk update && apk upgrade
apk upgrade gitea apk upgrade gitea
msg_ok "Updated Gitea"
msg_info "Restarting Gitea"
rc-service gitea restart rc-service gitea restart
msg_ok "Restarted Gitea" exit
exit 0 ;;
esac
done
} }
start start