feat: bootstrap NestJS backend with auth, stations, users, health-check, now-playing

This commit is contained in:
nk
2026-06-02 13:54:00 +03:00
commit 8aadd62e3c
47 changed files with 13234 additions and 0 deletions

30
scripts/deploy.sh Normal file
View File

@@ -0,0 +1,30 @@
#!/bin/bash
set -e
cd "$(dirname "$0")/.."
echo "=== radiOLA Backend Deploy ==="
# Pull latest changes if in git repo
if [ -d .git ]; then
git pull origin main || true
fi
# Ensure .env exists
if [ ! -f .env ]; then
echo "Warning: .env not found. Copying from .env.example"
cp .env.example .env
fi
# Build and start
echo "Building Docker images..."
docker compose build --no-cache
echo "Starting services..."
docker compose up -d
echo "Running database migrations..."
docker compose exec -T app npx prisma migrate deploy
echo "=== Deploy complete ==="
echo "API: http://$(curl -s ifconfig.me || echo 'localhost')"