Compare commits

..

16 Commits

Author SHA1 Message Date
community-scripts-pr-app[bot] a5b839f91f Update CHANGELOG.md (#15781)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-07-14 12:16:30 +00:00
push-app-to-main[bot] d4d482746b Add grav (ct) (#15773)
Co-authored-by: push-app-to-main[bot] <203845782+push-app-to-main[bot]@users.noreply.github.com>
2026-07-14 14:16:10 +02:00
community-scripts-pr-app[bot] 2bffa47924 Update CHANGELOG.md (#15780)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-07-14 12:16:01 +00:00
push-app-to-main[bot] 108c9dcf43 Add yuvomi (ct) (#15772)
Co-authored-by: push-app-to-main[bot] <203845782+push-app-to-main[bot]@users.noreply.github.com>
2026-07-14 14:15:32 +02:00
community-scripts-pr-app[bot] 0f37abff3c Update CHANGELOG.md (#15779)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-07-14 12:14:44 +00:00
Michel Roegl-Brunner 670d972cc1 fix(wanderer): clean deploy and install plugins for v0.20.0 update (#15759)
Use CLEAN_INSTALL with create_backup/restore_backup so stale v0.19.x source files no longer break go build after the integrations migration. Also set up the plugins directory and install official WASM bundles.
2026-07-14 14:14:20 +02:00
community-scripts-pr-app[bot] 9f8bc4b03d Update CHANGELOG.md (#15778)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-07-14 12:08:38 +00:00
CanbiZ (MickLesk) 817ee347c7 Bump OpenCloud version to v7.2.2 (#15769)
* Bump OpenCloud release version to v7.2.2

* Update OpenCloud version to v7.2.2
2026-07-14 22:08:14 +10:00
community-scripts-pr-app[bot] bb4e35f988 Update CHANGELOG.md (#15777)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-07-14 12:02:17 +00:00
community-scripts-pr-app[bot] 254e720b4f Update CHANGELOG.md (#15776)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-07-14 12:01:44 +00:00
Michel Roegl-Brunner 9055f4b34e fix(lychee): preserve uploads and ownership during update (#15768)
The update script wiped public/uploads and did not re-apply www-data
ownership, causing HTTP 500 after successful updates. Align with upstream
upgrade steps and sibling Laravel scripts by backing up uploads/dist,
restarting PHP-FPM, running full artisan cache cycle, and adding verbose
diagnostics.

Fixes #15763
2026-07-14 22:01:40 +10:00
Michel Roegl-Brunner 3f5453b609 FileFlows: Handle update API 401, force update, and Node install (#15766)
* fix(fileflows): handle update API failures and fix Node install

Server updates no longer abort on 401 or unreachable API; users can force deploy when security is enabled or the app is down. Node installs now pass --server during systemd setup, and Node updates skip the server-only API.

* Update fileflows.sh
2026-07-14 22:01:16 +10:00
community-scripts-pr-app[bot] e812206116 Update CHANGELOG.md (#15775)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-07-14 12:00:40 +00:00
Michel Roegl-Brunner 7f430e15bb feat(silverbullet): add optional Runtime API install via Chromium (#15761)
Adds an install-time prompt to optionally enable Silverbullet's Runtime API by installing Chromium and configuring SB_CHROME_PATH / SB_CHROME_DATA_DIR.
2026-07-14 22:00:17 +10:00
community-scripts-pr-app[bot] 9c586b94ab Update CHANGELOG.md (#15774)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-07-14 11:58:44 +00:00
Michel Roegl-Brunner ab3c9be482 fix(birdnet-go): match new upstream release asset naming (#15758)
Upstream BirdNET-Go releases now suffix tarball names with the release date (e.g. birdnet-go-linux-amd64-20260713.tar.gz). Use a wildcard pattern so install and update can fetch the latest release without falling back to older nightlies.

Fixes #15753
2026-07-14 21:58:22 +10:00
14 changed files with 285 additions and 60 deletions
+14
View File
@@ -504,12 +504,26 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
## 2026-07-14
### 🆕 New Scripts
- Grav ([#15773](https://github.com/community-scripts/ProxmoxVE/pull/15773))
- Yuvomi ([#15772](https://github.com/community-scripts/ProxmoxVE/pull/15772))
### 🚀 Updated Scripts
- #### 🐞 Bug Fixes
- Wanderer: Clean deploy and install plugins for v0.20.0 update [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#15759](https://github.com/community-scripts/ProxmoxVE/pull/15759))
- Lychee: Preserve uploads and ownership during update [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#15768](https://github.com/community-scripts/ProxmoxVE/pull/15768))
- FileFlows: Handle update API 401, force update, and Node install [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#15766](https://github.com/community-scripts/ProxmoxVE/pull/15766))
- BirdNET-Go: Match new upstream release asset naming [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#15758](https://github.com/community-scripts/ProxmoxVE/pull/15758))
- [Upstream Fix] Immich: Fix loader priority [@vhsdream](https://github.com/vhsdream) ([#15755](https://github.com/community-scripts/ProxmoxVE/pull/15755))
- #### ✨ New Features
- Bump OpenCloud version to v7.2.2 [@MickLesk](https://github.com/MickLesk) ([#15769](https://github.com/community-scripts/ProxmoxVE/pull/15769))
- Silverbullet: Add optional Runtime API install via Chromium [@michelroegl-brunner](https://github.com/michelroegl-brunner) ([#15761](https://github.com/community-scripts/ProxmoxVE/pull/15761))
## 2026-07-13
### 🆕 New Scripts
+1 -1
View File
@@ -37,7 +37,7 @@ function update_script() {
systemctl stop birdnet
msg_ok "Stopped Service"
fetch_and_deploy_gh_release "birdnet" "tphakala/birdnet-go" "prebuild" "latest" "/opt/birdnet" "birdnet-go-linux-$(arch_resolve).tar.gz"
fetch_and_deploy_gh_release "birdnet" "tphakala/birdnet-go" "prebuild" "latest" "/opt/birdnet" "birdnet-go-linux-$(arch_resolve)*.tar.gz"
msg_info "Deploying Binary"
cp /opt/birdnet/birdnet-go /usr/local/bin/birdnet-go
+71 -38
View File
@@ -31,50 +31,83 @@ function update_script() {
exit
fi
update_available=$(curl -fsSL -X 'GET' "http://localhost:19200/api/status/update-available" -H 'accept: application/json' | jq .UpdateAvailable)
if [[ "${update_available}" == "true" ]]; then
msg_info "Stopping Service"
systemctl --all stop 'fileflows*'
msg_info "Stopped Service"
local proceed=false
msg_info "Creating Backup"
ls /opt/*.tar.gz &>/dev/null && rm -f /opt/*.tar.gz
backup_filename="/opt/${APP}_backup_$(date +%F).tar.gz"
tar -czf "$backup_filename" -C /opt/fileflows Data
msg_ok "Backup Created"
# FileFlows tracks the latest release, whose .NET target can move (e.g. 8 -> 10);
# ensure the current ASP.NET Core Runtime so an existing install doesn't fail to
# start after updating to a newer .NET major version.
msg_info "Ensuring ASP.NET Core Runtime"
if [[ "$(arch_resolve)" == "arm64" ]]; then
if [[ ! -x /usr/lib/dotnet10/dotnet ]]; then
curl -fsSL https://dot.net/v1/dotnet-install.sh -o /tmp/dotnet-install.sh
$STD bash /tmp/dotnet-install.sh --channel 10.0 --runtime aspnetcore --install-dir /usr/lib/dotnet10
ln -sf /usr/lib/dotnet10/dotnet /usr/bin/dotnet
rm -f /tmp/dotnet-install.sh
if systemctl list-unit-files 'fileflows.service' --no-legend 2>/dev/null | grep -q '^fileflows\.service'; then
tmp=$(mktemp)
http_code=$(curl -sSL -X 'GET' "http://localhost:19200/api/status/update-available" -H 'accept: application/json' -o "$tmp" -w '%{http_code}' 2>/dev/null) || http_code="000"
if [[ "$http_code" == "200" ]]; then
update_available=$(jq -r '.UpdateAvailable // false' "$tmp" 2>/dev/null)
rm -f "$tmp"
if [[ "${update_available}" == "true" ]]; then
proceed=true
else
msg_ok "No update required. ${APP} is already at latest version"
exit
fi
else
rm -f "$tmp"
if [[ "$http_code" == "401" ]]; then
msg_warn "Could not check for updates: API returned 401 (security may be enabled)."
else
msg_warn "Could not check for updates: API unreachable (HTTP ${http_code})."
fi
if [[ "${FORCE_UPDATE:-}" == "1" ]]; then
proceed=true
else
read -r -p "${TAB3}Force update without version check? [y/N]: " CONFIRM
if [[ "$CONFIRM" =~ ^([yY][eE][sS]|[yY])$ ]]; then
proceed=true
else
msg_error "Update aborted."
exit
fi
fi
elif ! is_package_installed "aspnetcore-runtime-10.0"; then
$STD apt remove -y aspnetcore-runtime-8.0 aspnetcore-runtime-9.0 2>/dev/null || true
setup_deb822_repo \
"microsoft" \
"https://packages.microsoft.com/keys/microsoft-2025.asc" \
"https://packages.microsoft.com/debian/13/prod/" \
"trixie"
$STD apt install -y aspnetcore-runtime-10.0
fi
msg_ok "Ensured ASP.NET Core Runtime"
fetch_and_deploy_from_url "https://fileflows.com/downloads/zip" "/opt/fileflows"
msg_info "Starting Service"
systemctl --all start 'fileflows*'
msg_ok "Started Service"
msg_ok "Updated successfully!"
else
msg_ok "No update required. ${APP} is already at latest version"
proceed=true
fi
if [[ "$proceed" != "true" ]]; then
exit
fi
msg_info "Stopping Service"
systemctl --all stop 'fileflows*'
msg_ok "Stopped Service"
msg_info "Creating Backup"
ls /opt/*.tar.gz &>/dev/null && rm -f /opt/*.tar.gz
backup_filename="/opt/${APP}_backup_$(date +%F).tar.gz"
tar -czf "$backup_filename" -C /opt/fileflows Data
msg_ok "Backup Created"
msg_info "Ensuring ASP.NET Core Runtime"
if [[ "$(arch_resolve)" == "arm64" ]]; then
if [[ ! -x /usr/lib/dotnet10/dotnet ]]; then
curl -fsSL https://dot.net/v1/dotnet-install.sh -o /tmp/dotnet-install.sh
$STD bash /tmp/dotnet-install.sh --channel 10.0 --runtime aspnetcore --install-dir /usr/lib/dotnet10
ln -sf /usr/lib/dotnet10/dotnet /usr/bin/dotnet
rm -f /tmp/dotnet-install.sh
fi
elif ! is_package_installed "aspnetcore-runtime-10.0"; then
$STD apt remove -y aspnetcore-runtime-8.0 aspnetcore-runtime-9.0 2>/dev/null || true
setup_deb822_repo \
"microsoft" \
"https://packages.microsoft.com/keys/microsoft-2025.asc" \
"https://packages.microsoft.com/debian/13/prod/" \
"trixie"
$STD apt install -y aspnetcore-runtime-10.0
fi
msg_ok "Ensured ASP.NET Core Runtime"
fetch_and_deploy_from_url "https://fileflows.com/downloads/zip" "/opt/fileflows"
msg_info "Starting Service"
systemctl --all start 'fileflows*'
msg_ok "Started Service"
msg_ok "Updated successfully!"
exit
}
+6
View File
@@ -0,0 +1,6 @@
__ __ _
\ \/ /_ ___ ______ ____ ___ (_)
\ / / / / | / / __ \/ __ `__ \/ /
/ / /_/ /| |/ / /_/ / / / / / / /
/_/\__,_/ |___/\____/_/ /_/ /_/_/
+18 -13
View File
@@ -31,33 +31,38 @@ function update_script() {
fi
if check_for_gh_release "lychee" "LycheeOrg/Lychee"; then
PHP_VER=$(php -r 'echo PHP_MAJOR_VERSION . "." . PHP_MINOR_VERSION;')
msg_info "Stopping Services"
systemctl stop caddy
systemctl stop caddy php${PHP_VER}-fpm
msg_ok "Stopped Services"
msg_info "Backing up Data"
cp /opt/lychee/.env /opt/lychee.env.bak
cp -r /opt/lychee/storage /opt/lychee_storage_backup
msg_ok "Backed up Data"
create_backup /opt/lychee/.env \
/opt/lychee/storage \
/opt/lychee/public/uploads \
/opt/lychee/public/dist
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "lychee" "LycheeOrg/Lychee" "prebuild" "latest" "/opt/lychee" "Lychee.zip"
msg_info "Restoring Data"
cp /opt/lychee.env.bak /opt/lychee/.env
rm -f /opt/lychee.env.bak
cp -r /opt/lychee_storage_backup/. /opt/lychee/storage
rm -rf /opt/lychee_storage_backup
msg_ok "Restored Data"
restore_backup
msg_info "Updating Application"
cd /opt/lychee
$STD php artisan migrate --force
$STD php artisan config:clear
$STD php artisan cache:clear
$STD php artisan optimize:clear
chmod -R 775 /opt/lychee/storage /opt/lychee/bootstrap/cache
$STD php artisan optimize
chown -R www-data:www-data /opt/lychee
chmod -R 775 /opt/lychee/storage /opt/lychee/bootstrap/cache \
/opt/lychee/public/dist /opt/lychee/public/uploads
if [[ "${VERBOSE:-no}" = "yes" ]]; then
php artisan lychee:diagnostics || true
fi
msg_ok "Updated Application"
msg_info "Starting Services"
systemctl start caddy
systemctl start caddy php${PHP_VER}-fpm
msg_ok "Started Services"
msg_ok "Updated successfully!"
fi
+1 -1
View File
@@ -30,7 +30,7 @@ function update_script() {
exit
fi
RELEASE="v7.2.1"
RELEASE="v7.2.2"
if check_for_gh_release "OpenCloud" "opencloud-eu/opencloud" "${RELEASE}" "each release is tested individually before the version is updated. Please do not open issues for this"; then
msg_info "Stopping services"
systemctl stop opencloud opencloud-wopi
+11 -2
View File
@@ -30,12 +30,14 @@ function update_script() {
exit
fi
if check_for_gh_release "wanderer" "Flomp/wanderer"; then
if check_for_gh_release "wanderer" "open-wanderer/wanderer"; then
msg_info "Stopping service"
systemctl stop wanderer-web
msg_ok "Stopped service"
fetch_and_deploy_gh_release "wanderer" "open-wanderer/wanderer" "tarball" "latest" "/opt/wanderer/source"
create_backup /opt/wanderer/source/search
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "wanderer" "open-wanderer/wanderer" "tarball" "latest" "/opt/wanderer/source"
restore_backup
msg_info "Updating wanderer"
cd /opt/wanderer/source/db
@@ -44,6 +46,13 @@ function update_script() {
cd /opt/wanderer/source/web
$STD npm ci
$STD npm run build
mkdir -p /opt/wanderer/data/plugins
[[ -e /data/plugins ]] || ln -sfn /opt/wanderer/data/plugins /data/plugins
msg_info "Installing wanderer plugins"
for plugin in hammerhead komoot strava; do
fetch_and_deploy_gh_release "wanderer-plugin-${plugin}" "open-wanderer/wanderer" "prebuild" "${CHECK_UPDATE_RELEASE:-latest}" "/opt/wanderer/data/plugins" "wanderer-plugin-${plugin}.tar.gz" || msg_warn "Failed to install wanderer plugin: ${plugin}"
done
msg_ok "Installed wanderer plugins"
msg_ok "Updated wanderer"
msg_info "Starting service"
+64
View File
@@ -0,0 +1,64 @@
#!/usr/bin/env bash
source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/build.func)
# Copyright (c) 2021-2026 community-scripts ORG
# Author: MickLesk (CanbiZ)
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
# Source: https://github.com/ulsklyc/yuvomi
APP="Yuvomi"
var_tags="${var_tags:-family;planner;calendar}"
var_cpu="${var_cpu:-2}"
var_ram="${var_ram:-1024}"
var_disk="${var_disk:-8}"
var_os="${var_os:-debian}"
var_version="${var_version:-13}"
var_arm64="${var_arm64:-yes}"
var_unprivileged="${var_unprivileged:-1}"
header_info "$APP"
variables
color
catch_errors
function update_script() {
header_info
check_container_storage
check_container_resources
if [[ ! -d /opt/yuvomi ]]; then
msg_error "No ${APP} Installation Found!"
exit
fi
if check_for_gh_release "yuvomi" "ulsklyc/yuvomi"; then
msg_info "Stopping Service"
systemctl stop yuvomi
msg_ok "Stopped Service"
create_backup /opt/yuvomi/data /opt/yuvomi/.env
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "yuvomi" "ulsklyc/yuvomi" "tarball"
msg_info "Installing Node.js Dependencies"
cd /opt/yuvomi
$STD npm ci --omit=dev
msg_ok "Installed Node.js Dependencies"
restore_backup
msg_info "Starting Service"
systemctl start yuvomi
msg_ok "Started Service"
msg_ok "Updated successfully!"
fi
exit
}
start
build_container
description
msg_ok "Completed Successfully!\n"
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
echo -e "${GATEWAY}${BGN}http://${IP}:3000${CL}"
+1 -1
View File
@@ -21,7 +21,7 @@ $STD apt install -y \
ffmpeg
msg_ok "Installed Dependencies"
fetch_and_deploy_gh_release "birdnet" "tphakala/birdnet-go" "prebuild" "latest" "/opt/birdnet" "birdnet-go-linux-$(arch_resolve).tar.gz"
fetch_and_deploy_gh_release "birdnet" "tphakala/birdnet-go" "prebuild" "latest" "/opt/birdnet" "birdnet-go-linux-$(arch_resolve)*.tar.gz"
msg_info "Setting up BirdNET-Go"
cp /opt/birdnet/birdnet-go /usr/local/bin/birdnet-go
+5 -2
View File
@@ -55,9 +55,12 @@ if [[ "$install_server" =~ ^[Ss]$ ]]; then
msg_ok "Installed FileFlows Server"
else
msg_info "Installing FileFlows Node"
read -r -p "${TAB3}Enter FileFlows Server URL (e.g. http://192.168.1.10:19200): " server_url
while [[ -z "${server_url// /}" ]]; do
read -r -p "${TAB3}Enter FileFlows Server URL (e.g. http://192.168.1.10:19200): " server_url
done
cd /opt/fileflows/Node
$STD dotnet FileFlows.Node.dll
$STD dotnet FileFlows.Node.dll --systemd install --root true
$STD dotnet FileFlows.Node.dll --server "$server_url" --systemd install --root true
systemctl enable -q --now fileflows-node
msg_ok "Installed FileFlows Node"
fi
+1 -1
View File
@@ -64,7 +64,7 @@ $STD sudo -u cool coolconfig set-admin-password --user=admin --password="$COOLPA
echo "$COOLPASS" >~/.coolpass
msg_ok "Installed Collabora Online"
fetch_and_deploy_gh_release "OpenCloud" "opencloud-eu/opencloud" "singlefile" "v7.2.1" "/usr/bin" "opencloud-*-linux-$(arch_resolve)"
fetch_and_deploy_gh_release "OpenCloud" "opencloud-eu/opencloud" "singlefile" "v7.2.2" "/usr/bin" "opencloud-*-linux-$(arch_resolve)"
mv /usr/bin/OpenCloud /usr/bin/opencloud
msg_info "Configuring OpenCloud"
+12
View File
@@ -16,6 +16,17 @@ update_os
fetch_and_deploy_gh_release "silverbullet" "silverbulletmd/silverbullet" "prebuild" "latest" "/opt/silverbullet/bin" "silverbullet-server-linux-$(arch_resolve "x86_64" "aarch64").zip"
mkdir -p /opt/silverbullet/space
RUNTIME_API_ENV=""
read -rp "${TAB3}Enable Silverbullet Runtime API? Requires Chromium (~700MB). Uses ~200MB extra RAM. (y/N): " runtime_api_prompt
if [[ "${runtime_api_prompt,,}" =~ ^(y|yes)$ ]]; then
msg_info "Installing Chromium for Runtime API"
$STD apt install -y chromium
msg_ok "Installed Chromium for Runtime API"
RUNTIME_API_ENV=$'Environment=SB_CHROME_PATH=/usr/bin/chromium\nEnvironment=SB_CHROME_DATA_DIR=/opt/silverbullet/space/.chrome-data\n'
touch /opt/silverbullet/.runtime-api-enabled
msg_ok "Runtime API will be enabled"
fi
msg_info "Creating Service"
cat <<EOF >/etc/systemd/system/silverbullet.service
[Unit]
@@ -25,6 +36,7 @@ After=syslog.target network.target
[Service]
User=root
Type=simple
${RUNTIME_API_ENV}
ExecStart=/opt/silverbullet/bin/silverbullet --hostname 0.0.0.0 --port 3000 /opt/silverbullet/space
WorkingDirectory=/opt/silverbullet
Restart=on-failure
+8 -1
View File
@@ -20,7 +20,8 @@ if [[ "$(arch_resolve)" == "arm64" ]]; then
else
fetch_and_deploy_gh_release "meilisearch" "meilisearch/meilisearch" "binary" "latest" "/opt/wanderer/source/search"
fi
mkdir -p /opt/wanderer/{source,data/pb_data,data/meili_data}
mkdir -p /opt/wanderer/{source,data/pb_data,data/meili_data,data/plugins}
[[ -e /data/plugins ]] || ln -sfn /opt/wanderer/data/plugins /data/plugins
fetch_and_deploy_gh_release "wanderer" "open-wanderer/wanderer" "tarball" "latest" "/opt/wanderer/source"
msg_info "Installing wanderer (patience)"
@@ -32,6 +33,12 @@ $STD npm ci
$STD npm run build
msg_ok "Installed wanderer"
msg_info "Installing wanderer plugins"
for plugin in hammerhead komoot strava; do
fetch_and_deploy_gh_release "wanderer-plugin-${plugin}" "open-wanderer/wanderer" "prebuild" "latest" "/opt/wanderer/data/plugins" "wanderer-plugin-${plugin}.tar.gz" || msg_warn "Failed to install wanderer plugin: ${plugin}"
done
msg_ok "Installed wanderer plugins"
msg_info "Creating Service"
MEILI_KEY=$(openssl rand -hex 32)
POCKETBASE_KEY=$(openssl rand -hex 16)
+72
View File
@@ -0,0 +1,72 @@
#!/usr/bin/env bash
# Copyright (c) 2021-2026 community-scripts ORG
# Author: MickLesk (CanbiZ)
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
# Source: https://github.com/ulsklyc/yuvomi
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
color
verb_ip6
catch_errors
setting_up_container
network_check
update_os
msg_info "Installing Dependencies"
$STD apt install -y \
python3 \
make \
g++ \
libsqlcipher-dev
msg_ok "Installed Dependencies"
NODE_VERSION="22" setup_nodejs
fetch_and_deploy_gh_release "yuvomi" "ulsklyc/yuvomi" "tarball"
msg_info "Installing Node.js Dependencies"
cd /opt/yuvomi
$STD npm ci --omit=dev
msg_ok "Installed Node.js Dependencies"
msg_info "Configuring Yuvomi"
mkdir -p /opt/yuvomi/data /opt/yuvomi/backups
SESSION_SECRET=$(openssl rand -hex 32)
DB_ENCRYPT_KEY=$(openssl rand -hex 32)
cat <<EOF >/opt/yuvomi/.env
PORT=3000
NODE_ENV=production
DB_PATH=/opt/yuvomi/data/yuvomi.db
DB_ENCRYPTION_KEY=${DB_ENCRYPT_KEY}
SESSION_SECRET=${SESSION_SECRET}
RATE_LIMIT_WINDOW_MS=60000
RATE_LIMIT_MAX_ATTEMPTS=5
RATE_LIMIT_BLOCK_DURATION_MS=900000
EOF
msg_ok "Configured Yuvomi"
msg_info "Creating Service"
cat <<EOF >/etc/systemd/system/yuvomi.service
[Unit]
Description=Yuvomi Family Planner
After=network.target
[Service]
Type=simple
User=root
WorkingDirectory=/opt/yuvomi
EnvironmentFile=/opt/yuvomi/.env
ExecStart=/usr/bin/node server/index.js
Restart=on-failure
RestartSec=5
[Install]
WantedBy=multi-user.target
EOF
systemctl enable -q --now yuvomi
msg_ok "Created Service"
motd_ssh
customize
cleanup_lxc