chore: add deploy.sh script for server deployment

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Vadym Samoilenko 2026-03-18 10:19:29 +00:00
parent dc56132452
commit 89ab022c01

20
deploy.sh Normal file
View file

@ -0,0 +1,20 @@
#!/bin/bash
set -e
APP_DIR="/opt/build-a-squad"
WEB_DIR="/var/www/html/build-a-squad"
echo "==> Pulling latest code..."
cd "$APP_DIR"
git pull origin main
echo "==> Installing dependencies..."
npm install
echo "==> Building..."
npm run build
echo "==> Deploying to $WEB_DIR..."
sudo cp -r "$APP_DIR/dist/." "$WEB_DIR/"
echo "==> Done. $(date)"