All checks were successful
Deploy Web Client / deploy (push) Successful in 37s
- npm start instead of npm run dev - CI does npm run build before restart - Pages load in ~50ms instead of ~2s
31 lines
675 B
YAML
31 lines
675 B
YAML
name: Deploy Web Client
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: self-hosted
|
|
steps:
|
|
- name: Pull latest code
|
|
run: |
|
|
cd /root/projects/team-board/web-client
|
|
git pull origin main
|
|
|
|
- name: Install and build
|
|
run: |
|
|
cd /root/projects/team-board/web-client
|
|
npm install --production=false
|
|
npm run build
|
|
|
|
- name: Restart service
|
|
run: |
|
|
systemctl restart team-board-web
|
|
|
|
- name: Health check
|
|
run: |
|
|
sleep 8
|
|
curl -sf -o /dev/null http://localhost:3100/login || exit 1
|
|
echo "✅ Web client deployed successfully"
|