-
Notifications
You must be signed in to change notification settings - Fork 9
47 lines (40 loc) · 1.52 KB
/
demo.yml
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
36
37
38
39
40
41
42
43
44
45
46
47
name: demo
on:
push:
tags:
- "*"
jobs:
build-and-deploy:
runs-on: ubuntu-latest
environment: demo
env:
CI: false
REACT_APP_CLIENT_ID: ${{ secrets.REACT_APP_CLIENT_ID }}
REACT_APP_CLIENT_SECRET: ${{ secrets.REACT_APP_CLIENT_SECRET }}
REACT_APP_ENCRYPT: ${{ secrets.REACT_APP_ENCRYPT }}
REACT_APP_BI_ENDPOINT_URL: ${{ secrets.REACT_APP_BI_ENDPOINT_URL }}
REACT_APP_DATA_STREAM: ${{ secrets.REACT_APP_DATA_STREAM }}
REACT_APP_DEFAULT_USER: ${{ secrets.REACT_APP_DEFAULT_USER }}
REACT_APP_DEFAULT_PASSWORD: ${{ secrets.REACT_APP_DEFAULT_PASSWORD }}
REACT_APP_DEMO_USER: ${{ secrets.REACT_APP_DEMO_USER }}
REACT_APP_DEMO_PASSWORD: ${{ secrets.REACT_APP_DEMO_PASSWORD }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
ref: master
- uses: actions/setup-node@v4
with:
node-version: 18
- run: git submodule update --init --recursive
- run: yarn install --frozen-lockfile
- run: yarn build
- name: Install SSH Key
uses: shimataro/ssh-key-action@v2
with:
key: ${{ secrets.SSH_PRIVATE_KEY }}
known_hosts: unnecessary
- name: Adding Known Hosts
run: ssh-keyscan -p ${{ secrets.SSH_PORT}} -H ${{ secrets.SSH_HOST }} >> ~/.ssh/known_hosts
- name: Deploy with rsync
run: rsync -avz -e "ssh -p ${{ secrets.SSH_PORT }}" ./packages/aesirx-bi-app/build/ ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }}:${{ secrets.SSH_PATH }}