1. Packages
  2. AWS Cloud Control
  3. API Docs
  4. ec2
  5. getInternetGateway

We recommend new projects start with resources from the AWS provider.

AWS Cloud Control v1.27.0 published on Monday, Apr 14, 2025 by Pulumi

aws-native.ec2.getInternetGateway

Explore with Pulumi AI

We recommend new projects start with resources from the AWS provider.

AWS Cloud Control v1.27.0 published on Monday, Apr 14, 2025 by Pulumi

Allocates an internet gateway for use with a VPC. After creating the Internet gateway, you then attach it to a VPC.

Using getInternetGateway

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getInternetGateway(args: GetInternetGatewayArgs, opts?: InvokeOptions): Promise<GetInternetGatewayResult>
function getInternetGatewayOutput(args: GetInternetGatewayOutputArgs, opts?: InvokeOptions): Output<GetInternetGatewayResult>
Copy
def get_internet_gateway(internet_gateway_id: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetInternetGatewayResult
def get_internet_gateway_output(internet_gateway_id: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetInternetGatewayResult]
Copy
func LookupInternetGateway(ctx *Context, args *LookupInternetGatewayArgs, opts ...InvokeOption) (*LookupInternetGatewayResult, error)
func LookupInternetGatewayOutput(ctx *Context, args *LookupInternetGatewayOutputArgs, opts ...InvokeOption) LookupInternetGatewayResultOutput
Copy

> Note: This function is named LookupInternetGateway in the Go SDK.

public static class GetInternetGateway 
{
    public static Task<GetInternetGatewayResult> InvokeAsync(GetInternetGatewayArgs args, InvokeOptions? opts = null)
    public static Output<GetInternetGatewayResult> Invoke(GetInternetGatewayInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetInternetGatewayResult> getInternetGateway(GetInternetGatewayArgs args, InvokeOptions options)
public static Output<GetInternetGatewayResult> getInternetGateway(GetInternetGatewayArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: aws-native:ec2:getInternetGateway
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

InternetGatewayId This property is required. string
The ID of the internet gateway.
InternetGatewayId This property is required. string
The ID of the internet gateway.
internetGatewayId This property is required. String
The ID of the internet gateway.
internetGatewayId This property is required. string
The ID of the internet gateway.
internet_gateway_id This property is required. str
The ID of the internet gateway.
internetGatewayId This property is required. String
The ID of the internet gateway.

getInternetGateway Result

The following output properties are available:

InternetGatewayId string
The ID of the internet gateway.
Tags List<Pulumi.AwsNative.Outputs.Tag>
Any tags to assign to the internet gateway.
InternetGatewayId string
The ID of the internet gateway.
Tags Tag
Any tags to assign to the internet gateway.
internetGatewayId String
The ID of the internet gateway.
tags List<Tag>
Any tags to assign to the internet gateway.
internetGatewayId string
The ID of the internet gateway.
tags Tag[]
Any tags to assign to the internet gateway.
internet_gateway_id str
The ID of the internet gateway.
tags Sequence[root_Tag]
Any tags to assign to the internet gateway.
internetGatewayId String
The ID of the internet gateway.
tags List<Property Map>
Any tags to assign to the internet gateway.

Supporting Types

Tag

Key This property is required. string
The key name of the tag
Value This property is required. string
The value of the tag
Key This property is required. string
The key name of the tag
Value This property is required. string
The value of the tag
key This property is required. String
The key name of the tag
value This property is required. String
The value of the tag
key This property is required. string
The key name of the tag
value This property is required. string
The value of the tag
key This property is required. str
The key name of the tag
value This property is required. str
The value of the tag
key This property is required. String
The key name of the tag
value This property is required. String
The value of the tag

Package Details

Repository
AWS Native pulumi/pulumi-aws-native
License
Apache-2.0

We recommend new projects start with resources from the AWS provider.

AWS Cloud Control v1.27.0 published on Monday, Apr 14, 2025 by Pulumi