【发布时间】:2021-03-05 18:38:57
【问题描述】:
使用 deisgner 构建模板,Cloudformation 给出了一个
“resourcesToImport.1.member.resourceIdentifier”中的值“{LoadBalancerArn=}”未能满足约束:映射值必须满足约束:[成员的长度必须小于或等于 2048,成员的长度必须大于或等于1];
下面的代码。对 8 个不同的资源有 8 个相同的错误。知道出了什么问题吗?
"ELB": {
"Type": "AWS::ElasticLoadBalancingV2::LoadBalancer",
"Properties": {...},
"Metadata": {...}
},
"DeletionPolicy": "Retain"
},
"Listener": {
"Type": "AWS::ElasticLoadBalancingV2::Listener",
"Properties": {
"DefaultActions": [
{
"Type": "fixed-response",
"FixedResponseConfig": {
"ContentType": "text/plain",
"MessageBody": "Fixed Response",
"StatusCode": "200"
}
}
],
"LoadBalancerArn": {
"Ref": "ELB"
},
"Protocol": "HTTP"
},
"Metadata": {
"AWS::CloudFormation::Designer": {...}
},
"DependsOn": [
"ELB"
],
"DeletionPolicy": "Retain"
}
【问题讨论】:
-
您要导入一些资源吗?
-
@Marcin 我是。但是这两个都是要创建的。
-
你能澄清一下你在做什么,你得到
resourcesToImport错误吗?
标签: json amazon-web-services cloud amazon-cloudformation