ECS Blue/Green CodeDeploy 배포 시 unhealthy임에도 배포 성공

0

ECS Blue/Green 서비스를 CodePipeline을 통해 배포하고 있습니다. 그런데 대상 그룹이 unhealthy 상태임에도 CodeDeploy에서 배포가 실패하지 않고 성공합니다. 그리고 ECS 서비스에서는 아래처럼 대상 Register/Deregister가 계속 반복되고 있습니다.

service test-service deregistered 1 targets in target-group localhost-localhost-default

service test-service has begun draining connections on 1 tasks.

service test-service deregistered 1 targets in target-group localhost-localhost-default

service test-service has started 2 tasks: task 4e1569b3-a15c-4bac-85f7-396b530113a5 task d5651035-8e3d-48df-b457-d05e5b7be8db.

CodeDeploy에서 상태 검사가 실패한다면 배포를 중단하고 롤백할 수 있는 방법이 있을까요? 감사합니다.

已提问 1 年前270 查看次数
1 回答
1
已接受的回答

Lambda 등을 사용하여 CodeDeploy가 실행되어 일정 기간 동안 ALB 상태 검사를 확인하고 건강하지 않은 경우 롤백하는 이벤트에 트리거되는 스크립트를 만드는 것은 어떨까요?

다른 문서를 보면 롤백하는 방법은 여러 가지가 있는 것 같습니다.
https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-groups-configure-advanced-options.html

profile picture
专家
已回答 1 年前
  • 감사합니다. Cloudwatch와 Lambda를 사용해 봐야겠네요

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则