Files
Media-Server-Setup/deployLive.sh
Brandyn / Techy 18f4e07de8 Split hosts: media (gateway at /), files, clips, sync; live gains /dock, /dock/clock, /dump, /me, /time
configure.py: three new host roles (files/sync/clips) in --full, --hosts, .env, Caddy generator;
main host serves about/ at the root (/about* redirects); /time only where it is fetched same-origin.
about/index.html links across hosts; addCommunityMediaServer.sh asks for the new names; Caddyfile.example
regenerated; README/FRESH-INSTALL/HOSTNAME-CHANGE (procedure C)/STATUS updated.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-01 01:38:35 -05:00

12 lines
584 B
Bash
Executable File

#!/bin/bash
# Build the live portal here and push the static files to /srv/live on the server. Caddy serves them as-is.
set -euo pipefail
cd "$(dirname "$0")/live"
HOST="${1:-debian@media.dumpstervigilantes.rip}" # any name of the box works for ssh
npm install --no-audit --no-fund --loglevel=error
npm run build
ssh "$HOST" 'sudo install -d -o "$(id -u)" -g "$(id -g)" /srv/live && rm -rf /srv/live/*'
scp -r dist/. "$HOST:/srv/live/"
ssh "$HOST" 'ls -la /srv/live | head -5'
echo "deployed -> https://$(ssh "$HOST" 'cd ~/vanguard-stream && grep ^LIVE_HOST= .env | cut -d= -f2')/"