Skip to content
v2.277.0

CfnGatewayProps Struct ​

Properties for defining a CfnGateway.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_ecs as ecs } from 'aws-cdk-lib';
const cfnGatewayProps: ecs.CfnGatewayProps = {
  configuration: {
    hostSharedAlb: {
      accessLogs: {
        destination: {
          s3: {
            bucket: 'bucket',

            // the properties below are optional
            prefix: 'prefix',
          },
        },
      },
      currentAlbCount: 123,
      httpDesync: 'httpDesync',
      maxAlbCount: 123,
      networkConfiguration: {
        inboundSecurityGroup: 'inboundSecurityGroup',
        ipAddressType: 'ipAddressType',
        subnets: ['subnets'],
      },
      port: 123,
      protocol: 'protocol',
      scheme: 'scheme',
      testTrafficRules: {
        header: {
          name: 'name',
          values: ['values'],
        },
      },
      webAclArn: 'webAclArn',
    },
  },
  gatewayName: 'gatewayName',
  infrastructureRoleArn: 'infrastructureRoleArn',

  // the properties below are optional
  deletionProtection: false,
  propagateTags: 'propagateTags',
  tags: [{
    key: 'key',
    value: 'value',
  }],
};
python
from aws_cdk import CfnTag
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_ecs as ecs

cfn_gateway_props = ecs.CfnGatewayProps(
    configuration=ecs.CfnGateway.GatewayConfigurationProperty(
        host_shared_alb=ecs.CfnGateway.HostSharedAlbConfigurationProperty(
            access_logs=ecs.CfnGateway.GatewayElbAccessLogConfigurationProperty(
                destination=ecs.CfnGateway.GatewayElbAccessLogDestinationProperty(
                    s3=ecs.CfnGateway.GatewayElbAccessLogS3DestinationProperty(
                        bucket="bucket",

                        # the properties below are optional
                        prefix="prefix"
                    )
                )
            ),
            current_alb_count=123,
            http_desync="httpDesync",
            max_alb_count=123,
            network_configuration=ecs.CfnGateway.GatewayElbNetworkConfigurationProperty(
                inbound_security_group="inboundSecurityGroup",
                ip_address_type="ipAddressType",
                subnets=["subnets"]
            ),
            port=123,
            protocol="protocol",
            scheme="scheme",
            test_traffic_rules=ecs.CfnGateway.GatewayAlbTestTrafficRulesProperty(
                header=ecs.CfnGateway.GatewayTestTrafficHeaderProperty(
                    name="name",
                    values=["values"]
                )
            ),
            web_acl_arn="webAclArn"
        )
    ),
    gateway_name="gatewayName",
    infrastructure_role_arn="infrastructureRoleArn",

    # the properties below are optional
    deletion_protection=False,
    propagate_tags="propagateTags",
    tags=[CfnTag(
        key="key",
        value="value"
    )]
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.ecs.*;

CfnGatewayProps cfnGatewayProps = CfnGatewayProps.builder()
        .configuration(GatewayConfigurationProperty.builder()
                .hostSharedAlb(HostSharedAlbConfigurationProperty.builder()
                        .accessLogs(GatewayElbAccessLogConfigurationProperty.builder()
                                .destination(GatewayElbAccessLogDestinationProperty.builder()
                                        .s3(GatewayElbAccessLogS3DestinationProperty.builder()
                                                .bucket("bucket")

                                                // the properties below are optional
                                                .prefix("prefix")
                                                .build())
                                        .build())
                                .build())
                        .currentAlbCount(123)
                        .httpDesync("httpDesync")
                        .maxAlbCount(123)
                        .networkConfiguration(GatewayElbNetworkConfigurationProperty.builder()
                                .inboundSecurityGroup("inboundSecurityGroup")
                                .ipAddressType("ipAddressType")
                                .subnets(List.of("subnets"))
                                .build())
                        .port(123)
                        .protocol("protocol")
                        .scheme("scheme")
                        .testTrafficRules(GatewayAlbTestTrafficRulesProperty.builder()
                                .header(GatewayTestTrafficHeaderProperty.builder()
                                        .name("name")
                                        .values(List.of("values"))
                                        .build())
                                .build())
                        .webAclArn("webAclArn")
                        .build())
                .build())
        .gatewayName("gatewayName")
        .infrastructureRoleArn("infrastructureRoleArn")

        // the properties below are optional
        .deletionProtection(false)
        .propagateTags("propagateTags")
        .tags(List.of(CfnTag.builder()
                .key("key")
                .value("value")
                .build()))
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.ECS;

var cfnGatewayProps = new CfnGatewayProps {
    Configuration = new GatewayConfigurationProperty {
        HostSharedAlb = new HostSharedAlbConfigurationProperty {
            AccessLogs = new GatewayElbAccessLogConfigurationProperty {
                Destination = new GatewayElbAccessLogDestinationProperty {
                    S3 = new GatewayElbAccessLogS3DestinationProperty {
                        Bucket = "bucket",

                        // the properties below are optional
                        Prefix = "prefix"
                    }
                }
            },
            CurrentAlbCount = 123,
            HttpDesync = "httpDesync",
            MaxAlbCount = 123,
            NetworkConfiguration = new GatewayElbNetworkConfigurationProperty {
                InboundSecurityGroup = "inboundSecurityGroup",
                IpAddressType = "ipAddressType",
                Subnets = new [] { "subnets" }
            },
            Port = 123,
            Protocol = "protocol",
            Scheme = "scheme",
            TestTrafficRules = new GatewayAlbTestTrafficRulesProperty {
                Header = new GatewayTestTrafficHeaderProperty {
                    Name = "name",
                    Values = new [] { "values" }
                }
            },
            WebAclArn = "webAclArn"
        }
    },
    GatewayName = "gatewayName",
    InfrastructureRoleArn = "infrastructureRoleArn",

    // the properties below are optional
    DeletionProtection = false,
    PropagateTags = "propagateTags",
    Tags = new [] { new CfnTag {
        Key = "key",
        Value = "value"
    } }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

cfnGatewayProps := &CfnGatewayProps{
	Configuration: &GatewayConfigurationProperty{
		HostSharedAlb: &HostSharedAlbConfigurationProperty{
			AccessLogs: &GatewayElbAccessLogConfigurationProperty{
				Destination: &GatewayElbAccessLogDestinationProperty{
					S3: &GatewayElbAccessLogS3DestinationProperty{
						Bucket: jsii.String("bucket"),

						// the properties below are optional
						Prefix: jsii.String("prefix"),
					},
				},
			},
			CurrentAlbCount: jsii.Number(123),
			HttpDesync: jsii.String("httpDesync"),
			MaxAlbCount: jsii.Number(123),
			NetworkConfiguration: &GatewayElbNetworkConfigurationProperty{
				InboundSecurityGroup: jsii.String("inboundSecurityGroup"),
				IpAddressType: jsii.String("ipAddressType"),
				Subnets: []*string{
					jsii.String("subnets"),
				},
			},
			Port: jsii.Number(123),
			Protocol: jsii.String("protocol"),
			Scheme: jsii.String("scheme"),
			TestTrafficRules: &GatewayAlbTestTrafficRulesProperty{
				Header: &GatewayTestTrafficHeaderProperty{
					Name: jsii.String("name"),
					Values: []*string{
						jsii.String("values"),
					},
				},
			},
			WebAclArn: jsii.String("webAclArn"),
		},
	},
	GatewayName: jsii.String("gatewayName"),
	InfrastructureRoleArn: jsii.String("infrastructureRoleArn"),

	// the properties below are optional
	DeletionProtection: jsii.Boolean(false),
	PropagateTags: jsii.String("propagateTags"),
	Tags: []CfnTag{
		&CfnTag{
			Key: jsii.String("key"),
			Value: jsii.String("value"),
		},
	},
}

Properties ​

configurationIResolvable | CfnGateway.GatewayConfigurationPropertyconfigurationtyping.Union[IResolvable, GatewayConfigurationProperty]configurationIResolvableConfigurationIResolvableConfigurationinterface{}required#
The configuration for the gateway.

Currently only supports hostSharedAlb.

deletionProtectionoptionalboolean | IResolvabledeletion_protectionoptionaltyping.Union[bool, IResolvable]deletionProtectionoptionalBooleanDeletionProtectionoptionalboolDeletionProtectionoptionalinterface{}= true#
Whether deletion protection is enabled for the gateway.
gatewayNamestringgateway_namestrgatewayNameStringGatewayNamestringGatewayName*stringrequired#
The name of the gateway.

Up to 255 letters (uppercase and lowercase), numbers, and hyphens are allowed.

infrastructureRoleArnstringinfrastructure_role_arnstrinfrastructureRoleArnStringInfrastructureRoleArnstringInfrastructureRoleArn*stringrequired#
The ARN of the IAM role that ECS uses to manage infrastructure for the gateway.
propagateTagsoptionalstringpropagate_tagsoptionalstrpropagateTagsoptionalStringPropagateTagsoptionalstringPropagateTagsoptional*string#
Specifies whether to propagate the tags from the gateway to other resources.
tagsoptionalCfnTag[]tagsoptionaltyping.List[CfnTag]tagsoptionalList<CfnTag>TagsoptionalCfnTag[]Tagsoptional*[]CfnTag#
The metadata that you apply to the gateway to help you categorize and organize them.