Skip to content

Commit

Permalink
Merge pull request #60 from prgrms-web-devcourse-final-project/featur…
Browse files Browse the repository at this point in the history
…e/deploy

Feat: CI/CD 추가
  • Loading branch information
cho1ys authored Jan 14, 2025
2 parents 94d4e65 + 3f2db48 commit dc74d3b
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: CI/CD

on:
push:
branches:
- main
- feature/deploy

jobs:
build-deploy:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Set Up Node.js
uses: actions/setup-node@v3
with:
node-version: '20'

- name: Install and Build
run: |
npm install
npm run build
- name: Deploy to S3
uses: aws-actions/configure-aws-credentials@v2
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}

- name: Upload to S3
run: |
aws s3 sync ./dist/ s3://${{ secrets.AWS_S3_BUCKET }} --delete

0 comments on commit dc74d3b

Please sign in to comment.