amazon-web-services - AWS CloudFormation 是否支持 AWS::EC2::VPCEndpoint 的标签属性

标签 amazon-web-services tags aws-cloudformation key-value vpc

我一直在尝试为我的两个 vpc 创建端点,它正在创建 vpc,但它无法使用我需要命名创建的 vpc 端点的 Tags 属性。

Error: "Encountered unsupported property Tags"

{
  "Resources": {
        "VPCEndpoint1": {
            "Type" : "AWS::EC2::VPCEndpoint",
            "Properties" : {
                "PrivateDnsEnabled" : "True",
                "RouteTableIds" : ["rtb-1"],
                "ServiceName" : "com.amazonaws.eu-west-1.s3",
                "VpcEndpointType" : "Gateway",
                "VpcId" : "vpc-id1",
                "Tags": [
                    {
                        "Key": "Name",
                        "Value": "name1"
                    }
                ]
            }
        },
        "VPCEndpoint2": {
            "Type" : "AWS::EC2::VPCEndpoint",
            "Properties" : {
                "PrivateDnsEnabled" : "True",
                "RouteTableIds" : ["rtb-2"],
                "ServiceName" : "com.amazonaws.eu-west-1.s3",
                "VpcEndpointType" : "Gateway",
                "VpcId" : "vpc-id2",
                "Tags": [
                    {
                        "Key": "Name",
                        "Value": "name2"
                    }
                ]
            }
        }
    }
}

最佳答案

Cloudformation 不支持 Tags 属性。

引用cloudformation文档 => https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-vpcendpoint.html

关于amazon-web-services - AWS CloudFormation 是否支持 AWS::EC2::VPCEndpoint 的标签属性,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59405527/

相关文章:

amazon-web-services - 生成非 Terraform 创建的资源列表的最佳方法

amazon-web-services - AWS云表单任务定义条件命令

amazon-web-services - 模板格式错误: unsupported structure seen in AWS CloudFormation

.net - 如何将 'Tags' 添加到我的简单博客文章类库和存储库中?

amazon-web-services - 删除 Lambda 不会重置版本号

amazon-web-services - 如何更改AWS ECS集群中的实例类型?

java - 无法编译适用于java的aws sdk

amazon-web-services - 为什么我的 DynamoDB 扫描速度如此之快,而且只有 1 个预配置的读取容量单位?

Django:无法加载模板标签

python - 通过 http 连接仅获取 mp3 文件的最后 128 个字节