chore: initial backend + travel-proxy dockerized setup for NAS deployment

This commit is contained in:
2026-01-25 11:27:18 +09:00
parent 0fa163c00a
commit 9c9968b9a7
15 changed files with 1219 additions and 0 deletions

21
script/deploy-nas.sh Normal file
View File

@@ -0,0 +1,21 @@
#!/usr/bin/env bash
set -euo pipefail
ROOT="/volume1/docker/webpage"
cd "$ROOT"
echo "[1/5] git fetch + pull"
git fetch --all --prune
git pull --ff-only
echo "[2/5] docker compose build"
docker compose build --pull
echo "[3/5] docker compose up"
docker compose up -d
echo "[4/5] status"
docker compose ps
echo "[5/5] done"

15
script/healthcheck.sh Normal file
View File

@@ -0,0 +1,15 @@
#!/usr/bin/env bash
set -euo pipefail
BASE="http://127.0.0.1"
echo "backend health:"
curl -fsS "${BASE}:18000/health" | sed 's/^/ /'
echo "backend latest:"
curl -fsS "${BASE}:18000/api/lotto/latest" | head -c 200; echo
echo "travel regions:"
curl -fsS "${BASE}:19000/api/travel/regions" | head -c 200; echo
echo "OK"