Update build pipeline to upload artifacts for the binary #256
3 changed files with 24 additions and 10 deletions
|
@ -21,7 +21,7 @@ jobs:
|
|||
- run: yarn test
|
||||
- run: yarn lint
|
||||
|
||||
publish:
|
||||
package:
|
||||
needs: build
|
||||
runs-on: node
|
||||
steps:
|
||||
|
@ -29,10 +29,21 @@ jobs:
|
|||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 20.x
|
||||
- run: yarn install --frozen-lockfile
|
||||
- run: yarn build
|
||||
- run: yarn package
|
||||
- run: cp -r ./bin ${{ secrets.PROD_REPO_PATH }}
|
||||
- name: Upload Binary
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
path: bin/
|
||||
if-no-files-found: error
|
||||
|
||||
publish:
|
||||
needs: package
|
||||
runs-on: node
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 20.x
|
||||
- uses: https://github.com/JS-DevTools/npm-publish@v3
|
||||
with:
|
||||
token: ${{ secrets.NPM_TOKEN }}
|
|
@ -4,6 +4,8 @@ on:
|
|||
push:
|
||||
branches:
|
||||
- develop
|
||||
- release/*
|
||||
- hotfix/*
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
@ -21,7 +23,7 @@ jobs:
|
|||
- run: yarn test
|
||||
- run: yarn lint
|
||||
|
||||
rsync:
|
||||
package:
|
||||
needs: build
|
||||
runs-on: node
|
||||
steps:
|
||||
|
@ -29,7 +31,9 @@ jobs:
|
|||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 20.x
|
||||
- run: yarn install --frozen-lockfile
|
||||
- run: yarn build
|
||||
- run: yarn package
|
||||
- run: cp -r ./bin ${{ secrets.STAGE_REPO_PATH }}
|
||||
- name: Upload Binary
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
path: bin/
|
||||
if-no-files-found: error
|
|
@ -4,7 +4,6 @@ on:
|
|||
push:
|
||||
branches:
|
||||
- feature/*
|
||||
- hotfix/*
|
||||
- renovate/*
|
||||
- dependabot/*
|
||||
|
||||
|
|
Loading…
Reference in a new issue