File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1313 DOCKER_RUN_ARGS : >-
1414 -p 8081:8081
1515 --restart unless-stopped
16+ --log-driver=awslogs
17+ --log-opt awslogs-region=ap-northeast-2
18+ --log-opt awslogs-group=intune-chat-logs
19+ --log-opt awslogs-stream=$(hostname)
1620 S3_BUCKET : intune-deploy-bucket
1721
1822jobs :
@@ -40,14 +44,26 @@ jobs:
4044 "${{ env.ECR_REPOSITORY }}" \
4145 "${{ github.sha }}"
4246
43- # 2) 스크립트 업로드
47+ # 2) 로그 그룹 보장 (30일 보관)
48+ - name : Ensure CW log group with 30-day retention
49+ run : |
50+ aws logs create-log-group \
51+ --log-group-name intune-chat-logs \
52+ --region ${{ env.AWS_REGION }} 2>/dev/null || true
53+ aws logs put-retention-policy \
54+ --log-group-name intune-chat-logs \
55+ --retention-in-days 30 \
56+ --region ${{ env.AWS_REGION }}
57+
58+
59+ # 3) 스크립트 업로드
4460 - id : upload-script
4561 run : |
4662 aws s3 cp scripts/deploy_container.sh \
4763 "s3://${{ env.S3_BUCKET }}/deploy_container.sh" \
4864 --region "${{ env.AWS_REGION }}"
4965
50- # 3 ) SSM으로 EC2에 배포
66+ # 4 ) SSM으로 EC2에 배포
5167 - id : ssm-deploy
5268 run : |
5369 IMAGE_URI=${{ steps.build-image.outputs.image }}
7288 COMMAND_ID=$(jq -r '.Command.CommandId' send-command.json)
7389 echo "command-id=$COMMAND_ID" >> "$GITHUB_OUTPUT"
7490
75- # 4 ) SSM 결과 대기
91+ # 5 ) SSM 결과 대기
7692 - run : |
7793 bash scripts/wait_ssm.sh \
7894 "${{ env.AWS_REGION }}" \
You can’t perform that action at this time.
0 commit comments