Skip to content

Commit

Permalink
optimize: optimize workflow (#219)
Browse files Browse the repository at this point in the history
Signed-off-by: slievrly <[email protected]>
  • Loading branch information
slievrly authored Apr 8, 2024
1 parent 19dbf4d commit d79022d
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 18 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ jobs:

strategy:
matrix:
node-version: [18.x]
node-version: [ 18.19.x ]

steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
Expand Down
19 changes: 9 additions & 10 deletions .github/workflows/deploy-oss.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,19 @@ on:
- cron: '0 */12 * * *'
jobs:
Build-Deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [ 18.19.x ]
steps:
- uses: actions/checkout@master
- name: Use Node.js 18.x
uses: actions/setup-node@v1
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: 18.x
node-version: ${{ matrix.node-version }}
- name: Build
run: |
npm install && npm run build && mkdir deploy-dist && cp -R build/* deploy-dist/ && mv build .htaccess *.txt *.xml deploy-dist/
- name: Use Node.js 18.x
uses: actions/setup-node@v2
with:
node-version: 18.x
npm install && npm run build -dd && mkdir deploy-dist && cp -R build/* deploy-dist/ && mv build .htaccess *.txt *.xml deploy-dist/
- run: npm i @serverless-devs/s -g --registry=https://registry.npmmirror.com
- run: s config add --AccountID ${{secrets.ACCOUNT_ID}} --AccessKeyID ${{secrets.ACCESS_KEYID}} --AccessKeySecret ${{secrets.ACCESS_KEYSECRET}} -a higress -f
- name: Deploy
Expand Down
15 changes: 9 additions & 6 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,20 @@ on:

jobs:
Build-Deploy:
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [ 18.19.x ]
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v3

- name: Use Node.js 18.x
uses: actions/setup-node@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: 18.x
node-version: ${{ matrix.node-version }}
- name: Build
run: |
npm install && npm run build && mkdir -p deploy-dist && cp -R build/* deploy-dist/ && mv build .htaccess deploy-dist/
npm install && npm run build -dd && mkdir -p deploy-dist && cp -R build/* deploy-dist/ && mv build .htaccess deploy-dist/
- name: Deploy
uses: peaceiris/[email protected]
env:
Expand Down

0 comments on commit d79022d

Please sign in to comment.