larpaso-website/deploy.sh
Lara b3a3680d76 Add deploy.sh so the rollout is one short command
The full ssh one-liner is long enough that copying it reliably is a
problem. "bash deploy.sh" is short enough to type by hand.

Same sequence as before, with the mandatory order documented in the
file: build admin before publishing, because publish-content-to-live.sh
builds inside the admin container.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-10-04 18:41:40 +02:00

31 lines
1 KiB
Bash
Executable file

#!/bin/bash
# Rollt den aktuellen main-Stand auf larpaso.de aus.
#
# Aufruf vom eigenen Rechner aus (im Projektordner):
# bash deploy.sh
# In Claude Code genuegt:
# ! bash deploy.sh
#
# Reihenfolge ist Pflicht: publish-content-to-live.sh baut IM Admin-Container.
# Ist der nicht frisch gebaut, baut er mit dem alten Template und die
# Content-Aenderung wirkt scheinbar nicht. Siehe DEPLOYMENT_ADMIN.md,
# Abschnitt "Content-Updates ueber Git/Claude Code".
#
# Achtung: Dies ueberschreibt content/site.json und theme.json auf dem Server
# mit dem Git-Stand. Wurde zwischendurch ueber admin.larpaso.de etwas
# geaendert, vorher sync-content-from-live.sh laufen lassen.
set -euo pipefail
SERVER="${1:-deploy@larpaso.de}"
echo "==> Rolle auf $SERVER aus ..."
ssh "$SERVER" '
set -e
cd ~/sites/larpaso-website && git pull
cd ~/stack
docker compose build admin website
docker compose up -d admin website
~/sites/larpaso-website/publish-content-to-live.sh
'
echo
echo "==> Fertig. larpaso.de einmal mit Strg+F5 neu laden."