321 chore 키워드 편지 상세 조회 삭제 요청 파라미터 수정 (#322) #38
Workflow file for this run
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: postamn | |
on: | |
push: | |
branches: | |
- develope | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '20.18.0' | |
- name: Cache Yarn dependencies | |
uses: actions/cache@v3 | |
with: | |
path: ./.yarn/cache | |
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.os }}-yarn- | |
- name: Install dependencies | |
run: yarn install | |
- name: Build project | |
run: | | |
VITE_API_URL=${{ secrets.VITE_API_URL }} \ | |
yarn build | |
- name: Deploy to S3 | |
uses: jakejarvis/[email protected] | |
with: | |
args: --delete | |
env: | |
AWS_S3_BUCKET: devfinal | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
AWS_REGION: ap-northeast-2 | |
SOURCE_DIR: dist | |
- name: Invalidate CloudFront Cache | |
run: | | |
aws cloudfront create-invalidation \ | |
--distribution-id ${{ secrets.CLOUDFRONT_DISTRIBUTION_ID }} \ | |
--paths "/*" | |
env: | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
AWS_REGION: ap-northeast-2 |