Skip to content

AWS::EC2::InternetGateway

Allocates an internet gateway for use with a VPC.

Generated by cfn-typegen --out cfn_types AWS::EC2::InternetGateway into cfn_types/ec2.py:

# Generated by cfn-typegen from the CloudFormation registry schemas. Do not edit.
# fmt: off
# ruff: noqa
"""AWS::EC2 resources."""

from collections.abc import Sequence
from typing import Any, Literal, NotRequired, Unpack
from typing_extensions import TypedDict
from cfn_typed.base import DeletionPolicy, DependsOn, ResourceAttrs, Tag, UpdateReplacePolicy, build
from cfn_typed.intrinsics import Expr


CONSTRAINTS:dict[str,Any]={
'AWS::EC2::InternetGateway':{'Tags':{'T':{'P':{'Key':{'l':1,'L':128},'Value':{'L':256}}}}},
}


ATTRIBUTES:dict[str,Any]={"AWS::EC2::InternetGateway":["InternetGatewayId"]}


RULES:dict[str,Any]={}
Nested types (3)

These are defined above the properties in the generated module.

class InternetGatewayProps(TypedDict, closed=True):
    'Allocates an internet gateway for use with a VPC.'
    Tags: NotRequired[Expr[Sequence[Expr[Tag]]]]
    'Any tags to assign to the internet gateway.'


class InternetGateway(ResourceAttrs):
    'Allocates an internet gateway for use with a VPC.'
    Type: Literal['AWS::EC2::InternetGateway']
    Properties: NotRequired[InternetGatewayProps]


def internet_gateway(
    *,
    depends_on: DependsOn | None = None,
    deletion_policy: DeletionPolicy | None = None,
    update_replace_policy: UpdateReplacePolicy | None = None,
    condition: str | None = None,
    metadata: dict[str, Any] | None = None,
    **props: Unpack[InternetGatewayProps],
) -> InternetGateway:
    return build('AWS::EC2::InternetGateway', props, depends_on, deletion_policy, update_replace_policy, condition, metadata)

Attributes

Read-only values for get_att(logical_id, attribute). They are not accepted as inputs.

  • InternetGatewayId