Skip to content

Commit 129dfde

Browse files
committed
update
1 parent 620ad59 commit 129dfde

File tree

1 file changed

+17
-4
lines changed

1 file changed

+17
-4
lines changed

.github/workflows/deploy-languages-v2-web.yml

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,31 @@ on:
66
- labeled
77
- synchronize
88
jobs:
9-
copy-to-host:
10-
name: Build
9+
build-and-deploy:
10+
name: Build and Deploy
1111
if: ${{ github.event.label.name == 'deploy-languages-v2-web' }}
1212
runs-on: ubuntu-latest
13+
env:
14+
PROJECT_PATH: apps/languagesv2/languages-v2-web
1315
steps:
1416
- uses: actions/checkout@v4
17+
- name: Set up Node.js
18+
uses: actions/setup-node@v3
19+
with:
20+
node-version: '20'
21+
- name: Install dependencies
22+
working-directory: ${{ env.PROJECT_PATH }}
23+
run: npm install
24+
- name: Build React App
25+
working-directory: ${{ env.PROJECT_PATH }}
26+
run: npm run build
1527
- name: Copy file via ssh password
1628
uses: appleboy/[email protected]
1729
with:
1830
host: ${{ secrets.UTS_HOST }}
1931
username: ${{ secrets.UTS_USERNAME }}
2032
password: ${{ secrets.UTS_PASSWORD }}
2133
port: ${{ secrets.UTS_PORT }}
22-
source: "apps/languagesv2/README.md"
23-
target: "/root/apps2"
34+
source: "${{ env.PROJECT_PATH }}/build/*"
35+
target: "/root/apps2"
36+
recursive: true

0 commit comments

Comments
 (0)