AWS SAM - 无法创建变更集:Water ChangeSetCreateComplete 失败 [英] AWS SAM - Failed to create the changeset: Waiter ChangeSetCreateComplete failed
问题描述
AWS SAM 使用 aws-sam-cli 将代码库部署到 AWS 云,但它让我陷入以下错误.
AWS SAM deploying codebase to AWS cloud using aws-sam-cli but it throw me below error.
未能创建变更集:Water ChangeSetCreateComplete 失败:Water 遇到终端故障状态状态:FAILED.原因:需要功能:[CAPABILITY_IAM]
推荐答案
在创建或部署堆栈时,您需要明确允许创建 IAM 资源.为此,您需要在调用 sam deploy
时添加参数:
When you're creating or deploying a stack you need to explicitly allow creation of IAM resources. To do that, you need to add the parameter when calling sam deploy
:
--capabilities CAPABILITY_IAM
如果您想创建命名的 IAM 资源(例如,您明确指定名称的角色或用户),您需要改用 --capabilities CAPABILITY_NAMED_IAM
.
If you want to create named IAM resources (e.g. roles or users where you explicitly specify the name), you'll want to use --capabilities CAPABILITY_NAMED_IAM
instead.
您可以在此处阅读有关在 CloudFormation 中部署 IAM 资源的更多信息:https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-iam-template.html#using-iam-capabilities
You can read more about deploying IAM resources in CloudFormation here: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-iam-template.html#using-iam-capabilities
这篇关于AWS SAM - 无法创建变更集:Water ChangeSetCreateComplete 失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!