From e11254b185f506aca40cb05360e113cca6620064 Mon Sep 17 00:00:00 2001 From: vhsdream Date: Sat, 25 Oct 2025 12:53:46 -0400 Subject: [PATCH] PatchMon: use NodeJS 24; remove some msgs --- ct/patchmon.sh | 2 ++ install/patchmon-install.sh | 12 ++++-------- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/ct/patchmon.sh b/ct/patchmon.sh index 284400bc..8671ddcf 100644 --- a/ct/patchmon.sh +++ b/ct/patchmon.sh @@ -30,6 +30,8 @@ function update_script() { exit fi + NODE_VERSION="24" setup_nodejs + if check_for_gh_release "PatchMon" "PatchMon/PatchMon"; then msg_info "Stopping $APP" diff --git a/install/patchmon-install.sh b/install/patchmon-install.sh index 25029775..209b03e1 100644 --- a/install/patchmon-install.sh +++ b/install/patchmon-install.sh @@ -21,7 +21,7 @@ $STD apt install -y \ redis-server msg_ok "Installed Dependencies" -NODE_VERSION="22" setup_nodejs +NODE_VERSION="24" setup_nodejs PG_VERSION="17" setup_postgresql msg_info "Creating PostgreSQL Database" @@ -52,9 +52,7 @@ $STD npm install --no-audit --no-fund --no-save --ignore-scripts cd /opt/patchmon/frontend $STD npm install --include=dev --no-audit --no-fund --no-save --ignore-scripts $STD npm run build -msg_ok "Configured PatchMon" -msg_info "Creating env files" JWT_SECRET="$(openssl rand -base64 64 | tr -d "=+/" | cut -c1-50)" LOCAL_IP="$(hostname -I | awk '{print $1}')" cat </opt/patchmon/backend/.env @@ -111,13 +109,11 @@ VITE_API_URL=http://$LOCAL_IP/api/v1 VITE_APP_NAME=PatchMon VITE_APP_VERSION=1.3.0 EOF -msg_ok "Created env files" -msg_info "Running database migrations" cd /opt/patchmon/backend $STD npx prisma migrate deploy $STD npx prisma generate -msg_ok "Database migrations complete" +msg_ok "Configured PatchMon" msg_info "Configuring Nginx" cat </etc/nginx/sites-available/patchmon.conf @@ -231,7 +227,7 @@ EOF systemctl enable -q --now patchmon-server msg_ok "Created and started service" -msg_info "Populating server settings in DB" +msg_info "Updating settings" cat </opt/patchmon/backend/update-settings.js const { PrismaClient } = require('@prisma/client'); const { v4: uuidv4 } = require('uuid'); @@ -281,7 +277,7 @@ EOF cd /opt/patchmon/backend $STD node update-settings.js -msg_ok "Server settings populated successfully" +msg_ok "Settings updated successfully" motd_ssh customize