Compare commits

...

10 Commits

Author SHA1 Message Date
community-scripts-pr-app[bot]
03a44a8c9c Update CHANGELOG.md (#14230)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-05-03 20:38:54 +00:00
CanbiZ (MickLesk)
08b1398e7b Refactor: PeaNUT for v6 (#14224) 2026-05-03 22:38:30 +02:00
community-scripts-pr-app[bot]
dca3fb40a8 Update CHANGELOG.md (#14229)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-05-03 20:36:20 +00:00
Michael Oultram
37eafa199d core: fix validate_bridge function (#14206) 2026-05-03 22:35:53 +02:00
community-scripts-pr-app[bot]
6729fa2a87 Update CHANGELOG.md (#14228)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-05-03 20:30:48 +00:00
CanbiZ (MickLesk)
cd6bd154d9 fix(pangolin): pin version, drop manual SQL, use upstream migrator (#14223) 2026-05-03 22:30:21 +02:00
community-scripts-pr-app[bot]
92f2079a79 Update CHANGELOG.md (#14227)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-05-03 20:30:03 +00:00
CanbiZ (MickLesk)
683231127c fix(pbs/pve): guard sed against missing /etc/apt/sources.list (#14222) 2026-05-03 22:29:40 +02:00
community-scripts-pr-app[bot]
7733ac2806 Update CHANGELOG.md (#14226)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-05-03 20:29:32 +00:00
Tom Frenzel
1d83725249 Hortusfox: fix update issues (#14214) 2026-05-03 22:29:06 +02:00
10 changed files with 105 additions and 49 deletions

View File

@@ -460,6 +460,29 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
## 2026-05-03
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- Hortusfox: fix update issues [@tomfrenzel](https://github.com/tomfrenzel) ([#14214](https://github.com/community-scripts/ProxmoxVE/pull/14214))
- #### ✨ New Features
- Refactor: PeaNUT for v6 [@MickLesk](https://github.com/MickLesk) ([#14224](https://github.com/community-scripts/ProxmoxVE/pull/14224))
- pangolin: pin version, drop manual SQL, use upstream migrator [@MickLesk](https://github.com/MickLesk) ([#14223](https://github.com/community-scripts/ProxmoxVE/pull/14223))
### 💾 Core
- #### 🐞 Bug Fixes
- core: fix validate_bridge function [@MichaelOultram](https://github.com/MichaelOultram) ([#14206](https://github.com/community-scripts/ProxmoxVE/pull/14206))
### 🧰 Tools
- #### 🐞 Bug Fixes
- pve/pbs scripts: guard sed against missing /etc/apt/sources.list [@MickLesk](https://github.com/MickLesk) ([#14222](https://github.com/community-scripts/ProxmoxVE/pull/14222))
## 2026-05-02
### 🆕 New Scripts

View File

@@ -38,13 +38,15 @@ function update_script() {
mv /opt/hortusfox/ /opt/hortusfox-backup
msg_ok "Backed up current HortusFox installation"
fetch_and_deploy_gh_release "hortusfox" "danielbrendel/hortusfox-web" "tarball"
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "hortusfox" "danielbrendel/hortusfox-web" "tarball"
msg_info "Updating HortusFox"
cd /opt/hortusfox
mv /opt/hortusfox-backup/.env /opt/hortusfox/.env
cp /opt/hortusfox-backup/.env /opt/hortusfox/.env
cp -a /opt/hortusfox-backup/public/img/. /opt/hortusfox/public/img/
export COMPOSER_ALLOW_SUPERUSER=1
$STD composer install --no-dev --optimize-autoloader
$STD php asatru migrate --no-interaction
$STD php asatru migrate:upgrade
$STD php asatru plants:attributes
$STD php asatru calendar:classes
chown -R www-data:www-data /opt/hortusfox

View File

@@ -6,6 +6,7 @@ source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxV
# Source: https://pangolin.net/ | Github: https://github.com/fosrl/pangolin
APP="Pangolin"
PANGOLIN_VERSION="${PANGOLIN_VERSION:-1.18.2}"
var_tags="${var_tags:-proxy}"
var_cpu="${var_cpu:-2}"
var_ram="${var_ram:-4096}"
@@ -33,7 +34,7 @@ function update_script() {
NODE_VERSION="24" setup_nodejs
if check_for_gh_release "pangolin" "fosrl/pangolin"; then
if check_for_gh_release "pangolin" "fosrl/pangolin" "$PANGOLIN_VERSION" "Pinned to a tested release because Pangolin's schema changes have repeatedly broken unattended updates. To try a newer version at your own risk, run: 'export PANGOLIN_VERSION=<tag>' and re-run update. If it breaks, please open an issue at https://github.com/community-scripts/ProxmoxVE/issues with the error log."; then
msg_info "Stopping Service"
systemctl stop pangolin
systemctl stop gerbil
@@ -41,9 +42,13 @@ function update_script() {
msg_info "Creating backup"
tar -czf /opt/pangolin_config_backup.tar.gz -C /opt/pangolin config
if [[ -f /opt/pangolin/config/db/db.sqlite ]]; then
cp -a /opt/pangolin/config/db/db.sqlite \
"/opt/pangolin/config/db/db.sqlite.pre-${PANGOLIN_VERSION}-$(date +%Y%m%d-%H%M%S).bak"
fi
msg_ok "Created backup"
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "pangolin" "fosrl/pangolin" "tarball"
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "pangolin" "fosrl/pangolin" "tarball" "$PANGOLIN_VERSION"
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "gerbil" "fosrl/gerbil" "singlefile" "latest" "/usr/bin" "gerbil_linux_amd64"
msg_info "Updating Pangolin"
@@ -67,36 +72,16 @@ function update_script() {
rm -f /opt/pangolin_config_backup.tar.gz
msg_ok "Restored config"
msg_info "Running database migrations"
cd /opt/pangolin
# Pre-apply potentially destructive schema changes safely so drizzle-kit
# does not recreate tables (which would delete all rows).
local DB="/opt/pangolin/config/db/db.sqlite"
if [[ -f "$DB" ]]; then
sqlite3 "$DB" "ALTER TABLE 'orgs' ADD COLUMN 'settingsLogRetentionDaysConnection' integer DEFAULT 0 NOT NULL;" 2>/dev/null || true
sqlite3 "$DB" "ALTER TABLE 'clientSitesAssociationsCache' ADD COLUMN 'isJitMode' integer DEFAULT 0 NOT NULL;" 2>/dev/null || true
sqlite3 "$DB" "ALTER TABLE 'userOrgs' ADD COLUMN 'pamUsername' text;" 2>/dev/null || true
# Create new role-mapping tables and migrate data before drizzle-kit
# drops the roleId columns from userOrgs and userInvites.
sqlite3 "$DB" "CREATE TABLE IF NOT EXISTS 'userOrgRoles' (
'userId' text NOT NULL REFERENCES 'user'('id') ON DELETE CASCADE,
'orgId' text NOT NULL REFERENCES 'orgs'('orgId') ON DELETE CASCADE,
'roleId' integer NOT NULL REFERENCES 'roles'('roleId') ON DELETE CASCADE,
UNIQUE('userId', 'orgId', 'roleId')
);" 2>/dev/null || true
sqlite3 "$DB" "INSERT OR IGNORE INTO 'userOrgRoles' (userId, orgId, roleId) SELECT userId, orgId, roleId FROM 'userOrgs' WHERE roleId IS NOT NULL;" 2>/dev/null || true
sqlite3 "$DB" "CREATE TABLE IF NOT EXISTS 'userInviteRoles' (
'inviteId' text NOT NULL REFERENCES 'userInvites'('inviteId') ON DELETE CASCADE,
'roleId' integer NOT NULL REFERENCES 'roles'('roleId') ON DELETE CASCADE,
PRIMARY KEY('inviteId', 'roleId')
);" 2>/dev/null || true
sqlite3 "$DB" "INSERT OR IGNORE INTO 'userInviteRoles' (inviteId, roleId) SELECT inviteId, roleId FROM 'userInvites' WHERE roleId IS NOT NULL;" 2>/dev/null || true
if ! grep -q '^ExecStartPre=/usr/bin/node dist/migrations.mjs' /etc/systemd/system/pangolin.service 2>/dev/null; then
msg_info "Adding migration step to pangolin.service"
sed -i '/^ExecStart=\/usr\/bin\/node --enable-source-maps dist\/server.mjs/i ExecStartPre=/usr/bin/node dist/migrations.mjs' /etc/systemd/system/pangolin.service
systemctl daemon-reload
msg_ok "Updated pangolin.service"
fi
ENVIRONMENT=prod $STD npx drizzle-kit push --force --config drizzle.sqlite.config.ts
msg_info "Running database migrations"
cd /opt/pangolin
ENVIRONMENT=prod $STD node dist/migrations.mjs
msg_ok "Ran database migrations"
msg_info "Updating Badger plugin version"

View File

@@ -45,6 +45,33 @@ function update_script() {
msg_ok "Fixed entrypoint"
fi
if [[ ! -f /etc/peanut/peanut.env ]]; then
msg_info "Migrating service to EnvironmentFile"
mkdir -p /etc/peanut
cat <<EOF >/etc/peanut/peanut.env
NODE_ENV=production
#WEB_HOST=0.0.0.0
#WEB_PORT=8080
#NUT_HOST=localhost
#NUT_PORT=3493
# Disable auth entirely:
#AUTH_DISABLED=true
# Bootstrap initial account on first start (ignored afterwards):
#WEB_USERNAME=admin
#WEB_PASSWORD=changeme
EOF
chmod 600 /etc/peanut/peanut.env
sed -i '/^Environment=/d' /etc/systemd/system/peanut.service
if ! grep -q '^EnvironmentFile=/etc/peanut/peanut.env' /etc/systemd/system/peanut.service; then
sed -i '/^Type=simple/a EnvironmentFile=/etc/peanut/peanut.env' /etc/systemd/system/peanut.service
fi
systemctl daemon-reload
msg_ok "Migrated to /etc/peanut/peanut.env"
fi
msg_info "Updating PeaNUT"
cd /opt/peanut
$STD pnpm i

View File

@@ -22,7 +22,8 @@ $STD apt install -y \
msg_ok "Installed Dependencies"
NODE_VERSION="24" setup_nodejs
fetch_and_deploy_gh_release "pangolin" "fosrl/pangolin" "tarball"
PANGOLIN_VERSION="${PANGOLIN_VERSION:-1.18.2}"
fetch_and_deploy_gh_release "pangolin" "fosrl/pangolin" "tarball" "$PANGOLIN_VERSION"
fetch_and_deploy_gh_release "gerbil" "fosrl/gerbil" "singlefile" "latest" "/usr/bin" "gerbil_linux_amd64"
fetch_and_deploy_gh_release "traefik" "traefik/traefik" "prebuild" "latest" "/usr/bin" "traefik_v*_linux_amd64.tar.gz"
@@ -204,6 +205,7 @@ User=root
Environment=NODE_ENV=production
Environment=ENVIRONMENT=prod
WorkingDirectory=/opt/pangolin
ExecStartPre=/usr/bin/node dist/migrations.mjs
ExecStart=/usr/bin/node --enable-source-maps dist/server.mjs
Restart=always
RestartSec=10

View File

@@ -29,13 +29,28 @@ cp -r .next/static .next/standalone/.next/
mkdir -p /opt/peanut/.next/standalone/config
mkdir -p /etc/peanut/
ln -sf .next/standalone/server.js server.js
cat <<EOF >/etc/peanut/settings.yml
WEB_HOST: 0.0.0.0
WEB_PORT: 8080
NUT_HOST: 0.0.0.0
NUT_PORT: 3493
if [[ ! -f /etc/peanut/settings.yml ]]; then
cat <<EOF >/etc/peanut/settings.yml
NUT_SERVERS: []
EOF
fi
ln -sf /etc/peanut/settings.yml /opt/peanut/.next/standalone/config/settings.yml
cat <<EOF >/etc/peanut/peanut.env
NODE_ENV=production
#WEB_HOST=0.0.0.0
#WEB_PORT=8080
#NUT_HOST=localhost
#NUT_PORT=3493
# Disable auth entirely:
#AUTH_DISABLED=true
# Bootstrap initial account on first start (ignored afterwards):
#WEB_USERNAME=admin
#WEB_PASSWORD=changeme
EOF
chmod 600 /etc/peanut/peanut.env
msg_ok "Setup Peanut"
msg_info "Creating Service"
@@ -48,11 +63,7 @@ SyslogIdentifier=peanut
Restart=always
RestartSec=5
Type=simple
Environment="NODE_ENV=production"
#Environment="NUT_HOST=localhost"
#Environment="NUT_PORT=3493"
#Environment="WEB_HOST=0.0.0.0"
#Environment="WEB_PORT=8080"
EnvironmentFile=/etc/peanut/peanut.env
WorkingDirectory=/opt/peanut
ExecStart=node /opt/peanut/entrypoint.mjs
TimeoutStopSec=30

View File

@@ -513,7 +513,7 @@ validate_bridge() {
[[ -z "$bridge" ]] && return 1
# Check if bridge interface exists
if ! ip link show "$bridge" &>/dev/null; then
if ! ip link show dev "$bridge" &>/dev/null; then
return 1
fi

View File

@@ -57,7 +57,9 @@ start_routines() {
yes)
msg_info "Switching to Debian 13 (Trixie) Sources"
rm -f /etc/apt/sources.list.d/*.list
sed -i '/proxmox/d;/bookworm/d' /etc/apt/sources.list || true
if [ -f /etc/apt/sources.list ]; then
sed -i '/proxmox/d;/bookworm/d' /etc/apt/sources.list
fi
cat >/etc/apt/sources.list.d/debian.sources <<EOF
Types: deb
URIs: http://deb.debian.org/debian

View File

@@ -188,7 +188,9 @@ start_routines_4() {
yes)
msg_info "Correcting Debian Sources (deb822)"
rm -f /etc/apt/sources.list.d/*.list
sed -i '/proxmox/d;/bookworm/d' /etc/apt/sources.list || true
if [ -f /etc/apt/sources.list ]; then
sed -i '/proxmox/d;/bookworm/d' /etc/apt/sources.list
fi
cat >/etc/apt/sources.list.d/debian.sources <<EOF
Types: deb
URIs: http://deb.debian.org/debian/

View File

@@ -251,8 +251,10 @@ start_routines_9() {
msg_info "Correcting Proxmox VE Sources (deb822)"
# remove all existing .list files
rm -f /etc/apt/sources.list.d/*.list
# remove bookworm and proxmox entries from sources.list
sed -i '/proxmox/d;/bookworm/d' /etc/apt/sources.list || true
# remove bookworm and proxmox entries from sources.list (if it exists)
if [ -f /etc/apt/sources.list ]; then
sed -i '/proxmox/d;/bookworm/d' /etc/apt/sources.list
fi
# Create new deb822 sources
cat >/etc/apt/sources.list.d/debian.sources <<EOF
Types: deb