From ad18c05686456f99deb731d6bab82a8b703cf8af Mon Sep 17 00:00:00 2001 From: CanbiZ <47820557+MickLesk@users.noreply.github.com> Date: Mon, 18 Nov 2024 21:09:10 +0100 Subject: [PATCH] Massive Update (Remove StorageCheck (old) + Add Ressource & StorageCheck, Remove Whiptail, Remove PCT Ressource Set (#333) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Massive Update (Remove StorageCheck (old) + Add Ressource & StorageCheck, Remove Whiptail, Remove PCT Ressource Set * Update calibre-web.sh * Update cockpit.sh * Update cronicle.sh * Update homeassistant-core.sh * Update podman-homeassistant.sh * Update node-red.sh * Update plex.sh * Update wallos.sh * Revert "Update wallos.sh" This reverts commit ea6311e19076b3c290eb1e4dd5cb04afd56d0f56. * Update homeassistant.sh * Update ct/cronicle.sh Co-authored-by: Håvard Gjøby Thom <34199185+havardthom@users.noreply.github.com> --------- Co-authored-by: Håvard Gjøby Thom <34199185+havardthom@users.noreply.github.com> --- ct/actualbudget.sh | 8 +++----- ct/adguard.sh | 2 ++ ct/adventurelog.sh | 6 ++---- ct/agentdvr.sh | 2 ++ ct/apache-cassandra.sh | 2 ++ ct/apache-couchdb.sh | 2 ++ ct/apt-cacher-ng.sh | 2 ++ ct/archivebox.sh | 6 ++---- ct/aria2.sh | 2 ++ ct/audiobookshelf.sh | 2 ++ ct/autobrr.sh | 2 ++ ct/bazarr.sh | 2 ++ ct/blocky.sh | 2 ++ ct/bookstack.sh | 6 ++---- ct/bunkerweb.sh | 2 ++ ct/caddy.sh | 2 ++ ct/calibre-web.sh | 9 +++------ ct/casaos.sh | 2 ++ ct/changedetection.sh | 2 ++ ct/channels.sh | 2 ++ ct/cloudflared.sh | 2 ++ ct/cockpit.sh | 4 +++- ct/commafeed.sh | 2 ++ ct/cronicle.sh | 4 +++- ct/daemonsync.sh | 2 ++ ct/dashy.sh | 2 ++ ct/debian.sh | 2 ++ ct/deconz.sh | 2 ++ ct/deluge.sh | 2 ++ ct/docker.sh | 2 ++ ct/dockge.sh | 2 ++ ct/emby.sh | 2 ++ ct/emqx.sh | 2 ++ ct/ersatztv.sh | 2 ++ ct/esphome.sh | 2 ++ ct/evcc.sh | 2 ++ ct/fenrus.sh | 2 ++ ct/fhem.sh | 2 ++ ct/flaresolverr.sh | 7 ++----- ct/flowiseai.sh | 7 ++----- ct/forgejo.sh | 2 ++ ct/frigate.sh | 6 +++--- ct/gitea.sh | 2 ++ ct/go2rtc.sh | 2 ++ ct/gokapi.sh | 2 ++ ct/gotify.sh | 2 ++ ct/grafana.sh | 2 ++ ct/grocy.sh | 2 ++ ct/headscale.sh | 3 ++- ct/heimdall-dashboard.sh | 2 ++ ct/hivemq.sh | 2 ++ ct/homarr.sh | 6 ++---- ct/homeassistant-core.sh | 4 +++- ct/homeassistant.sh | 5 ++++- ct/homebox.sh | 6 ++---- ct/homebridge.sh | 2 ++ ct/homepage.sh | 2 ++ ct/homer.sh | 2 ++ ct/hyperhdr.sh | 2 ++ ct/hyperion.sh | 2 ++ ct/influxdb.sh | 2 ++ ct/iobroker.sh | 2 ++ ct/iventoy.sh | 3 +++ ct/jackett.sh | 2 ++ ct/jellyfin.sh | 2 ++ ct/jellyseerr.sh | 12 ++---------- ct/kavita.sh | 2 ++ ct/keycloak.sh | 2 ++ ct/kubo.sh | 2 ++ ct/lazylibrarian.sh | 2 ++ ct/lidarr.sh | 2 ++ ct/linkwarden.sh | 4 ++-- ct/lldap.sh | 2 ++ ct/mafl.sh | 8 ++------ ct/magicmirror.sh | 2 ++ ct/mariadb.sh | 2 ++ ct/matterbridge.sh | 2 ++ ct/mediamtx.sh | 3 ++- ct/medusa.sh | 2 ++ ct/memos.sh | 2 ++ ct/meshcentral.sh | 2 ++ ct/metube.sh | 6 ++---- ct/mongodb.sh | 2 ++ ct/motioneye.sh | 2 ++ ct/mqtt.sh | 2 ++ ct/myspeed.sh | 6 ++---- ct/mysql.sh | 2 ++ ct/n8n.sh | 2 ++ ct/navidrome.sh | 2 ++ ct/neo4j.sh | 2 ++ ct/nextcloudpi.sh | 2 ++ ct/nginxproxymanager.sh | 6 ++---- ct/nocodb.sh | 2 ++ ct/node-red.sh | 4 +++- ct/notifiarr.sh | 2 ++ ct/ntfy.sh | 2 ++ ct/nzbget.sh | 2 ++ ct/octoprint.sh | 2 ++ ct/ollama.sh | 2 ++ ct/omada.sh | 2 ++ ct/ombi.sh | 2 ++ ct/omv.sh | 2 ++ ct/openhab.sh | 2 ++ ct/openobserve.sh | 2 ++ ct/openwebui.sh | 2 ++ ct/overseerr.sh | 2 ++ ct/owncast.sh | 2 ++ ct/pairdrop.sh | 2 ++ ct/paperless-ngx.sh | 2 ++ ct/pbs.sh | 2 ++ ct/peanut.sh | 7 ++----- ct/petio.sh | 2 ++ ct/photoprism.sh | 2 ++ ct/pialert.sh | 2 ++ ct/pihole.sh | 2 ++ ct/pingvin.sh | 2 ++ ct/plex.sh | 5 +++-- ct/podman-homeassistant.sh | 5 ++++- ct/podman.sh | 2 ++ ct/postgresql.sh | 2 ++ ct/prometheus.sh | 2 ++ ct/prowlarr.sh | 2 ++ ct/qbittorrent.sh | 2 ++ ct/rabbitmq.sh | 6 ++---- ct/radarr.sh | 2 ++ ct/readarr.sh | 2 ++ ct/readeck.sh | 2 ++ ct/recyclarr.sh | 2 ++ ct/redis.sh | 2 ++ ct/rtsptoweb.sh | 2 ++ ct/runtipi.sh | 2 ++ ct/sabnzbd.sh | 2 ++ ct/scrypted.sh | 2 ++ ct/sftpgo.sh | 2 ++ ct/shinobi.sh | 2 ++ ct/smokeping.sh | 2 ++ ct/sonarr.sh | 2 ++ ct/spoolman.sh | 6 ++---- ct/stirling-pdf.sh | 2 ++ ct/syncthing.sh | 2 ++ ct/tandoor.sh | 8 ++------ ct/tasmoadmin.sh | 2 ++ ct/tautulli.sh | 2 ++ ct/tdarr.sh | 2 ++ ct/technitiumdns.sh | 2 ++ ct/threadfin.sh | 2 ++ ct/tianji.sh | 12 ++---------- ct/traccar.sh | 2 ++ ct/traefik.sh | 2 ++ ct/transmission.sh | 2 ++ ct/trilium.sh | 2 ++ ct/ubuntu.sh | 2 ++ ct/umami.sh | 11 ++--------- ct/umbrel.sh | 2 ++ ct/unifi.sh | 2 ++ ct/unmanic.sh | 2 ++ ct/uptimekuma.sh | 2 ++ ct/vaultwarden.sh | 5 ----- ct/vikunja.sh | 6 ++---- ct/wastebin.sh | 2 ++ ct/watchyourlan.sh | 2 ++ ct/wavelog.sh | 2 ++ ct/whisparr.sh | 2 ++ ct/whoogle.sh | 2 ++ ct/wikijs.sh | 2 ++ ct/wireguard.sh | 3 +++ ct/yunohost.sh | 2 ++ ct/zabbix.sh | 2 ++ ct/zigbee2mqtt.sh | 2 ++ ct/zipline.sh | 6 ++---- ct/zoraxy.sh | 2 ++ ct/zwave-js-ui.sh | 2 ++ 172 files changed, 356 insertions(+), 135 deletions(-) diff --git a/ct/actualbudget.sh b/ct/actualbudget.sh index 80d1e0fb2..009fb9527 100644 --- a/ct/actualbudget.sh +++ b/ct/actualbudget.sh @@ -54,8 +54,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/actualbudget ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 msg_info "Updating ${APP}" systemctl stop actualbudget.service cd /opt/actualbudget @@ -69,10 +70,7 @@ exit start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 1024 -pct set $CTID -cores 1 -msg_ok "Set Container to Normal Resources" + msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:5006${CL} \n" diff --git a/ct/adguard.sh b/ct/adguard.sh index dd07e48b8..165e66610 100644 --- a/ct/adguard.sh +++ b/ct/adguard.sh @@ -54,6 +54,8 @@ function default_settings() { } function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/AdGuardHome ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "Adguard Home should be updated via the user interface." exit diff --git a/ct/adventurelog.sh b/ct/adventurelog.sh index 5fd53b0b1..f7806968d 100644 --- a/ct/adventurelog.sh +++ b/ct/adventurelog.sh @@ -54,11 +54,9 @@ function default_settings() { } function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/adventurelog ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi RELEASE=$(curl -s https://api.github.com/repos/seanmorley15/AdventureLog/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then msg_info "Stopping Services" diff --git a/ct/agentdvr.sh b/ct/agentdvr.sh index 006d75da9..82cab2430 100644 --- a/ct/agentdvr.sh +++ b/ct/agentdvr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/agentdvr ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/apache-cassandra.sh b/ct/apache-cassandra.sh index f5b0aea74..81486eff7 100644 --- a/ct/apache-cassandra.sh +++ b/ct/apache-cassandra.sh @@ -56,6 +56,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/cassandra.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/apache-couchdb.sh b/ct/apache-couchdb.sh index 278ba73d7..4aab856a6 100644 --- a/ct/apache-couchdb.sh +++ b/ct/apache-couchdb.sh @@ -56,6 +56,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/couchdb.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/apt-cacher-ng.sh b/ct/apt-cacher-ng.sh index 9dc1115ae..f363b0e37 100644 --- a/ct/apt-cacher-ng.sh +++ b/ct/apt-cacher-ng.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/archivebox.sh b/ct/archivebox.sh index 0ad2ab7ba..7569b9dcc 100644 --- a/ct/archivebox.sh +++ b/ct/archivebox.sh @@ -54,11 +54,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/archivebox ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi msg_info "Stopping ${APP}" systemctl stop archivebox msg_ok "Stopped ${APP}" diff --git a/ct/aria2.sh b/ct/aria2.sh index e58e51a63..e23e7fa25 100644 --- a/ct/aria2.sh +++ b/ct/aria2.sh @@ -53,6 +53,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/audiobookshelf.sh b/ct/audiobookshelf.sh index 5c57a966a..8edc13bf7 100644 --- a/ct/audiobookshelf.sh +++ b/ct/audiobookshelf.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/trusted.gpg.d/audiobookshelf-ppa.asc ]]; then msg_error "No ${APP} Installation Found!"; exit; fi echo "This application receives updates through the APT package manager." exit diff --git a/ct/autobrr.sh b/ct/autobrr.sh index 5cd19e7ab..d4d98a117 100644 --- a/ct/autobrr.sh +++ b/ct/autobrr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /root/.config/autobrr/config.toml ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping ${APP} LXC" systemctl stop autobrr.service diff --git a/ct/bazarr.sh b/ct/bazarr.sh index 7897f4c4a..f6118d992 100755 --- a/ct/bazarr.sh +++ b/ct/bazarr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var/lib/bazarr/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/blocky.sh b/ct/blocky.sh index 634f21c27..3bd6ed7b0 100644 --- a/ct/blocky.sh +++ b/ct/blocky.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/bookstack.sh b/ct/bookstack.sh index 5e908874c..0d52f3900 100644 --- a/ct/bookstack.sh +++ b/ct/bookstack.sh @@ -55,11 +55,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/bookstack ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi RELEASE=$(curl -s https://api.github.com/repos/BookStackApp/BookStack/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then msg_info "Stopping Apache2" diff --git a/ct/bunkerweb.sh b/ct/bunkerweb.sh index 7d2cfdbf0..2a9c2b286 100644 --- a/ct/bunkerweb.sh +++ b/ct/bunkerweb.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /etc/bunkerweb ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/bunkerity/bunkerweb/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') diff --git a/ct/caddy.sh b/ct/caddy.sh index 12c852071..0945c298c 100644 --- a/ct/caddy.sh +++ b/ct/caddy.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /etc/caddy ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/calibre-web.sh b/ct/calibre-web.sh index a8c7fad96..5d8a94189 100644 --- a/ct/calibre-web.sh +++ b/ct/calibre-web.sh @@ -54,12 +54,13 @@ function default_settings() { } function update_script() { + header_info + check_container_storage + check_container_resources if [[ ! -f /etc/systemd/system/cps.service ]]; then msg_error "No ${APP} Installation Found!" exit fi - whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 - header_info msg_info "Updating $APP LXC" systemctl stop cps cd /opt/kepubify @@ -156,10 +157,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 512 -pct set $CTID -cores 1 -msg_ok "Set Container to Normal Resources" msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:8083${CL} \n" diff --git a/ct/casaos.sh b/ct/casaos.sh index c3fda0b90..ebd0050c3 100644 --- a/ct/casaos.sh +++ b/ct/casaos.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/changedetection.sh b/ct/changedetection.sh index cb4c8f840..817862c19 100644 --- a/ct/changedetection.sh +++ b/ct/changedetection.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/changedetection.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" if ! dpkg -s libjpeg-dev >/dev/null 2>&1; then diff --git a/ct/channels.sh b/ct/channels.sh index b42361fbf..dad211a56 100644 --- a/ct/channels.sh +++ b/ct/channels.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/channels-dvr ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/cloudflared.sh b/ct/cloudflared.sh index 667499259..cc6d1e821 100644 --- a/ct/cloudflared.sh +++ b/ct/cloudflared.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/cockpit.sh b/ct/cockpit.sh index 167e766c4..213817e7a 100644 --- a/ct/cockpit.sh +++ b/ct/cockpit.sh @@ -54,6 +54,9 @@ function default_settings() { } function update_script() { +header_info +check_container_storage +check_container_resources if [[ ! -d /etc/cockpit ]]; then msg_error "No ${APP} Installation Found!"; exit; fi UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --radiolist --cancel-button Exit-Script "Spacebar = Select" 11 58 4 \ "1" "Update LXC" ON \ @@ -62,7 +65,6 @@ UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --radio "4" "Install cockpit-navigator" OFF \ 3>&1 1>&2 2>&3) -header_info if [ "$UPD" == "1" ]; then msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/commafeed.sh b/ct/commafeed.sh index 2ad9262f4..0f47d12c6 100644 --- a/ct/commafeed.sh +++ b/ct/commafeed.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/commafeed ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -sL https://api.github.com/repos/Athou/commafeed/releases/latest | grep '"tag_name":' | cut -d'"' -f4) if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then diff --git a/ct/cronicle.sh b/ct/cronicle.sh index aa5423e22..0915c4f98 100644 --- a/ct/cronicle.sh +++ b/ct/cronicle.sh @@ -53,13 +53,15 @@ function default_settings() { } function update_script() { +header_info +check_container_storage +check_container_resources UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --radiolist --cancel-button Exit-Script "Spacebar = Select" 11 58 2 \ "1" "Update ${APP}" ON \ "2" "Install ${APP} Worker" OFF \ 3>&1 1>&2 2>&3) if [ "$UPD" == "1" ]; then -header_info if [[ ! -d /opt/cronicle ]]; then msg_error "No ${APP} Installation Found!"; exit; fi if [[ "$(node -v | cut -d 'v' -f 2)" == "18."* ]]; then if ! command -v npm >/dev/null 2>&1; then diff --git a/ct/daemonsync.sh b/ct/daemonsync.sh index 4e8069e29..071832260 100644 --- a/ct/daemonsync.sh +++ b/ct/daemonsync.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/dashy.sh b/ct/dashy.sh index f4c806142..6bcacc35f 100644 --- a/ct/dashy.sh +++ b/ct/dashy.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/dashy/public/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -sL https://api.github.com/repos/Lissy93/dashy/releases/latest | grep '"tag_name":' | cut -d'"' -f4) diff --git a/ct/debian.sh b/ct/debian.sh index 0af0c4974..6120d5ab5 100644 --- a/ct/debian.sh +++ b/ct/debian.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/deconz.sh b/ct/deconz.sh index f5df37c6c..c994a8abf 100644 --- a/ct/deconz.sh +++ b/ct/deconz.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/deconz.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/deluge.sh b/ct/deluge.sh index e938be22e..88a0ccd55 100644 --- a/ct/deluge.sh +++ b/ct/deluge.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/deluged.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/docker.sh b/ct/docker.sh index 2b9a880c9..b45ba0621 100644 --- a/ct/docker.sh +++ b/ct/docker.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/dockge.sh b/ct/dockge.sh index 38f6eb2a6..d05023c0e 100644 --- a/ct/dockge.sh +++ b/ct/dockge.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/dockge ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" cd /opt/dockge diff --git a/ct/emby.sh b/ct/emby.sh index 452affaaf..a6c913b40 100644 --- a/ct/emby.sh +++ b/ct/emby.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/emby-server ]]; then msg_error "No ${APP} Installation Found!"; exit; fi LATEST=$(curl -sL https://api.github.com/repos/MediaBrowser/Emby.Releases/releases/latest | grep '"tag_name":' | cut -d'"' -f4) msg_info "Stopping ${APP}" diff --git a/ct/emqx.sh b/ct/emqx.sh index 59aeeb663..070e38ff9 100644 --- a/ct/emqx.sh +++ b/ct/emqx.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/ersatztv.sh b/ct/ersatztv.sh index 52cb9727c..75ff27579 100644 --- a/ct/ersatztv.sh +++ b/ct/ersatztv.sh @@ -56,6 +56,8 @@ function default_settings() { } function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/ErsatzTV ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping ErsatzTV" diff --git a/ct/esphome.sh b/ct/esphome.sh index d5184a8ed..ee0912652 100644 --- a/ct/esphome.sh +++ b/ct/esphome.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/esphomeDashboard.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping ESPHome" systemctl stop esphomeDashboard diff --git a/ct/evcc.sh b/ct/evcc.sh index 17834d69e..003409e1f 100644 --- a/ct/evcc.sh +++ b/ct/evcc.sh @@ -53,6 +53,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/evcc-stable.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating evcc LXC" apt update &>/dev/null diff --git a/ct/fenrus.sh b/ct/fenrus.sh index af76aca15..0138a9ce7 100644 --- a/ct/fenrus.sh +++ b/ct/fenrus.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/${APP} ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/fhem.sh b/ct/fhem.sh index 482373be1..6ffd51ad7 100644 --- a/ct/fhem.sh +++ b/ct/fhem.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/fhem.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/flaresolverr.sh b/ct/flaresolverr.sh index b3018bdc8..1946c9329 100644 --- a/ct/flaresolverr.sh +++ b/ct/flaresolverr.sh @@ -55,8 +55,9 @@ function default_settings() { function update_script() { header_info + check_container_storage + check_container_resources if [[ ! -f /etc/systemd/system/flaresolverr.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi - whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 RELEASE=$(wget -q https://github.com/FlareSolverr/FlareSolverr/releases/latest -O - | grep "title>Release" | cut -d " " -f 4) if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then msg_info "Updating $APP LXC" @@ -77,10 +78,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 512 -pct set $CTID -cores 1 -msg_ok "Set Container to Normal Resources" msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:8191${CL} \n" diff --git a/ct/flowiseai.sh b/ct/flowiseai.sh index b2fd762c4..2b58a7399 100644 --- a/ct/flowiseai.sh +++ b/ct/flowiseai.sh @@ -54,8 +54,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/flowise.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 msg_info "Updating ${APP}" systemctl stop flowise npm install -g flowise --upgrade @@ -68,10 +69,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 2048 -pct set $CTID -cores 2 -msg_ok "Set Container to Normal Resources" msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:3000${CL} \n" diff --git a/ct/forgejo.sh b/ct/forgejo.sh index 606430b97..8199ec578 100644 --- a/ct/forgejo.sh +++ b/ct/forgejo.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/forgejo ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping ${APP}" systemctl stop forgejo diff --git a/ct/frigate.sh b/ct/frigate.sh index 14dd5f612..ca0104f82 100644 --- a/ct/frigate.sh +++ b/ct/frigate.sh @@ -54,6 +54,9 @@ function default_settings() { } function update_script() { + header_info + check_container_storage + check_container_resources if [[ ! -f /etc/systemd/system/frigate.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "To update Frigate, create a new container and transfer your configuration." exit @@ -63,9 +66,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 1024 -msg_ok "Set Container to Normal Resources" msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:5000${CL} \n" diff --git a/ct/gitea.sh b/ct/gitea.sh index 7b09f0b25..0779cc8d3 100644 --- a/ct/gitea.sh +++ b/ct/gitea.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /usr/local/bin/gitea ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(wget -q https://github.com/go-gitea/gitea/releases/latest -O - | grep "title>Release" | cut -d " " -f 4 | sed 's/^v//') msg_info "Updating $APP to ${RELEASE}" diff --git a/ct/go2rtc.sh b/ct/go2rtc.sh index 03ad250c7..741ee0d22 100644 --- a/ct/go2rtc.sh +++ b/ct/go2rtc.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/go2rtc ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP" systemctl stop go2rtc diff --git a/ct/gokapi.sh b/ct/gokapi.sh index eafd79799..79814f5fa 100644 --- a/ct/gokapi.sh +++ b/ct/gokapi.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/gokapi ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/gotify.sh b/ct/gotify.sh index 5ef748f7d..c80fb9efb 100644 --- a/ct/gotify.sh +++ b/ct/gotify.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/gotify ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/gotify/server/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') diff --git a/ct/grafana.sh b/ct/grafana.sh index 36c6832d7..7042a2fe5 100644 --- a/ct/grafana.sh +++ b/ct/grafana.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/grafana.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" apt-get update &>/dev/null diff --git a/ct/grocy.sh b/ct/grocy.sh index 58e21318d..945c7aea0 100644 --- a/ct/grocy.sh +++ b/ct/grocy.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apache2/sites-available/grocy.conf ]]; then msg_error "No ${APP} Installation Found!"; exit; fi php_version=$(php -v | head -n 1 | awk '{print $2}') if [[ ! $php_version == "8.3"* ]]; then diff --git a/ct/headscale.sh b/ct/headscale.sh index 619e2475a..5138b8112 100644 --- a/ct/headscale.sh +++ b/ct/headscale.sh @@ -54,8 +54,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /etc/headscale ]]; then msg_error "No ${APP} Installation Found!"; exit; fi - RELEASE=$(curl -s https://api.github.com/repos/juanfont/headscale/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then msg_info "Stopping ${APP}" diff --git a/ct/heimdall-dashboard.sh b/ct/heimdall-dashboard.sh index 1d3e44d0d..265acb0b5 100644 --- a/ct/heimdall-dashboard.sh +++ b/ct/heimdall-dashboard.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/Heimdall ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -sX GET "https://api.github.com/repos/linuxserver/Heimdall/releases/latest" | awk '/tag_name/{print $4;exit}' FS='[""]') if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then diff --git a/ct/hivemq.sh b/ct/hivemq.sh index 26a92005f..9356ad904 100644 --- a/ct/hivemq.sh +++ b/ct/hivemq.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/homarr.sh b/ct/homarr.sh index fa3ca417f..1e7210b3c 100644 --- a/ct/homarr.sh +++ b/ct/homarr.sh @@ -55,11 +55,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/homarr ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi RELEASE=$(curl -s https://api.github.com/repos/ajnart/homarr/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then msg_info "Stopping Services" diff --git a/ct/homeassistant-core.sh b/ct/homeassistant-core.sh index 4a673328d..001f98f18 100644 --- a/ct/homeassistant-core.sh +++ b/ct/homeassistant-core.sh @@ -53,6 +53,9 @@ function default_settings() { } function update_script() { + header_info + check_container_storage + check_container_resources if [[ ! -d /srv/homeassistant ]]; then msg_error "No ${APP} Installation Found!" exit @@ -64,7 +67,6 @@ function update_script() { "2" "Install HACS" OFF \ "3" "Install FileBrowser" OFF \ 3>&1 1>&2 2>&3) - header_info if [ "$UPD" == "1" ]; then if (whiptail --backtitle "Proxmox VE Helper Scripts" --defaultno --title "SELECT BRANCH" --yesno "Use Beta Branch?" 10 58); then clear diff --git a/ct/homeassistant.sh b/ct/homeassistant.sh index 7a2444078..bb0a325a0 100644 --- a/ct/homeassistant.sh +++ b/ct/homeassistant.sh @@ -53,6 +53,9 @@ function default_settings() { } function update_script() { + header_info + check_container_storage + check_container_resources if [[ ! -d /var/lib/docker/volumes/hass_config/_data ]]; then msg_error "No ${APP} Installation Found!" exit @@ -63,7 +66,7 @@ function update_script() { "3" "Install HACS" OFF \ "4" "Install FileBrowser" OFF \ 3>&1 1>&2 2>&3) - header_info + if [ "$UPD" == "1" ]; then msg_info "Updating All Containers" CONTAINER_LIST="${1:-$(docker ps -q)}" diff --git a/ct/homebox.sh b/ct/homebox.sh index b05ba0642..2441bc0b7 100644 --- a/ct/homebox.sh +++ b/ct/homebox.sh @@ -54,11 +54,9 @@ function default_settings() { } function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /opt/homebox ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi RELEASE=$(curl -s https://api.github.com/repos/sysadminsmedia/homebox/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then msg_info "Stopping ${APP}" diff --git a/ct/homebridge.sh b/ct/homebridge.sh index e511b7270..b371d9c0c 100644 --- a/ct/homebridge.sh +++ b/ct/homebridge.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/homebridge.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/homepage.sh b/ct/homepage.sh index 4cda21ab5..ddce1e8a3 100644 --- a/ct/homepage.sh +++ b/ct/homepage.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/homepage ]]; then msg_error "No ${APP} Installation Found!"; exit; fi if [[ "$(node -v | cut -d 'v' -f 2)" == "18."* ]]; then if ! command -v npm >/dev/null 2>&1; then diff --git a/ct/homer.sh b/ct/homer.sh index 7aa5cbb58..bb2695d76 100644 --- a/ct/homer.sh +++ b/ct/homer.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/homer ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping ${APP}" systemctl stop homer diff --git a/ct/hyperhdr.sh b/ct/hyperhdr.sh index 60d7b2d8a..023a326fd 100644 --- a/ct/hyperhdr.sh +++ b/ct/hyperhdr.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/hyperion.sh b/ct/hyperion.sh index 36541dd67..f9134e69e 100644 --- a/ct/hyperion.sh +++ b/ct/hyperion.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/hyperion.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/influxdb.sh b/ct/influxdb.sh index 8cf91d48f..6e4f683cf 100644 --- a/ct/influxdb.sh +++ b/ct/influxdb.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/influxdata.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" apt-get update &>/dev/null diff --git a/ct/iobroker.sh b/ct/iobroker.sh index 50ef85c56..eb5a1f804 100644 --- a/ct/iobroker.sh +++ b/ct/iobroker.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/iobroker ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/iventoy.sh b/ct/iventoy.sh index f58d7427f..5e38f05f5 100644 --- a/ct/iventoy.sh +++ b/ct/iventoy.sh @@ -53,6 +53,9 @@ function default_settings() { } function update_script() { +header_info +check_container_storage +check_container_resources if [[ ! -d /opt/iventoy ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/jackett.sh b/ct/jackett.sh index 7548b7def..7f336510f 100644 --- a/ct/jackett.sh +++ b/ct/jackett.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/jackett.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(wget -q https://github.com/Jackett/Jackett/releases/latest -O - | grep "title>Release" | cut -d " " -f 4) if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then diff --git a/ct/jellyfin.sh b/ct/jellyfin.sh index 41c073a32..e15623523 100644 --- a/ct/jellyfin.sh +++ b/ct/jellyfin.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /usr/lib/jellyfin ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/jellyseerr.sh b/ct/jellyseerr.sh index b4ac5c276..602ebad03 100644 --- a/ct/jellyseerr.sh +++ b/ct/jellyseerr.sh @@ -54,12 +54,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/jellyseerr ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi -whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your Jellyseerr LXC to 4vcpu and 4096RAM for the build process before continuing" 10 75 if ! command -v pnpm &> /dev/null; then msg_error "pnpm not found. Installing..." npm install -g pnpm &>/dev/null @@ -107,11 +104,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 2048 -pct set $CTID -cores 2 -msg_ok "Set Container to Normal Resources" - msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:5055${CL} \n" diff --git a/ct/kavita.sh b/ct/kavita.sh index 3b2286d43..e80d64631 100644 --- a/ct/kavita.sh +++ b/ct/kavita.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/Kavita ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" systemctl stop kavita diff --git a/ct/keycloak.sh b/ct/keycloak.sh index 43d9f44cc..5dad21ca4 100644 --- a/ct/keycloak.sh +++ b/ct/keycloak.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/keycloak.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" diff --git a/ct/kubo.sh b/ct/kubo.sh index 587cb66b1..335690f20 100644 --- a/ct/kubo.sh +++ b/ct/kubo.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /usr/local/kubo ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(wget -q https://github.com/ipfs/kubo/releases/latest -O - | grep "title>Release" | cut -d " " -f 4) if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then diff --git a/ct/lazylibrarian.sh b/ct/lazylibrarian.sh index 47f4f1b39..f6e1d1a60 100644 --- a/ct/lazylibrarian.sh +++ b/ct/lazylibrarian.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/LazyLibrarian/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping LazyLibrarian" systemctl stop lazylibrarian diff --git a/ct/lidarr.sh b/ct/lidarr.sh index ec04267bd..11e3359b4 100644 --- a/ct/lidarr.sh +++ b/ct/lidarr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var/lib/lidarr/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/linkwarden.sh b/ct/linkwarden.sh index 7292d5036..1ba50c52a 100644 --- a/ct/linkwarden.sh +++ b/ct/linkwarden.sh @@ -65,7 +65,7 @@ if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP} msg_info "Updating ${APP} to ${RELEASE}" cd /opt - mv /opt/linkwarden /opt/linkwarden_bak + mv /opt/linkwarden/.env /opt/.env RELEASE=$(curl -s https://api.github.com/repos/linkwarden/linkwarden/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }') wget -q "https://github.com/linkwarden/linkwarden/archive/refs/tags/${RELEASE}.zip" unzip -q ${RELEASE}.zip @@ -74,7 +74,7 @@ if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP} yarn &>/dev/null npx playwright install-deps &>/dev/null yarn playwright install &>/dev/null - cp /opt/linkwarden_bak/.env /opt/linkwarden/.env + cp /opt/.env /opt/linkwarden/.env yarn build &>/dev/null yarn prisma migrate deploy &>/dev/null echo "${RELEASE}" >/opt/${APP}_version.txt diff --git a/ct/lldap.sh b/ct/lldap.sh index 8f47ef2a9..a31ef14f5 100644 --- a/ct/lldap.sh +++ b/ct/lldap.sh @@ -56,6 +56,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/lldap.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP" apt update diff --git a/ct/mafl.sh b/ct/mafl.sh index df3dc8f40..730671d55 100644 --- a/ct/mafl.sh +++ b/ct/mafl.sh @@ -54,8 +54,9 @@ function default_settings() { function update_script() { header_info + check_container_storage + check_container_resources if [[ ! -d /opt/mafl ]]; then msg_error "No ${APP} Installation Found!"; exit; fi - whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 RELEASE=$(curl -s https://api.github.com/repos/hywax/mafl/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') msg_info "Updating Mafl to v${RELEASE} (Patience)" systemctl stop mafl @@ -75,11 +76,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 1024 -pct set $CTID -cores 1 -msg_ok "Set Container to Normal Resources" - msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:3000${CL} \n" diff --git a/ct/magicmirror.sh b/ct/magicmirror.sh index 55ef49051..6a92747f6 100644 --- a/ct/magicmirror.sh +++ b/ct/magicmirror.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/magicmirror ]]; then msg_error "No ${APP} Installation Found!"; exit; fi if [[ "$(node -v | cut -d 'v' -f 2)" == "18."* ]]; then if ! command -v npm >/dev/null 2>&1; then diff --git a/ct/mariadb.sh b/ct/mariadb.sh index 0341ddc77..526231095 100644 --- a/ct/mariadb.sh +++ b/ct/mariadb.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/mariadb.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/matterbridge.sh b/ct/matterbridge.sh index 63254c060..8cac08a8e 100644 --- a/ct/matterbridge.sh +++ b/ct/matterbridge.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /root/Matterbridge ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "Update via the Matterbridge UI" exit diff --git a/ct/mediamtx.sh b/ct/mediamtx.sh index 3992c0cb6..f6acb4d6f 100644 --- a/ct/mediamtx.sh +++ b/ct/mediamtx.sh @@ -55,8 +55,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/mediamtx/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi - msg_error "There is currently no update path available." exit } diff --git a/ct/medusa.sh b/ct/medusa.sh index 24a77f340..e9e494135 100644 --- a/ct/medusa.sh +++ b/ct/medusa.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/medusa ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping ${APP}" systemctl stop medusa diff --git a/ct/memos.sh b/ct/memos.sh index da4ae6156..ab7017dd0 100644 --- a/ct/memos.sh +++ b/ct/memos.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/memos ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP (Patience)" cd /opt/memos diff --git a/ct/meshcentral.sh b/ct/meshcentral.sh index bdb3a648c..6f2ebe7c5 100644 --- a/ct/meshcentral.sh +++ b/ct/meshcentral.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/meshcentral ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/metube.sh b/ct/metube.sh index 425683c6e..ff09ace48 100644 --- a/ct/metube.sh +++ b/ct/metube.sh @@ -54,11 +54,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/metube ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi msg_info "Stopping ${APP} Service" systemctl stop metube msg_ok "Stopped ${APP} Service" diff --git a/ct/mongodb.sh b/ct/mongodb.sh index e255b9a78..44bbf386e 100644 --- a/ct/mongodb.sh +++ b/ct/mongodb.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/mongodb-org-7.0.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/motioneye.sh b/ct/motioneye.sh index 545656112..76e2cb652 100644 --- a/ct/motioneye.sh +++ b/ct/motioneye.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/motioneye.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" pip install motioneye --upgrade &>/dev/null diff --git a/ct/mqtt.sh b/ct/mqtt.sh index 705096666..0015fbb86 100644 --- a/ct/mqtt.sh +++ b/ct/mqtt.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/mosquitto/conf.d/default.conf ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/myspeed.sh b/ct/myspeed.sh index 99c7ef6c8..4d9601f2d 100644 --- a/ct/myspeed.sh +++ b/ct/myspeed.sh @@ -56,11 +56,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/myspeed ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi RELEASE=$(wget -q https://github.com/gnmyt/myspeed/releases/latest -O - | grep "title>Release" | cut -d " " -f 5) if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then diff --git a/ct/mysql.sh b/ct/mysql.sh index 02ffbb6df..06352bcd5 100644 --- a/ct/mysql.sh +++ b/ct/mysql.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /usr/share/keyrings/mysql.gpg ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/n8n.sh b/ct/n8n.sh index 22a58c0d2..ead77f732 100644 --- a/ct/n8n.sh +++ b/ct/n8n.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/n8n.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi if [[ "$(node -v | cut -d 'v' -f 2)" == "18."* ]]; then if ! command -v npm >/dev/null 2>&1; then diff --git a/ct/navidrome.sh b/ct/navidrome.sh index a6a0b38be..6a33bd238 100644 --- a/ct/navidrome.sh +++ b/ct/navidrome.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/navidrome ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/navidrome/navidrome/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') msg_info "Stopping ${APP}" diff --git a/ct/neo4j.sh b/ct/neo4j.sh index a23f88821..957576879 100644 --- a/ct/neo4j.sh +++ b/ct/neo4j.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /etc/neo4j ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" apt-get update &>/dev/null diff --git a/ct/nextcloudpi.sh b/ct/nextcloudpi.sh index 7eb52c7d9..c9a51281b 100644 --- a/ct/nextcloudpi.sh +++ b/ct/nextcloudpi.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /lib/systemd/system/nextcloud-domain.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/nginxproxymanager.sh b/ct/nginxproxymanager.sh index bfaa82223..476989bbf 100644 --- a/ct/nginxproxymanager.sh +++ b/ct/nginxproxymanager.sh @@ -55,11 +55,12 @@ function default_settings() { function update_script() { header_info + check_container_storage + check_container_resources if [[ ! -f /lib/systemd/system/npm.service ]]; then msg_error "No ${APP} Installation Found!" exit fi - whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 if ! command -v pnpm &> /dev/null; then msg_info "Installing pnpm" #export NODE_OPTIONS=--openssl-legacy-provider @@ -187,9 +188,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -cores 1 -msg_ok "Set Container to Normal Resources" msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:81${CL}\n" diff --git a/ct/nocodb.sh b/ct/nocodb.sh index e8fd6e710..98755f1bb 100644 --- a/ct/nocodb.sh +++ b/ct/nocodb.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/nocodb.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" systemctl stop nocodb.service diff --git a/ct/node-red.sh b/ct/node-red.sh index c5ff805eb..b1fac4c2e 100644 --- a/ct/node-red.sh +++ b/ct/node-red.sh @@ -53,12 +53,14 @@ function default_settings() { } function update_script() { +header_info +check_container_storage +check_container_resources if [[ ! -d /root/.node-red ]]; then msg_error "No ${APP} Installation Found!"; exit; fi UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --radiolist --cancel-button Exit-Script "Spacebar = Select" 11 58 2 \ "1" "Update ${APP}" ON \ "2" "Install Themes" OFF \ 3>&1 1>&2 2>&3) -header_info if [ "$UPD" == "1" ]; then if [[ "$(node -v | cut -d 'v' -f 2)" == "18."* ]]; then if ! command -v npm >/dev/null 2>&1; then diff --git a/ct/notifiarr.sh b/ct/notifiarr.sh index ede2911c1..3ab68b621 100644 --- a/ct/notifiarr.sh +++ b/ct/notifiarr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/golift.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP" apt-get update &>/dev/null diff --git a/ct/ntfy.sh b/ct/ntfy.sh index 9cde97edd..d9031f594 100644 --- a/ct/ntfy.sh +++ b/ct/ntfy.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/nzbget.sh b/ct/nzbget.sh index da5c7d63a..e8b83bd5d 100644 --- a/ct/nzbget.sh +++ b/ct/nzbget.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /lib/systemd/system/nzbget.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/octoprint.sh b/ct/octoprint.sh index f132db14d..bf5b634b8 100644 --- a/ct/octoprint.sh +++ b/ct/octoprint.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/octoprint ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping OctoPrint" systemctl stop octoprint diff --git a/ct/ollama.sh b/ct/ollama.sh index b8ad9a600..1d5bf4719 100644 --- a/ct/ollama.sh +++ b/ct/ollama.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/ollama ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" apt-get update &>/dev/null diff --git a/ct/omada.sh b/ct/omada.sh index 0ff1a8107..ceaa9c8a2 100644 --- a/ct/omada.sh +++ b/ct/omada.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/tplink ]]; then msg_error "No ${APP} Installation Found!"; exit; fi latest_url=$(curl -fsSL "https://www.tp-link.com/en/support/download/omada-software-controller/" | grep -o 'https://.*x64.deb' | head -n1) latest_version=$(basename "${latest_url}") diff --git a/ct/ombi.sh b/ct/ombi.sh index 70eeccdcb..d378a11c1 100644 --- a/ct/ombi.sh +++ b/ct/ombi.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/ombi ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -sL https://api.github.com/repos/Ombi-app/Ombi/releases/latest | grep '"tag_name":' | cut -d'"' -f4) if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then diff --git a/ct/omv.sh b/ct/omv.sh index e5ae9d14b..48e0ca0cf 100644 --- a/ct/omv.sh +++ b/ct/omv.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/openmediavault.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/openhab.sh b/ct/openhab.sh index 7c9f32571..f4c0fdd8e 100644 --- a/ct/openhab.sh +++ b/ct/openhab.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/openhab.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/openobserve.sh b/ct/openobserve.sh index d4f50109a..3ec7c50ef 100644 --- a/ct/openobserve.sh +++ b/ct/openobserve.sh @@ -56,6 +56,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/openobserve/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP" systemctl stop openobserve diff --git a/ct/openwebui.sh b/ct/openwebui.sh index ecbcb9b62..a8c28ac98 100644 --- a/ct/openwebui.sh +++ b/ct/openwebui.sh @@ -56,6 +56,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/open-webui ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} (Patience)" cd /opt/open-webui diff --git a/ct/overseerr.sh b/ct/overseerr.sh index edd1c8e16..e489be028 100644 --- a/ct/overseerr.sh +++ b/ct/overseerr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/overseerr ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP" systemctl stop overseerr diff --git a/ct/owncast.sh b/ct/owncast.sh index 34306eb16..95c0a8918 100644 --- a/ct/owncast.sh +++ b/ct/owncast.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/owncast ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/pairdrop.sh b/ct/pairdrop.sh index 28cf8a967..baf4783cb 100644 --- a/ct/pairdrop.sh +++ b/ct/pairdrop.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/pairdrop ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP" systemctl stop pairdrop diff --git a/ct/paperless-ngx.sh b/ct/paperless-ngx.sh index d7a1947c0..3aac6ab11 100644 --- a/ct/paperless-ngx.sh +++ b/ct/paperless-ngx.sh @@ -65,6 +65,8 @@ function update_script() { "2" "Paperless-ngx Credentials" OFF \ 3>&1 1>&2 2>&3) header_info + check_container_storage + check_container_resources if [ "$UPD" == "1" ]; then if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then if [[ "$(gs --version 2>/dev/null)" != "10.04.0" ]]; then diff --git a/ct/pbs.sh b/ct/pbs.sh index a1f08711a..11d6be38f 100644 --- a/ct/pbs.sh +++ b/ct/pbs.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/peanut.sh b/ct/peanut.sh index 0ec83da96..13fd94dee 100644 --- a/ct/peanut.sh +++ b/ct/peanut.sh @@ -55,8 +55,9 @@ function default_settings() { function update_script() { header_info + check_container_storage + check_container_resources if [[ ! -f /etc/systemd/system/peanut.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi - whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 RELEASE=$(curl -sL https://api.github.com/repos/Brandawg93/PeaNUT/releases/latest | grep '"tag_name":' | cut -d'"' -f4) if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then msg_info "Updating $APP to ${RELEASE}" @@ -83,10 +84,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 1024 -pct set $CTID -cores 1 -msg_ok "Set Container to Normal Resources" msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:3000${CL} \n" diff --git a/ct/petio.sh b/ct/petio.sh index a05b4e5d7..4e8d9541b 100644 --- a/ct/petio.sh +++ b/ct/petio.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/Petio ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP" systemctl stop petio.service diff --git a/ct/photoprism.sh b/ct/photoprism.sh index aeec30c25..864de0398 100644 --- a/ct/photoprism.sh +++ b/ct/photoprism.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info + check_container_storage + check_container_resources if [[ ! -d /opt/photoprism ]]; then msg_error "No ${APP} Installation Found!" exit diff --git a/ct/pialert.sh b/ct/pialert.sh index 6be4b07f7..ee0de9376 100644 --- a/ct/pialert.sh +++ b/ct/pialert.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/pialert ]]; then msg_error "No ${APP} Installation Found!"; exit; fi bash -c "$(wget -qLO - https://github.com/leiweibau/Pi.Alert/raw/main/install/pialert_update.sh)" -s --lxc msg_ok "Updated $APP" diff --git a/ct/pihole.sh b/ct/pihole.sh index 4bf2be6e4..f26c120ec 100644 --- a/ct/pihole.sh +++ b/ct/pihole.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /etc/pihole ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" set +e diff --git a/ct/pingvin.sh b/ct/pingvin.sh index 29fec06f3..e2a2bd3df 100644 --- a/ct/pingvin.sh +++ b/ct/pingvin.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/pingvin-share ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping Pingvin Share" systemctl stop pm2-root.service diff --git a/ct/plex.sh b/ct/plex.sh index ba79c08de..539778597 100644 --- a/ct/plex.sh +++ b/ct/plex.sh @@ -53,13 +53,14 @@ function default_settings() { } function update_script() { +header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/plexmediaserver.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --radiolist --cancel-button Exit-Script "Spacebar = Select \nplexupdate info >> https://github.com/mrworf/plexupdate" 10 59 2 \ "1" "Update LXC" ON \ "2" "Install plexupdate" OFF \ 3>&1 1>&2 2>&3) - -header_info if [ "$UPD" == "1" ]; then msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/podman-homeassistant.sh b/ct/podman-homeassistant.sh index 34d42f157..4498a6a63 100644 --- a/ct/podman-homeassistant.sh +++ b/ct/podman-homeassistant.sh @@ -57,6 +57,9 @@ function default_settings() { } function update_script() { +header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/homeassistant.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "UPDATE" --radiolist --cancel-button Exit-Script "Spacebar = Select" 11 58 4 \ "1" "Update system and containers" ON \ @@ -64,7 +67,7 @@ function update_script() { "3" "Install FileBrowser" OFF \ "4" "Remove ALL Unused Images" OFF \ 3>&1 1>&2 2>&3) -header_info + if [ "$UPD" == "1" ]; then msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/podman.sh b/ct/podman.sh index 5e8d542d4..7c29ca8fa 100644 --- a/ct/podman.sh +++ b/ct/podman.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/containers/registries.conf ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/postgresql.sh b/ct/postgresql.sh index da2940a71..a20c5e7b2 100644 --- a/ct/postgresql.sh +++ b/ct/postgresql.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/pgdg.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/prometheus.sh b/ct/prometheus.sh index af62545b0..b24470353 100644 --- a/ct/prometheus.sh +++ b/ct/prometheus.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/prometheus.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/prometheus/prometheus/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then diff --git a/ct/prowlarr.sh b/ct/prowlarr.sh index 798cf319a..38bced48e 100644 --- a/ct/prowlarr.sh +++ b/ct/prowlarr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var/lib/prowlarr/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/qbittorrent.sh b/ct/qbittorrent.sh index 3474e606f..7544f7848 100644 --- a/ct/qbittorrent.sh +++ b/ct/qbittorrent.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/qbittorrent-nox.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/rabbitmq.sh b/ct/rabbitmq.sh index c422f9028..0ff43448a 100644 --- a/ct/rabbitmq.sh +++ b/ct/rabbitmq.sh @@ -56,11 +56,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /etc/rabbitmq ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi msg_info "Stopping ${APP} Service" systemctl stop rabbitmq-server msg_ok "Stopped ${APP} Service" diff --git a/ct/radarr.sh b/ct/radarr.sh index 62ada6efe..a7218ef86 100644 --- a/ct/radarr.sh +++ b/ct/radarr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var/lib/radarr/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/readarr.sh b/ct/readarr.sh index 1c0cc4891..10c6280ba 100644 --- a/ct/readarr.sh +++ b/ct/readarr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var/lib/readarr/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/readeck.sh b/ct/readeck.sh index 1fb4e15a3..29233e166 100644 --- a/ct/readeck.sh +++ b/ct/readeck.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/readeck ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" LATEST=$(curl -s https://codeberg.org/readeck/readeck/releases/ | grep -oP '(?<=Version )\d+\.\d+\.\d+' | head -1) diff --git a/ct/recyclarr.sh b/ct/recyclarr.sh index b17c10eda..ea2bb1861 100644 --- a/ct/recyclarr.sh +++ b/ct/recyclarr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /root/.config/recyclarr/recyclarr.yml ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" diff --git a/ct/redis.sh b/ct/redis.sh index 66d470155..32d0ee55e 100644 --- a/ct/redis.sh +++ b/ct/redis.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /lib/systemd/system/redis-server.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/rtsptoweb.sh b/ct/rtsptoweb.sh index 8bcf415e9..a2db35831 100644 --- a/ct/rtsptoweb.sh +++ b/ct/rtsptoweb.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/runtipi.sh b/ct/runtipi.sh index 44d2e8d20..2af52c24e 100644 --- a/ct/runtipi.sh +++ b/ct/runtipi.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/runtipi ]]; then msg_error "No ${APP} Installation Found!"; exit; fi cd /opt/runtipi && ./runtipi-cli update latest exit diff --git a/ct/sabnzbd.sh b/ct/sabnzbd.sh index 65d7f7e85..10b1b5490 100644 --- a/ct/sabnzbd.sh +++ b/ct/sabnzbd.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/sabnzbd ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/sabnzbd/sabnzbd/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then diff --git a/ct/scrypted.sh b/ct/scrypted.sh index 0fc2547d1..44d001ed6 100644 --- a/ct/scrypted.sh +++ b/ct/scrypted.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/scrypted.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/sftpgo.sh b/ct/sftpgo.sh index fc4061f66..203ea956d 100644 --- a/ct/sftpgo.sh +++ b/ct/sftpgo.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/shinobi.sh b/ct/shinobi.sh index 681823986..609cae770 100644 --- a/ct/shinobi.sh +++ b/ct/shinobi.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/Shinobi ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating Shinobi LXC" cd /opt/Shinobi diff --git a/ct/smokeping.sh b/ct/smokeping.sh index fa3ae66d4..cb1e98a23 100644 --- a/ct/smokeping.sh +++ b/ct/smokeping.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if ! command -v smokeping &> /dev/null; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" diff --git a/ct/sonarr.sh b/ct/sonarr.sh index d47faf3cb..b1cb114e5 100644 --- a/ct/sonarr.sh +++ b/ct/sonarr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/Sonarr ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP v4" systemctl stop sonarr.service diff --git a/ct/spoolman.sh b/ct/spoolman.sh index b4e4be5b7..d1ba9ed9c 100644 --- a/ct/spoolman.sh +++ b/ct/spoolman.sh @@ -55,11 +55,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/spoolman ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi RELEASE=$(wget -q https://github.com/Donkie/Spoolman/releases/latest -O - | grep "title>Release" | cut -d " " -f 4) if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then diff --git a/ct/stirling-pdf.sh b/ct/stirling-pdf.sh index 06239f24a..67eaee05f 100644 --- a/ct/stirling-pdf.sh +++ b/ct/stirling-pdf.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/Stirling-PDF ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" systemctl stop stirlingpdf diff --git a/ct/syncthing.sh b/ct/syncthing.sh index 65cc49859..d771e03f4 100644 --- a/ct/syncthing.sh +++ b/ct/syncthing.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/sources.list.d/syncthing.list ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/tandoor.sh b/ct/tandoor.sh index 2409971a6..693c8a9f6 100644 --- a/ct/tandoor.sh +++ b/ct/tandoor.sh @@ -55,8 +55,9 @@ function default_settings() { function update_script() { header_info + check_container_storage + check_container_resources if [[ ! -d /opt/tandoor ]]; then msg_error "No ${APP} Installation Found!"; exit; fi - whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 if cd /opt/tandoor && git pull | grep -q 'Already up to date'; then msg_ok "There is currently no update available." else @@ -80,11 +81,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 2048 -pct set $CTID -cores 2 -msg_ok "Set Container to Normal Resources" - msg_ok "Completed Successfully!\n" echo -e "${APP} Setup should be reachable by going to the following URL. ${BL}http://${IP}:8002${CL} \n" diff --git a/ct/tasmoadmin.sh b/ct/tasmoadmin.sh index bc949cdb4..a99c012ac 100644 --- a/ct/tasmoadmin.sh +++ b/ct/tasmoadmin.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/tautulli.sh b/ct/tautulli.sh index 1e5924da5..59e1831b8 100644 --- a/ct/tautulli.sh +++ b/ct/tautulli.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/Tautulli/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/tdarr.sh b/ct/tdarr.sh index 96ed6878b..c6d5fddd7 100644 --- a/ct/tdarr.sh +++ b/ct/tdarr.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/tdarr ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/technitiumdns.sh b/ct/technitiumdns.sh index b7d6984ef..73ff29bae 100644 --- a/ct/technitiumdns.sh +++ b/ct/technitiumdns.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /etc/dns ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" diff --git a/ct/threadfin.sh b/ct/threadfin.sh index 9ffbf8681..9995ea157 100644 --- a/ct/threadfin.sh +++ b/ct/threadfin.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/threadfin ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP" systemctl stop threadfin.service diff --git a/ct/tianji.sh b/ct/tianji.sh index 54edc90d3..e80a52480 100644 --- a/ct/tianji.sh +++ b/ct/tianji.sh @@ -54,14 +54,11 @@ function default_settings() { } function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/tianji ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi RELEASE=$(curl -s https://api.github.com/repos/msgbyte/tianji/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then - whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 msg_info "Stopping ${APP} Service" systemctl stop tianji msg_ok "Stopped ${APP} Service" @@ -105,11 +102,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 1024 -pct set $CTID -cores 1 -msg_ok "Set Container to Normal Resources" - msg_ok "Completed Successfully!\n" echo -e "${APP} Setup should be reachable by going to the following URL. ${BL}http://${IP}:12345${CL} \n" diff --git a/ct/traccar.sh b/ct/traccar.sh index 497334aeb..c0f7a5daf 100644 --- a/ct/traccar.sh +++ b/ct/traccar.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/traccar ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_error "There is currently no update path available." exit diff --git a/ct/traefik.sh b/ct/traefik.sh index 54a6c6fc6..6cfbfe20e 100644 --- a/ct/traefik.sh +++ b/ct/traefik.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/traefik.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/traefik/traefik/releases | grep -oP '"tag_name":\s*"v\K[\d.]+?(?=")' | sort -V | tail -n 1) msg_info "Updating $APP LXC" diff --git a/ct/transmission.sh b/ct/transmission.sh index 3fa4f0cbc..deaf8f741 100644 --- a/ct/transmission.sh +++ b/ct/transmission.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/transmission-daemon/settings.json ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/trilium.sh b/ct/trilium.sh index efc430aa4..f6a7d60ba 100644 --- a/ct/trilium.sh +++ b/ct/trilium.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/trilium ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/TriliumNext/Notes/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }') diff --git a/ct/ubuntu.sh b/ct/ubuntu.sh index 3df8920e6..fe2851d96 100644 --- a/ct/ubuntu.sh +++ b/ct/ubuntu.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" apt-get update &>/dev/null diff --git a/ct/umami.sh b/ct/umami.sh index f746f7e3d..0c37d001d 100644 --- a/ct/umami.sh +++ b/ct/umami.sh @@ -54,12 +54,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/umami ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi msg_info "Stopping ${APP}" systemctl stop umami @@ -84,10 +81,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 1024 -pct set $CTID -cores 1 -msg_ok "Set Container to Normal Resources" msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:3000${CL} \n" diff --git a/ct/umbrel.sh b/ct/umbrel.sh index 6e5ccf07a..fa1bfb99d 100644 --- a/ct/umbrel.sh +++ b/ct/umbrel.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources msg_info "Updating ${APP} LXC" apt-get update &>/dev/null apt-get -y upgrade &>/dev/null diff --git a/ct/unifi.sh b/ct/unifi.sh index 4c092cfba..5be90bdab 100644 --- a/ct/unifi.sh +++ b/ct/unifi.sh @@ -58,6 +58,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /usr/lib/unifi ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP}" apt-get update --allow-releaseinfo-change diff --git a/ct/unmanic.sh b/ct/unmanic.sh index 8cb594582..a24633afc 100644 --- a/ct/unmanic.sh +++ b/ct/unmanic.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/systemd/system/unmanic.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" pip3 install -U unmanic &>/dev/null diff --git a/ct/uptimekuma.sh b/ct/uptimekuma.sh index ca736b48d..53667c18f 100644 --- a/ct/uptimekuma.sh +++ b/ct/uptimekuma.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/uptime-kuma ]]; then msg_error "No ${APP} Installation Found!"; exit; fi if [[ "$(node -v | cut -d 'v' -f 2)" == "18."* ]]; then if ! command -v npm >/dev/null 2>&1; then diff --git a/ct/vaultwarden.sh b/ct/vaultwarden.sh index be1b9f768..7b66d2331 100644 --- a/ct/vaultwarden.sh +++ b/ct/vaultwarden.sh @@ -75,7 +75,6 @@ function update_script() { check_container_storage check_container_resources if [ "$UPD" == "1" ]; then - whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "SET RESOURCES" "Please set the resources in your ${APP} LXC to ${var_cpu}vCPU and ${var_ram}RAM for the build process before continuing" 10 75 msg_info "Stopping Vaultwarden" systemctl stop vaultwarden.service msg_ok "Stopped Vaultwarden" @@ -144,10 +143,6 @@ start build_container description -msg_info "Setting Container to Normal Resources" -pct set $CTID -memory 512 -pct set $CTID -cores 1 -msg_ok "Set Container to Normal Resources" msg_ok "Completed Successfully!\n" echo -e "${APP} should be reachable by going to the following URL. ${BL}http://${IP}:8000${CL} \n" diff --git a/ct/vikunja.sh b/ct/vikunja.sh index b143816f4..ed643699f 100644 --- a/ct/vikunja.sh +++ b/ct/vikunja.sh @@ -56,11 +56,9 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/vikunja ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi RELEASE=$(curl -s https://dl.vikunja.io/vikunja/ | grep -oP 'href="/vikunja/\K[0-9]+\.[0-9]+\.[0-9]+' | sort -V | tail -n 1) if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then msg_info "Stopping ${APP}" diff --git a/ct/wastebin.sh b/ct/wastebin.sh index c13d0d9f4..639e0caca 100644 --- a/ct/wastebin.sh +++ b/ct/wastebin.sh @@ -57,6 +57,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/wastebin ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/matze/wastebin/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then diff --git a/ct/watchyourlan.sh b/ct/watchyourlan.sh index 290ed72b5..182a106fe 100644 --- a/ct/watchyourlan.sh +++ b/ct/watchyourlan.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /lib/systemd/system/watchyourlan.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP" systemctl stop watchyourlan.service diff --git a/ct/wavelog.sh b/ct/wavelog.sh index d8d5afab9..60ed3754a 100644 --- a/ct/wavelog.sh +++ b/ct/wavelog.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/wavelog ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/wavelog/wavelog/releases/latest | grep "tag_name" | cut -d '"' -f 4) if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then diff --git a/ct/whisparr.sh b/ct/whisparr.sh index 583135747..31c5813a5 100644 --- a/ct/whisparr.sh +++ b/ct/whisparr.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /var/lib/whisparr ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/whoogle.sh b/ct/whoogle.sh index 9db69dee5..a43750503 100644 --- a/ct/whoogle.sh +++ b/ct/whoogle.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /usr/local/bin/whoogle-search ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating ${APP} LXC" pip3 install whoogle-search --upgrade &>/dev/null diff --git a/ct/wikijs.sh b/ct/wikijs.sh index 0fc854edc..bc9ddf907 100644 --- a/ct/wikijs.sh +++ b/ct/wikijs.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/wikijs ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Stopping ${APP}" systemctl stop wikijs diff --git a/ct/wireguard.sh b/ct/wireguard.sh index 34adb6bd9..d4388ad33 100644 --- a/ct/wireguard.sh +++ b/ct/wireguard.sh @@ -53,6 +53,9 @@ function default_settings() { } function update_script() { +header_info +check_container_storage +check_container_resources if [[ ! -d /etc/wireguard ]]; then msg_error "No ${APP} Installation Found!"; exit; fi apt-get update apt-get -y upgrade diff --git a/ct/yunohost.sh b/ct/yunohost.sh index a8efa1d33..ce44c28ea 100644 --- a/ct/yunohost.sh +++ b/ct/yunohost.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/apt/trusted.gpg.d/php.gpg ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/zabbix.sh b/ct/zabbix.sh index aa5eaef6b..1a6300111 100644 --- a/ct/zabbix.sh +++ b/ct/zabbix.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -f /etc/zabbix/zabbix_server.conf ]]; then msg_error "No ${APP} Installation Found!"; exit; fi msg_info "Updating $APP LXC" apt-get update &>/dev/null diff --git a/ct/zigbee2mqtt.sh b/ct/zigbee2mqtt.sh index e78b5efe2..70f1e7587 100644 --- a/ct/zigbee2mqtt.sh +++ b/ct/zigbee2mqtt.sh @@ -55,6 +55,8 @@ function default_settings() { function update_script() { header_info + check_container_storage + check_container_resources if [[ ! -d /opt/zigbee2mqtt ]]; then msg_error "No ${APP} Installation Found!" exit diff --git a/ct/zipline.sh b/ct/zipline.sh index 28da39d93..8887bb998 100644 --- a/ct/zipline.sh +++ b/ct/zipline.sh @@ -54,11 +54,9 @@ function default_settings() { } function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/zipline ]]; then msg_error "No ${APP} Installation Found!"; exit; fi -if (( $(df /boot | awk 'NR==2{gsub("%","",$5); print $5}') > 80 )); then - read -r -p "Warning: Storage is dangerously low, continue anyway? <y/N> " prompt - [[ ${prompt,,} =~ ^(y|yes)$ ]] || exit -fi RELEASE=$(curl -s https://api.github.com/repos/diced/zipline/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then msg_info "Stopping ${APP}" diff --git a/ct/zoraxy.sh b/ct/zoraxy.sh index 463e98dc2..5fadef42e 100644 --- a/ct/zoraxy.sh +++ b/ct/zoraxy.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info +check_container_storage +check_container_resources if [[ ! -d /opt/zoraxy/ ]]; then msg_error "No ${APP} Installation Found!"; exit; fi RELEASE=$(curl -s https://api.github.com/repos/tobychui/zoraxy/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }') if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then diff --git a/ct/zwave-js-ui.sh b/ct/zwave-js-ui.sh index 51c130926..8bb0624e9 100644 --- a/ct/zwave-js-ui.sh +++ b/ct/zwave-js-ui.sh @@ -54,6 +54,8 @@ function default_settings() { function update_script() { header_info + check_container_storage + check_container_resources if [[ ! -d /opt/zwave-js-ui ]]; then msg_error "No ${APP} Installation Found!" exit