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
function update_script() {
header_info
msg_info "Updating Alpine Packages"
apk update
apk upgrade
msg_ok "Updated Alpine Packages"
msg_info "Updating Gitea"
apk upgrade gitea
msg_ok "Updated Gitea"
msg_info "Restarting Gitea"
rc-service gitea restart
msg_ok "Restarted Gitea"
exit 0
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
case $CHOICE in
1)
apk update && apk upgrade
exit
;;
2)
apk update && apk upgrade
apk upgrade gitea
rc-service gitea restart
exit
;;
esac
done
}
start