gpt4 book ai didi

git - 由于 "HEALTH_CONSTRAINTS",AWS 部署失败

转载 作者:太空狗 更新时间:2023-10-29 13:48:06 28 4
gpt4 key购买 nike

我正在处理一个场景,我需要将代码从 GIT 存储库推送到 AWS 实例。为此,我使用了 AWS CodeDeploy 功能。但是在部署代码过程的最后一步,我收到以下错误。

Deployment Failed The overall deployment failed because too many individual instances failed deployment, too few healthy instances are available for deployment, or some instances in your deployment group are experiencing problems. (Error code: HEALTH_CONSTRAINTS)

最佳答案

如果 EC2 实例没有正确的 IAM 角色,您会看到此错误。使用策略“AmazonEC2RoleforAWSCodeDeploy”创建 IAM 角色。您无法将 IAM 角色添加到现有实例,因此您必须启动一个新实例。

还要确保您已经为正确的区域安装了 CodeDeploy 代理,例如对于 us-east-1:

apt-get -y install awscli ruby2.0
aws s3 cp s3://aws-codedeploy-us-east-1/latest/install . --region us-east-1
chmod +x ./install
./install auto

http://docs.aws.amazon.com/codedeploy/latest/userguide/how-to-set-up-new-instance.html

关于git - 由于 "HEALTH_CONSTRAINTS",AWS 部署失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39143191/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com