From 6df5531fb4967297518280a5805eaf48b5ba8a80 Mon Sep 17 00:00:00 2001 From: "CanbiZ (MickLesk)" <47820557+MickLesk@users.noreply.github.com> Date: Mon, 2 Feb 2026 13:57:08 +0100 Subject: [PATCH] Adjust Checkmate build/env and service handling Pass VITE_APP_API_BASE_URL, UPTIME_APP_API_BASE_URL and VITE_APP_LOG_LEVEL into the Checkmate client build so the frontend targets /api/v1 and uses a warn log level (applied in both update and install scripts). Rename PORT to SERVER_HOST/SERVER_PORT in the installer and set SERVER_HOST=0.0.0.0 so the server binds correctly. Use quiet systemctl enable (-q --now) for checkmate services and reload nginx instead of re-enabling it. Move vaultwarden-install.sh into install/deferred/. --- ct/checkmate.sh | 2 +- install/checkmate-install.sh | 12 ++++++------ install/{ => deferred}/vaultwarden-install.sh | 0 3 files changed, 7 insertions(+), 7 deletions(-) rename install/{ => deferred}/vaultwarden-install.sh (100%) diff --git a/ct/checkmate.sh b/ct/checkmate.sh index b6d0a1fec..6cf30fbb4 100644 --- a/ct/checkmate.sh +++ b/ct/checkmate.sh @@ -52,7 +52,7 @@ function update_script() { msg_info "Updating Checkmate Client" cd /opt/checkmate/client $STD npm install - $STD npm run build + VITE_APP_API_BASE_URL="/api/v1" UPTIME_APP_API_BASE_URL="/api/v1" VITE_APP_LOG_LEVEL="warn" $STD npm run build msg_ok "Updated Checkmate Client" msg_info "Restoring Data" diff --git a/install/checkmate-install.sh b/install/checkmate-install.sh index 24e3c6eee..ad245ca8d 100644 --- a/install/checkmate-install.sh +++ b/install/checkmate-install.sh @@ -33,7 +33,8 @@ DB_CONNECTION_STRING="mongodb://localhost:27017/checkmate_db" TOKEN_TTL="99d" ORIGIN="${LOCAL_IP}" LOG_LEVEL="info" -PORT=52345 +SERVER_HOST=0.0.0.0 +SERVER_PORT=52345 EOF cat </opt/checkmate/client/.env.local @@ -52,7 +53,7 @@ msg_ok "Installed Checkmate Server" msg_info "Installing Checkmate Client" cd /opt/checkmate/client $STD npm install -$STD npm run build +VITE_APP_API_BASE_URL="/api/v1" UPTIME_APP_API_BASE_URL="/api/v1" VITE_APP_LOG_LEVEL="warn" $STD npm run build msg_ok "Installed Checkmate Client" msg_info "Creating Services" @@ -90,9 +91,8 @@ RestartSec=5 [Install] WantedBy=multi-user.target EOF -systemctl daemon-reload -$STD systemctl enable --now checkmate-server -$STD systemctl enable --now checkmate-client +$STD systemctl enable -q --now checkmate-server +$STD systemctl enable -q --now checkmate-client msg_ok "Created Services" msg_info "Configuring Nginx Reverse Proxy" @@ -128,7 +128,7 @@ EOF ln -sf /etc/nginx/sites-available/checkmate /etc/nginx/sites-enabled/checkmate rm -f /etc/nginx/sites-enabled/default $STD nginx -t -$STD systemctl enable --now nginx +$STD systemctl reload nginx msg_ok "Configured Nginx Reverse Proxy" motd_ssh diff --git a/install/vaultwarden-install.sh b/install/deferred/vaultwarden-install.sh similarity index 100% rename from install/vaultwarden-install.sh rename to install/deferred/vaultwarden-install.sh