Skip to content

Commit

Permalink
🔨 Fix: S3 object retrieval in deploy.yml
Browse files Browse the repository at this point in the history
#
  • Loading branch information
qilip committed Nov 9, 2023
1 parent 5da00b2 commit f7952b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ jobs:
PREFIX="_nuxt/"
# _nuxt/ 프리픽스로 시작하는 모든 S3 객체 가져오기
aws s3api list-objects-v2 --bucket ${{ env.AWS_S3_BUCKET }} --prefix $PREFIX --output json | jq -r '.Contents[] | .Key + " " + (.LastModified | strflocaltime("%Y-%m-%d"))' | sort -k2,2r > objects_by_date.txt
aws s3api list-objects-v2 --bucket ${{ env.AWS_S3_BUCKET }} --prefix $PREFIX --output json | jq -r '.Contents[] | "\(.Key) \(.LastModified)"' | awk '{sub(/\..*/,"",$NF); print $0}' | sort -k2r > objects_by_date.txt
# 각 날짜별로 파일 그룹화하고, 날짜만 추출하여 배열 생성
DATES=($(cat objects_by_date.txt | cut -d ' ' -f2 | uniq))
Expand Down

0 comments on commit f7952b7

Please sign in to comment.