-
-
Notifications
You must be signed in to change notification settings - Fork 26
35 lines (30 loc) · 792 Bytes
/
react-frontend.yml
File metadata and controls
35 lines (30 loc) · 792 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
name: Frontend deploy
on:
push:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-22.04
defaults:
run:
working-directory: 'ts-grpc-vite-front'
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Node.js environment
uses: actions/setup-node@v4
with:
node-version: '22'
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build
- name: Deploy demo front files via ssh
uses: appleboy/scp-action@master
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
key: ${{ secrets.SSH_KEY }}
source: "./ts-grpc-vite-front/dist"
target: ${{ secrets.REACT_DEMO_TARGET_PATH }}
strip_components: 1