Skip to content

Commit 05c0455

Browse files
authored
Add GitHub Actions workflow for Vite deployment
1 parent ca54d55 commit 05c0455

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Deploy to Server (Self-hosted, Vite)
2+
3+
on:
4+
push:
5+
branches:
6+
- prod/iiitnr
7+
8+
jobs:
9+
deploy:
10+
name: Deploy on Self-Hosted Server
11+
runs-on: self-hosted
12+
13+
steps:
14+
- name: 📦 Checkout code
15+
uses: actions/checkout@v4
16+
17+
- name: Setup Node
18+
uses: actions/setup-node@v4
19+
with:
20+
node-version: '24'
21+
22+
- run: npm ci
23+
- run: CI=false npm run build
24+
25+
- name: 🚀 Deploy build
26+
run: |
27+
rm -rf /var/www/html/*
28+
cp -r dist/* /var/www/html/

0 commit comments

Comments
 (0)