Skip to content

refactor: 304 code 예외 제외, 로깅 순서 변경 #7

refactor: 304 code 예외 제외, 로깅 순서 변경

refactor: 304 code 예외 제외, 로깅 순서 변경 #7

Workflow file for this run

name: stage_CD
on:
push:
branches:
- develop
paths-ignore:
- 'README.md'
workflow_dispatch:
permissions:
id-token: write
contents: read
env:
LAMBDA: stage-resize-image
jobs:
upload_zip_to_lambda:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Make zip
run: |
cd src
sed -i "s/BUCKET_NAME/${{ secrets.STAGE_BUCKET_NAME }}/gi" index.js
docker build --tag sharp_on_lambda:nodejs14 .
docker run --name sharp_on_lambda_container sharp_on_lambda:nodejs14
docker cp sharp_on_lambda_container:/lambda.zip .
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v2
with:
role-to-assume: arn:aws:iam::571281437321:role/GitHubActions
aws-region: ap-northeast-2
- name: Upload AWS
run: |
cd src
aws lambda update-function-code \
--region us-east-1 \
--function-name ${{ env.LAMBDA }} \
--zip-file fileb://lambda.zip