Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: CI pipeline
on:
workflow_dispatch:
workflow_call:
pull_request:
branches:
- 'dev'
Expand Down Expand Up @@ -29,3 +30,8 @@ jobs:
run: yarn test
- name: build code
run: yarn build
- name: upload artifact
uses: actions/upload-artifact@v4
with:
name: build
path: dist
30 changes: 30 additions & 0 deletions .github/workflows/S3-Deploy-Boris.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: CD pipeline Boris
on:
workflow_dispatch:
permissions:
contents: read
id-token: write
jobs:
rerun-CI-worlflow:
uses: ./.github/workflows/CI.yml
deploy-to-S3:
needs: rerun-CI-worlflow
runs-on: ubuntu-latest
steps:
- name: checkout code
uses: actions/checkout@v4
- name: download artifact
uses: actions/download-artifact@v4
with:
name: build
path: dist
- name: configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
audience: sts.amazonaws.com
aws-region: ap-southeast-2
role-to-assume: ${{ secrets.AWS_ROLE_ARN_BORIS }}
- name: sts get caller identity
run: aws sts get-caller-identity
- name: deploy to S3
run: aws s3 sync dist s3://${{ secrets.AWS_S3_BUCKET_BORIS }}