Compare commits

..

4 Commits

Author SHA1 Message Date
MickLesk
8e04c1eae7 style(tools): unify all function declarations to name() { style
Remove 'function' keyword from 30 declarations to match the project convention
used in core.func, error_handler.func, and all other .func files (POSIX-compatible name() { syntax)
2026-05-24 21:26:03 +02:00
MickLesk
d06b7f2a28 fix(tools): consolidate OS detection, add error hints, sort setup functions
- Replace all 13 manual /etc/os-release reads with get_os_info() across
  prepare_repository_setup, setup_hwaccel, setup_java, setup_mysql,
  setup_php, setup_postgresql, setup_clickhouse, install_packages_with_retry
- Add actionable Hint messages to 16 download/network failure paths:
  adminer, composer, ffmpeg (x2), go, ghostscript, imagemagick, rbenv,
  ruby-build, meilisearch-config, uv, yq, rust, apt-lock timeout,
  mongodb GPG, php keyring
- Replace 6 silent 'apt install || true' with msg_warn for optional packages:
  3x postgresql modules, ruby build deps, ssl-cert, docker-compose
- Sort all 'function setup_*' declarations into alphabetical order:
  clickhouse moved to after adminer, docker moved to after composer,
  meilisearch moved to after mariadb_db
2026-05-24 21:22:29 +02:00
MickLesk
85aa701e31 fix(tools): improve error diagnostics and actionable hints across install functions
- Add _diagnose_deb_failure() helper: extracts package metadata from failed .deb installs,
  detects PostgreSQL version conflicts (e.g., postgresql-16-vchord with PG17 active),
  lists unmet dependencies, and provides specific actionable hints
- Replace all 4 generic 'Both apt and dpkg installation failed' messages in
  fetch_and_deploy_{codeberg,gh,gl}_release and fetch_and_deploy_from_url with
  _diagnose_deb_failure() for targeted diagnostics
- install_packages_with_retry: on failure, check which packages are missing from
  configured repos and name them with a distribution-specific hint
- upgrade_packages_with_retry: add hint about held-back packages / apt-cache policy
- setup_postgresql: when PGDG repo is unavailable for trixie/forky/sid, show which
  distro PG version will be installed and warn that extension packages must match
- setup_deb822_repo: include GPG key URL and firewall hint in download failure message
- curl_download: add network/DNS hint to the failure message
- error_handler: add log-pattern analysis block after Node.js OOM detection that
  scans the last 60 log lines for 5 common failure patterns and emits msg_warn hints:
    * APT/dpkg dependency conflict (generic + PostgreSQL version mismatch)
    * APT GPG/signature verification failure (sqv, KEYEXPIRED, NO_PUBKEY)
    * Network/DNS failure (Could not resolve, Failed to fetch)
    * APT lock held by another process
    * Disk space exhaustion (ENOSPC)
2026-05-24 21:03:14 +02:00
MickLesk
947d032f96 fix(tools): replace raw GitHub API curl calls with get_latest_github_release 2026-05-23 23:12:31 +02:00
10 changed files with 1081 additions and 991 deletions

135
.github/changelogs/2026/05.md generated vendored
View File

@@ -1,138 +1,3 @@
## 2026-05-23
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- IronClaw: Extra configuration during install to ensure Web Gateway can run [@SystemIdleProcess](https://github.com/SystemIdleProcess) ([#14635](https://github.com/community-scripts/ProxmoxVE/pull/14635))
- Tunarr: fix path to backup during update [@SystemIdleProcess](https://github.com/SystemIdleProcess) ([#14655](https://github.com/community-scripts/ProxmoxVE/pull/14655))
- #### ✨ New Features
- wealthfolio: add: prebuild [@CrazyWolf13](https://github.com/CrazyWolf13) ([#14658](https://github.com/community-scripts/ProxmoxVE/pull/14658))
### 🧰 Tools
- #### ✨ New Features
- kernel-clean: support range syntax in selection prompt [@djhojd](https://github.com/djhojd) ([#14656](https://github.com/community-scripts/ProxmoxVE/pull/14656))
## 2026-05-22
### 🆕 New Scripts
- bitfocus-companion ([#14603](https://github.com/community-scripts/ProxmoxVE/pull/14603))
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- fix(the-lounge): install Node.js 22 before deb package [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#14648](https://github.com/community-scripts/ProxmoxVE/pull/14648))
- Docmost: Fix duplicate STORAGE_DRIVER [@MickLesk](https://github.com/MickLesk) ([#14645](https://github.com/community-scripts/ProxmoxVE/pull/14645))
- Profilarr: pin Deno version to v2.7.5 [@MickLesk](https://github.com/MickLesk) ([#14632](https://github.com/community-scripts/ProxmoxVE/pull/14632))
- #### ✨ New Features
- add: karakeep cli wrapper [@CrazyWolf13](https://github.com/CrazyWolf13) ([#14618](https://github.com/community-scripts/ProxmoxVE/pull/14618))
- #### 💥 Breaking Changes
- OpenCloud: v7.0.0 changes [@vhsdream](https://github.com/vhsdream) ([#14650](https://github.com/community-scripts/ProxmoxVE/pull/14650))
- #### 🔧 Refactor
- workflows: update workflows, templates to support arm64. [@asylumexp](https://github.com/asylumexp) ([#14653](https://github.com/community-scripts/ProxmoxVE/pull/14653))
- SoulSync: setup Node v22 and build WebUI [@MickLesk](https://github.com/MickLesk) ([#14639](https://github.com/community-scripts/ProxmoxVE/pull/14639))
- Refactor: Dispatcharr [@MickLesk](https://github.com/MickLesk) ([#14313](https://github.com/community-scripts/ProxmoxVE/pull/14313))
### 💾 Core
- #### 🐞 Bug Fixes
- fix: make LXC banner OS detection dynamic via /etc/os-release [@atahan99](https://github.com/atahan99) ([#14269](https://github.com/community-scripts/ProxmoxVE/pull/14269))
- #### 🔧 Refactor
- core: suppress MOTD for non-interactive shells [@MickLesk](https://github.com/MickLesk) ([#14638](https://github.com/community-scripts/ProxmoxVE/pull/14638))
## 2026-05-21
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- snowshare: use mv instead of cp for uploads backup to prevent disk fill [@TuroYT](https://github.com/TuroYT) ([#14558](https://github.com/community-scripts/ProxmoxVE/pull/14558))
- Technitium DNS: download release before stopping the service on update [@w-gitops](https://github.com/w-gitops) ([#14616](https://github.com/community-scripts/ProxmoxVE/pull/14616))
- #### ✨ New Features
- Proxmox VE 9.2 support [@MickLesk](https://github.com/MickLesk) ([#14624](https://github.com/community-scripts/ProxmoxVE/pull/14624))
## 2026-05-20
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- Update mylar3 to point to new Repo [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#14606](https://github.com/community-scripts/ProxmoxVE/pull/14606))
- Ollama: Fix for latest version [@tremor021](https://github.com/tremor021) ([#14596](https://github.com/community-scripts/ProxmoxVE/pull/14596))
- #### ✨ New Features
- Profilarr v2: Update and Refactor whole Script [@MickLesk](https://github.com/MickLesk) ([#14584](https://github.com/community-scripts/ProxmoxVE/pull/14584))
## 2026-05-19
### 🆕 New Scripts
- LobeHub ([#14441](https://github.com/community-scripts/ProxmoxVE/pull/14441))
### 🚀 Updated Scripts
- Update nodejs Versions [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#14582](https://github.com/community-scripts/ProxmoxVE/pull/14582))
- #### 🐞 Bug Fixes
- ESPConnect: Fix paths to SSL certificates [@tremor021](https://github.com/tremor021) ([#14591](https://github.com/community-scripts/ProxmoxVE/pull/14591))
- ReactiveResume: set correct WorkingDirectory for systemd service [@MickLesk](https://github.com/MickLesk) ([#14579](https://github.com/community-scripts/ProxmoxVE/pull/14579))
- Sparkyfitness: add missing nginx template variable substitutions [@MickLesk](https://github.com/MickLesk) ([#14578](https://github.com/community-scripts/ProxmoxVE/pull/14578))
- Wanderer: include dev dependencies during build [@MickLesk](https://github.com/MickLesk) ([#14577](https://github.com/community-scripts/ProxmoxVE/pull/14577))
- Whisparr: switch from nightly to stable GitHub release [@MickLesk](https://github.com/MickLesk) ([#14581](https://github.com/community-scripts/ProxmoxVE/pull/14581))
- #### 🔧 Refactor
- Refactor: SonarQube [@tremor021](https://github.com/tremor021) ([#14594](https://github.com/community-scripts/ProxmoxVE/pull/14594))
## 2026-05-18
### 🆕 New Scripts
- ESPconnect ([#14444](https://github.com/community-scripts/ProxmoxVE/pull/14444))
- degoog ([#14533](https://github.com/community-scripts/ProxmoxVE/pull/14533))
- Webtrees ([#14532](https://github.com/community-scripts/ProxmoxVE/pull/14532))
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- Bichon: Support v1 migration [@tomfrenzel](https://github.com/tomfrenzel) ([#14524](https://github.com/community-scripts/ProxmoxVE/pull/14524))
- #### ✨ New Features
- Pangolin: bump to 1.18.4, fix missing statusHistory migration [@MickLesk](https://github.com/MickLesk) ([#14566](https://github.com/community-scripts/ProxmoxVE/pull/14566))
## 2026-05-17
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- dashy: fix yarn-missing on update and back up full user-data [@lissy93](https://github.com/lissy93) ([#14548](https://github.com/community-scripts/ProxmoxVE/pull/14548))
- #### ✨ New Features
- tools.func: replace max-time with speed-limit stall detection in curl_download [@MickLesk](https://github.com/MickLesk) ([#14545](https://github.com/community-scripts/ProxmoxVE/pull/14545))
## 2026-05-16 ## 2026-05-16
### 🚀 Updated Scripts ### 🚀 Updated Scripts

View File

@@ -53,9 +53,6 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
@@ -69,7 +66,7 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
<details> <details>
<summary><h4>May (23 entries)</h4></summary> <summary><h4>May (16 entries)</h4></summary>
[View May 2026 Changelog](.github/changelogs/2026/05.md) [View May 2026 Changelog](.github/changelogs/2026/05.md)
@@ -467,33 +464,6 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
</details> </details>
## 2026-05-25
### 💾 Core
- #### ✨ New Features
- tools.func: replace raw GitHub API curl calls with get_latest_github_release [@MickLesk](https://github.com/MickLesk) ([#14690](https://github.com/community-scripts/ProxmoxVE/pull/14690))
### 🧰 Tools
- #### 🔧 Refactor
- Kernel-Clean: detect meta-packages and fix silent removal failures [@MickLesk](https://github.com/MickLesk) ([#14674](https://github.com/community-scripts/ProxmoxVE/pull/14674))
## 2026-05-24
### 🚀 Updated Scripts
- #### ✨ New Features
- RomM: add installation steps for Nginx mod_zip module [@MickLesk](https://github.com/MickLesk) ([#14678](https://github.com/community-scripts/ProxmoxVE/pull/14678))
- ISponsorblockTV: detect CPU capabilities to select compatible binary [@MickLesk](https://github.com/MickLesk) ([#14677](https://github.com/community-scripts/ProxmoxVE/pull/14677))
- #### 🔧 Refactor
- Refactor: MQTT [@tremor021](https://github.com/tremor021) ([#14673](https://github.com/community-scripts/ProxmoxVE/pull/14673))
## 2026-05-23 ## 2026-05-23
### 🚀 Updated Scripts ### 🚀 Updated Scripts
@@ -1064,4 +1034,161 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
- #### 🔧 Refactor - #### 🔧 Refactor
- Refactor: Ghostfolio [@MickLesk](https://github.com/MickLesk) ([#13990](https://github.com/community-scripts/ProxmoxVE/pull/13990)) - Refactor: Ghostfolio [@MickLesk](https://github.com/MickLesk) ([#13990](https://github.com/community-scripts/ProxmoxVE/pull/13990))
## 2026-04-23
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- mealie: start.sh missing after failed update [@MickLesk](https://github.com/MickLesk) ([#13958](https://github.com/community-scripts/ProxmoxVE/pull/13958))
- twingate-connector: perform real apt upgrade during update flow [@MickLesk](https://github.com/MickLesk) ([#13959](https://github.com/community-scripts/ProxmoxVE/pull/13959))
- #### ✨ New Features
- core: auto-size NODE_OPTIONS heap [@MickLesk](https://github.com/MickLesk) ([#13960](https://github.com/community-scripts/ProxmoxVE/pull/13960))
- #### 🔧 Refactor
- Update scripts to match standard [@tremor021](https://github.com/tremor021) ([#13956](https://github.com/community-scripts/ProxmoxVE/pull/13956))
### 💾 Core
- #### 🐞 Bug Fixes
- tools.func: upgrade Node.js minor/patch on same major version [@MickLesk](https://github.com/MickLesk) ([#13957](https://github.com/community-scripts/ProxmoxVE/pull/13957))
- core: hotfix - prefer silent mode on PHS env conflict [@MickLesk](https://github.com/MickLesk) ([#13951](https://github.com/community-scripts/ProxmoxVE/pull/13951))
- #### 🔧 Refactor
- core: improve system update information / lxc stack upgrade [@MickLesk](https://github.com/MickLesk) ([#13970](https://github.com/community-scripts/ProxmoxVE/pull/13970))
## 2026-04-22
### 🆕 New Scripts
- Dashy ([#13817](https://github.com/community-scripts/ProxmoxVE/pull/13817))
- Mini-QR ([#13902](https://github.com/community-scripts/ProxmoxVE/pull/13902))
- ownfoil ([#13904](https://github.com/community-scripts/ProxmoxVE/pull/13904))
- ERPNext ([#13921](https://github.com/community-scripts/ProxmoxVE/pull/13921))
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- add --clear to uv venv in update_script() to prevent interactive prompt [@MickLesk](https://github.com/MickLesk) ([#13926](https://github.com/community-scripts/ProxmoxVE/pull/13926))
### 💾 Core
- #### ✨ New Features
- core: Add PHS_VERBOSE env var to skip verbose mode prompts [@gormanity](https://github.com/gormanity) ([#13797](https://github.com/community-scripts/ProxmoxVE/pull/13797))
## 2026-04-21
### 🆕 New Scripts
- gogs ([#13896](https://github.com/community-scripts/ProxmoxVE/pull/13896))
- anchor ([#13895](https://github.com/community-scripts/ProxmoxVE/pull/13895))
- minthcm ([#13903](https://github.com/community-scripts/ProxmoxVE/pull/13903))
- foldergram ([#13900](https://github.com/community-scripts/ProxmoxVE/pull/13900))
### 🚀 Updated Scripts
- OpenCloud: Pin version to 6.1.0 [@vhsdream](https://github.com/vhsdream) ([#13890](https://github.com/community-scripts/ProxmoxVE/pull/13890))
- #### 🐞 Bug Fixes
- Domain-Locker: Update dependencies [@tremor021](https://github.com/tremor021) ([#13901](https://github.com/community-scripts/ProxmoxVE/pull/13901))
- homelable: fix install failure by correcting password-reset chmod target [@Copilot](https://github.com/Copilot) ([#13894](https://github.com/community-scripts/ProxmoxVE/pull/13894))
- #### ✨ New Features
- FileFlows: Update dependencies [@tremor021](https://github.com/tremor021) ([#13917](https://github.com/community-scripts/ProxmoxVE/pull/13917))
## 2026-04-20
### 🆕 New Scripts
- WhoDB ([#13880](https://github.com/community-scripts/ProxmoxVE/pull/13880))
### 🚀 Updated Scripts
- pangolin: create migration tables before data transfer to prevent role loss [@MickLesk](https://github.com/MickLesk) ([#13874](https://github.com/community-scripts/ProxmoxVE/pull/13874))
- #### 🐞 Bug Fixes
- Pangolin: pre-apply schema migrations to prevent data loss [@MickLesk](https://github.com/MickLesk) ([#13861](https://github.com/community-scripts/ProxmoxVE/pull/13861))
- ActualBudget: change migration messages to warnings [@MickLesk](https://github.com/MickLesk) ([#13860](https://github.com/community-scripts/ProxmoxVE/pull/13860))
- slskd: migrate config keys for 0.25.0 breaking change [@MickLesk](https://github.com/MickLesk) ([#13862](https://github.com/community-scripts/ProxmoxVE/pull/13862))
- #### ✨ New Features
- Wanderer: add pocketbase CLI wrapper with env [@MickLesk](https://github.com/MickLesk) ([#13863](https://github.com/community-scripts/ProxmoxVE/pull/13863))
- feat(homelable): add password reset utility script [@davidsoncabista](https://github.com/davidsoncabista) ([#13798](https://github.com/community-scripts/ProxmoxVE/pull/13798))
- #### 🔧 Refactor
- Several Scripts: Bump NodeJS to align Node.js versions with upstream for 5 scripts [@MickLesk](https://github.com/MickLesk) ([#13875](https://github.com/community-scripts/ProxmoxVE/pull/13875))
- Refactor: PMG Post Install [@MickLesk](https://github.com/MickLesk) ([#13693](https://github.com/community-scripts/ProxmoxVE/pull/13693))
### 💾 Core
- #### 🐞 Bug Fixes
- core: detect Perl breakage after LXC stack upgrade and improve storage validation [@MickLesk](https://github.com/MickLesk) ([#13879](https://github.com/community-scripts/ProxmoxVE/pull/13879))
## 2026-04-19
### 🆕 New Scripts
- nametag ([#13849](https://github.com/community-scripts/ProxmoxVE/pull/13849))
## 2026-04-18
### 🆕 New Scripts
- Dagu ([#13830](https://github.com/community-scripts/ProxmoxVE/pull/13830))
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- BabyBuddy: set DJANGO_SETTINGS_MODULE before migrate in update [@MickLesk](https://github.com/MickLesk) ([#13836](https://github.com/community-scripts/ProxmoxVE/pull/13836))
- litellm: add prisma generate and use venv binary directly [@MickLesk](https://github.com/MickLesk) ([#13835](https://github.com/community-scripts/ProxmoxVE/pull/13835))
- yamtrack: add missing nginx.conf sed edits to update script [@MickLesk](https://github.com/MickLesk) ([#13834](https://github.com/community-scripts/ProxmoxVE/pull/13834))
### 🧰 Tools
- #### 🐞 Bug Fixes
- SparkyFitness Garmin Microservice: fix update function [@tomfrenzel](https://github.com/tomfrenzel) ([#13824](https://github.com/community-scripts/ProxmoxVE/pull/13824))
- #### 🔧 Refactor
- Clean-Orphan-LVM: check all cluster nodes for VM/CT configs [@MickLesk](https://github.com/MickLesk) ([#13837](https://github.com/community-scripts/ProxmoxVE/pull/13837))
## 2026-04-17
### 🆕 New Scripts
- step-ca ([#13775](https://github.com/community-scripts/ProxmoxVE/pull/13775))
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- core: pin IGC version to compute-runtime compatible tag (Intel GPU) [@MickLesk](https://github.com/MickLesk) ([#13814](https://github.com/community-scripts/ProxmoxVE/pull/13814))
- Fix for bambuddy community script update [@abbasegbeyemi](https://github.com/abbasegbeyemi) ([#13816](https://github.com/community-scripts/ProxmoxVE/pull/13816))
- Umami: Fix update procedure [@tremor021](https://github.com/tremor021) ([#13807](https://github.com/community-scripts/ProxmoxVE/pull/13807))
### 💾 Core
- #### 🐞 Bug Fixes
- core: sanitize mount_fs input — strip spaces and trailing commas [@MickLesk](https://github.com/MickLesk) ([#13806](https://github.com/community-scripts/ProxmoxVE/pull/13806))
- #### 🔧 Refactor
- core: fix some pct create issues (telemetry) + cleanup [@MickLesk](https://github.com/MickLesk) ([#13810](https://github.com/community-scripts/ProxmoxVE/pull/13810))

View File

@@ -36,11 +36,7 @@ function update_script() {
systemctl stop isponsorblocktv systemctl stop isponsorblocktv
msg_ok "Stopped Service" msg_ok "Stopped Service"
ISBTV_BINARY="iSponsorBlockTV-x86_64-linux-v1" CLEAN_INSTALL=1 fetch_and_deploy_gh_release "isponsorblocktv" "dmunozv04/iSponsorBlockTV" "singlefile" "latest" "/opt/isponsorblocktv" "iSponsorBlockTV-x86_64-linux"
if grep -q ' avx ' /proc/cpuinfo 2>/dev/null && grep -q ' avx2 ' /proc/cpuinfo 2>/dev/null && grep -q ' movbe ' /proc/cpuinfo 2>/dev/null; then
ISBTV_BINARY="iSponsorBlockTV-x86_64-linux"
fi
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "isponsorblocktv" "dmunozv04/iSponsorBlockTV" "singlefile" "latest" "/opt/isponsorblocktv" "${ISBTV_BINARY}"
msg_info "Starting Service" msg_info "Starting Service"
systemctl start isponsorblocktv systemctl start isponsorblocktv

View File

@@ -21,28 +21,18 @@ color
catch_errors catch_errors
function update_script() { function update_script() {
header_info header_info
check_container_storage check_container_storage
check_container_resources check_container_resources
if [[ ! -f /etc/mosquitto/conf.d/default.conf ]]; then
if [[ ! -f /etc/mosquitto/conf.d/default.conf ]]; then msg_error "No ${APP} Installation Found!"
msg_error "No ${APP} Installation Found!" exit
fi
msg_info "Updating ${APP} LXC"
$STD apt update
$STD apt -y upgrade
msg_ok "Updated successfully!"
exit exit
fi
if [[ ! -f /etc/apt/sources.list.d/mqtt.sources ]]; then
setup_deb822_repo \
"mqtt" \
"https://repo.mosquitto.org/debian/mosquitto-repo.gpg" \
"https://repo.mosquitto.org/debian" \
"trixie"
fi
msg_info "Updating MQTT"
$STD apt update
$STD apt upgrade -y
msg_ok "Updated successfully!"
exit
} }
start start

View File

@@ -13,12 +13,12 @@ setting_up_container
network_check network_check
update_os update_os
ISBTV_BINARY="iSponsorBlockTV-x86_64-linux-v1" if ! grep -q ' avx ' /proc/cpuinfo 2>/dev/null; then
if grep -q ' avx ' /proc/cpuinfo 2>/dev/null && grep -q ' avx2 ' /proc/cpuinfo 2>/dev/null && grep -q ' movbe ' /proc/cpuinfo 2>/dev/null; then msg_error "CPU does not support AVX instructions (required by iSponsorBlockTV/PyApp)"
ISBTV_BINARY="iSponsorBlockTV-x86_64-linux" exit 106
fi fi
fetch_and_deploy_gh_release "isponsorblocktv" "dmunozv04/iSponsorBlockTV" "singlefile" "latest" "/opt/isponsorblocktv" "${ISBTV_BINARY}" fetch_and_deploy_gh_release "isponsorblocktv" "dmunozv04/iSponsorBlockTV" "singlefile" "latest" "/opt/isponsorblocktv" "iSponsorBlockTV-x86_64-linux"
msg_info "Setting up iSponsorBlockTV" msg_info "Setting up iSponsorBlockTV"
install -d /var/lib/isponsorblocktv install -d /var/lib/isponsorblocktv

View File

@@ -13,26 +13,18 @@ setting_up_container
network_check network_check
update_os update_os
setup_deb822_repo \
"mqtt" \
"https://repo.mosquitto.org/debian/mosquitto-repo.gpg" \
"https://repo.mosquitto.org/debian" \
"trixie"
msg_info "Installing Mosquitto MQTT Broker" msg_info "Installing Mosquitto MQTT Broker"
$STD apt install -y \ source /etc/os-release
mosquitto \ $STD apt update
mosquitto-clients $STD apt -y install mosquitto mosquitto-clients
msg_ok "Installed Mosquitto MQTT Broker"
msg_info "Configuring Mosquitto MQTT Broker"
cat <<EOF >/etc/mosquitto/conf.d/default.conf cat <<EOF >/etc/mosquitto/conf.d/default.conf
allow_anonymous false allow_anonymous false
persistence true persistence true
password_file /etc/mosquitto/passwd password_file /etc/mosquitto/passwd
listener 1883 listener 1883
EOF EOF
msg_ok "Configured Mosquitto MQTT Broker" msg_ok "Installed Mosquitto MQTT Broker"
motd_ssh motd_ssh
customize customize

View File

@@ -41,16 +41,6 @@ $STD apt install -y \
nginx nginx
msg_ok "Installed Dependencies" msg_ok "Installed Dependencies"
msg_info "Installing Nginx mod_zip module"
setup_deb822_repo \
"getpagespeed-extras" \
"https://extras.getpagespeed.com/deb-archive-keyring.gpg" \
"https://extras.getpagespeed.com/debian" \
"$(get_os_info codename)" \
"main"
$STD apt-get install -y nginx nginx-module-zip
msg_ok "Installed Nginx mod_zip module"
PYTHON_VERSION="3.13" setup_uv PYTHON_VERSION="3.13" setup_uv
NODE_VERSION="24" setup_nodejs NODE_VERSION="24" setup_nodejs
setup_mariadb setup_mariadb

View File

@@ -358,6 +358,55 @@ error_handler() {
fi fi
fi fi
# ── Log-pattern analysis: detect common failure causes and emit actionable hints ──
if [[ -n "$active_log" && -s "$active_log" ]]; then
local _log_tail
_log_tail=$(tail -n 60 "$active_log" 2>/dev/null || true)
# 1. APT/dpkg dependency conflict
if echo "$_log_tail" | grep -qE "Depends:|depends on.*but.*not installed|broken packages|unmet dep|dependency problems"; then
# Check for PostgreSQL-specific version mismatch (most actionable)
local _pg_conflict
_pg_conflict=$(echo "$_log_tail" | grep -oE 'postgresql-[0-9]+ but.*installed' | head -1 || true)
if [[ -n "$_pg_conflict" ]]; then
if declare -f msg_warn >/dev/null 2>&1; then
msg_warn "PostgreSQL version conflict: ${_pg_conflict}"
msg_warn "Hint: A package requires a specific PostgreSQL version that is not installed. Your distribution may have installed a different PG version than expected."
fi
else
if declare -f msg_warn >/dev/null 2>&1; then
msg_warn "APT dependency conflict detected. A required package is not available or is the wrong version for this system."
msg_warn "Hint: Run 'apt-get install -f' inside the container or check that all required repositories are configured for your distribution."
fi
fi
# 2. APT/GPG signature verification failure
elif echo "$_log_tail" | grep -qE "sqv|KEYEXPIRED|NO_PUBKEY|key is not certified|signature verification failed|is not signed|Sub-process.*sqv"; then
if declare -f msg_warn >/dev/null 2>&1; then
msg_warn "APT repository signature error detected."
msg_warn "Hint: A repository GPG key may be missing, expired, or the keyring file is not yet present (/usr/share/postgresql-common/pgdg/apt.postgresql.org.asc etc.)."
msg_warn "Hint: Install the 'postgresql-common' package first, or re-add the repository with its correct signing key."
fi
# 3. Network / DNS failure during apt-get or curl
elif echo "$_log_tail" | grep -qE "Could not resolve|Failed to fetch|Unable to connect|Name or service not known|Network is unreachable|curl.*resolve"; then
if declare -f msg_warn >/dev/null 2>&1; then
msg_warn "Network or DNS failure detected."
msg_warn "Hint: Check the container's network connectivity, DNS settings, and whether any firewall or ad-blocker is intercepting traffic."
fi
# 4. APT lock held by another process
elif echo "$_log_tail" | grep -qE "Could not get lock|dpkg frontend lock|waiting for it to exit|E: Unable to lock"; then
if declare -f msg_warn >/dev/null 2>&1; then
msg_warn "APT or dpkg lock conflict detected."
msg_warn "Hint: Another package manager process may be running. Try 'rm /var/lib/dpkg/lock-frontend && dpkg --configure -a' inside the container."
fi
# 5. Disk space exhaustion
elif echo "$_log_tail" | grep -qE "No space left on device|disk quota exceeded|ENOSPC"; then
if declare -f msg_warn >/dev/null 2>&1; then
msg_warn "Disk space exhausted during installation."
msg_warn "Hint: Increase the container's disk size (pct resize <ctid> rootfs +2G) or clean up space first."
fi
fi
fi
# Detect context: Container (INSTALL_LOG set + inside container /root) vs Host # Detect context: Container (INSTALL_LOG set + inside container /root) vs Host
if [[ -n "${INSTALL_LOG:-}" && -f "${INSTALL_LOG:-}" && -d /root ]]; then if [[ -n "${INSTALL_LOG:-}" && -f "${INSTALL_LOG:-}" && -d /root ]]; then
# CONTAINER CONTEXT: Copy log and create flag file for host # CONTAINER CONTEXT: Copy log and create flag file for host

File diff suppressed because it is too large Load Diff

View File

@@ -28,14 +28,7 @@ declare -f init_tool_telemetry &>/dev/null && init_tool_telemetry "kernel-clean"
# Detect current kernel # Detect current kernel
current_kernel=$(uname -r) current_kernel=$(uname -r)
# Only list fully-installed (ii) versioned kernel packages; the pattern available_kernels=$(dpkg --list | grep 'kernel-.*-pve' | awk '{print $2}' | grep -v "$current_kernel" | sort -V)
# proxmox-kernel-X.Y.Z matches versioned kernels while excluding the
# two-segment meta-packages (proxmox-kernel-X.Y) and proxmox-kernel-helper.
available_kernels=$(dpkg --list |
awk '/^ii/ {print $2}' |
grep -E '^proxmox-kernel-[0-9]+\.[0-9]+\.[0-9]' |
grep -v "$current_kernel" |
sort -V)
header_info header_info
@@ -89,28 +82,10 @@ fi
# Remove kernels # Remove kernels
for kernel in "${kernels_to_remove[@]}"; do for kernel in "${kernels_to_remove[@]}"; do
echo -e "${YW}Removing $kernel...${CL}" echo -e "${YW}Removing $kernel...${CL}"
# Derive the major.minor meta-package name (e.g. proxmox-kernel-6.14) if apt-get purge -y "$kernel" >/dev/null 2>&1; then
# from a versioned name like proxmox-kernel-6.14.11-9-pve-signed. echo -e "${GN}Successfully removed: $kernel${CL}"
minor_version=$(echo "$kernel" | sed -E 's/^proxmox-kernel-([0-9]+\.[0-9]+)\..*/\1/')
meta="proxmox-kernel-${minor_version}"
pkgs_to_remove=("$kernel")
# Include the meta-package in the purge when it is installed and when
# no other versioned kernel of the same minor version will remain
# (the running kernel keeps it alive if it shares the same minor).
if dpkg -l "$meta" 2>/dev/null | grep -q '^ii'; then
remaining=$(dpkg --list |
awk '/^ii/ {print $2}' |
grep -E "^proxmox-kernel-${minor_version}\." |
grep -v "^${kernel}$" |
wc -l)
if [ "$remaining" -eq 0 ]; then
pkgs_to_remove+=("$meta")
fi
fi
if apt-get purge -y "${pkgs_to_remove[@]}" >/dev/null 2>&1; then
echo -e "${GN}Successfully removed: ${pkgs_to_remove[*]}${CL}"
else else
echo -e "${RD}Failed to remove: ${pkgs_to_remove[*]}. Check dependencies.${CL}" echo -e "${RD}Failed to remove: $kernel. Check dependencies.${CL}"
fi fi
done done