#!/bin/bash set -euo pipefail source ./scripts/_common.sh systemctl stop "$app" 2>/dev/null || true mkdir -p "$install_dir" rm -rf "$install_dir/backend" "$install_dir/web" "$install_dir/doc" cp -a backend web doc "$install_dir"/ chown -R "$app:$app" "$install_dir" systemctl daemon-reload systemctl start "$app" systemctl reload nginx || true echo "Albumik upgraded"