Sean Front End CI/CD #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Sean Front End CI/CD | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ sean-fe-cicd ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
ref: sean-fe-cicd | |
- name: Set up Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 22.x | |
- name: Install dependencies | |
run: npm install | |
- name: Run build script | |
run: npm run build | |
- name: Upload to S3 | |
env: | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
AWS_REGION: 'ap-southeast-2' | |
run: | | |
aws s3 cp ./build s3://sample-ts-react-automation-test --recursive |