mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-11-05 13:04:37 +01:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 1bf0d43122 |
@@ -571,29 +571,6 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
|
||||
|
||||
</details>
|
||||
|
||||
## 2026-11-05
|
||||
|
||||
### 🚀 Updated Scripts
|
||||
|
||||
- #### 🐞 Bug Fixes
|
||||
|
||||
- OPNsense VM: wait for the FreeBSD login prompt instead of 180 seconds [@MickLesk](https://github.com/MickLesk) ([#18467](https://github.com/community-scripts/ProxmoxVE/pull/18467))
|
||||
|
||||
- #### 🔧 Refactor
|
||||
|
||||
- Tududi: run 2.0 on PostgreSQL, keep SQLite installs on 1.15.0 [@MickLesk](https://github.com/MickLesk) ([#18465](https://github.com/community-scripts/ProxmoxVE/pull/18465))
|
||||
|
||||
### 💾 Core
|
||||
|
||||
- fix: keep the existing install until the new archive has extracted [@rcourtman](https://github.com/rcourtman) ([core#201](https://github.com/community-scripts/core/pull/201))
|
||||
- fix: keep the install when a clone or an Alpine extract fails [@rcourtman](https://github.com/rcourtman) ([core#210](https://github.com/community-scripts/core/pull/210))
|
||||
|
||||
### 🧰 Tools
|
||||
|
||||
- #### 🐞 Bug Fixes
|
||||
|
||||
- Arcane: write both env names, stop shipping the unused .env [@MickLesk](https://github.com/MickLesk) ([#18466](https://github.com/community-scripts/ProxmoxVE/pull/18466))
|
||||
|
||||
## 2026-11-04
|
||||
|
||||
### 🚀 Updated Scripts
|
||||
|
||||
+2
-14
@@ -32,14 +32,7 @@ function update_script() {
|
||||
|
||||
NODE_VERSION="22" setup_nodejs
|
||||
|
||||
RELEASE=""
|
||||
if ! grep -qs '^DATABASE_URL=' /opt/tududi/backend/.env; then
|
||||
RELEASE="v1.15.0"
|
||||
msg_warn "Tududi 2.0 runs on PostgreSQL only, so this SQLite install stays on 1.15.0"
|
||||
msg_warn "To move to 2.0, export in Settings > Backups and import into a new Tududi LXC"
|
||||
fi
|
||||
|
||||
if check_for_gh_release "tududi" "chrisvel/tududi" "${RELEASE}" "2.0 needs PostgreSQL"; then
|
||||
if check_for_gh_release "tududi" "chrisvel/tududi"; then
|
||||
msg_info "Stopping Service"
|
||||
systemctl stop tududi
|
||||
msg_ok "Stopped Service"
|
||||
@@ -50,14 +43,9 @@ function update_script() {
|
||||
else
|
||||
cp /opt/tududi/.env /opt/tududi.env
|
||||
fi
|
||||
if ! grep -q '^TUDUDI_UPLOAD_PATH=' /opt/tududi.env; then
|
||||
mkdir -p /opt/tududi-uploads
|
||||
[[ -d /opt/tududi/backend/uploads ]] && cp -a /opt/tududi/backend/uploads/. /opt/tududi-uploads/
|
||||
echo "TUDUDI_UPLOAD_PATH=/opt/tududi-uploads" >>/opt/tududi.env
|
||||
fi
|
||||
msg_ok "Backed up env file"
|
||||
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "tududi" "chrisvel/tududi" "tarball" "${CHECK_UPDATE_RELEASE}" "/opt/tududi"
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "tududi" "chrisvel/tududi" "tarball" "latest" "/opt/tududi"
|
||||
|
||||
msg_info "Updating Tududi"
|
||||
cd /opt/tududi
|
||||
|
||||
@@ -13,9 +13,13 @@ setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y \
|
||||
sqlite3 \
|
||||
yq
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
NODE_VERSION="22" setup_nodejs
|
||||
PG_VERSION="17" setup_postgresql
|
||||
PG_DB_NAME="tududi" PG_DB_USER="tududi" setup_postgresql_db
|
||||
fetch_and_deploy_gh_release "tududi" "chrisvel/tududi" "tarball" "latest" "/opt/tududi"
|
||||
|
||||
msg_info "Configuring Tududi"
|
||||
@@ -26,22 +30,30 @@ $STD npm run frontend:build
|
||||
mv ./dist ./backend
|
||||
msg_ok "Configured Tududi"
|
||||
|
||||
msg_info "Creating env"
|
||||
mkdir -p /opt/tududi-uploads
|
||||
msg_info "Creating env and database"
|
||||
DB_LOCATION="/opt/tududi-db"
|
||||
UPLOAD_DIR="/opt/tududi-uploads"
|
||||
mkdir -p {"$DB_LOCATION","$UPLOAD_DIR"}
|
||||
SECRET="$(openssl rand -hex 64)"
|
||||
sed -e '/^NODE_ENV=/s/=.*$/=production/' \
|
||||
-e 's/^TUDUDI_USER/# TUDUDI_USER/g' \
|
||||
-e "s/^TUDUDI_SESSION_SECRET=.*/TUDUDI_SESSION_SECRET=${SECRET}/" \
|
||||
-e "s|^DATABASE_URL=.*|DATABASE_URL=postgres://tududi:${PG_DB_PASS}@localhost:5432/tududi|" \
|
||||
-e "/_SECRET=/s/=.*$/=${SECRET}/" \
|
||||
-e '/^# DB_FILE=/s/^# //' \
|
||||
-e "s|^DB_FILE=.*|DB_FILE=${DB_LOCATION}/production.sqlite3|" \
|
||||
-e "/^# TUDUDI_ALLOWED/s/^# //; \
|
||||
\|_ORIGINS=|s|=.*$|=<your tududi IP or FDQN>|" \
|
||||
-e "/^# TUDUDI_UPLOAD/s/^# //; \
|
||||
\|UPLOAD_PATH=|s|=.*$|=${UPLOAD_DIR}|" \
|
||||
/opt/tududi/backend/.env.example >/opt/tududi/backend/.env
|
||||
echo "TUDUDI_UPLOAD_PATH=/opt/tududi-uploads" >>/opt/tududi/backend/.env
|
||||
msg_ok "Created env"
|
||||
export DB_FILE="${DB_LOCATION}/production.sqlite3"
|
||||
$STD npm run db:init
|
||||
msg_ok "Created env and database"
|
||||
|
||||
msg_info "Creating service"
|
||||
cat <<EOF >/etc/systemd/system/tududi.service
|
||||
[Unit]
|
||||
Description=Tududi Service
|
||||
After=network.target postgresql.service
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
|
||||
+1
-20
@@ -442,26 +442,7 @@ msg_ok "Bridge interfaces have been successfully added."
|
||||
msg_ok "Created a OPNsense VM ${CL}${BL}(${HN})"
|
||||
msg_ok "Starting OPNsense VM (the bootstrap takes 10-30 minutes)"
|
||||
$STD qm start $VMID
|
||||
# The FreeBSD image prints its login prompt on the serial console too. Boot takes
|
||||
# under a minute with DHCP, each NIC without a DHCP server adds a 60s timeout.
|
||||
SERIAL_LOG="${TEMP_DIR}/serial-${VMID}.log"
|
||||
timeout 900 socat -u "UNIX-CONNECT:/var/run/qemu-server/${VMID}.serial0" - >"$SERIAL_LOG" 2>/dev/null &
|
||||
SERIAL_PID=$!
|
||||
boot_wait=0
|
||||
until grep -aq 'login:' "$SERIAL_LOG" 2>/dev/null || ! kill -0 "$SERIAL_PID" 2>/dev/null; do
|
||||
sleep 5
|
||||
boot_wait=$((boot_wait + 5))
|
||||
done
|
||||
kill "$SERIAL_PID" 2>/dev/null || true
|
||||
if grep -aq 'login:' "$SERIAL_LOG" 2>/dev/null; then
|
||||
msg_ok "FreeBSD booted after ${boot_wait}s"
|
||||
elif [ $boot_wait -lt 180 ]; then
|
||||
msg_warn "Could not read the serial console, waiting 3 minutes instead"
|
||||
sleep $((180 - boot_wait))
|
||||
else
|
||||
msg_warn "No login prompt on the serial console after $((boot_wait / 60)) minutes; continuing"
|
||||
fi
|
||||
sleep 3
|
||||
sleep 180
|
||||
send_line_to_vm "root"
|
||||
sleep 2
|
||||
send_line_to_vm ""
|
||||
|
||||
Reference in New Issue
Block a user