1. Packages
  2. AWS
  3. API Docs
  4. ec2
  5. VpnGatewayRoutePropagation
AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi

aws.ec2.VpnGatewayRoutePropagation

Explore with Pulumi AI

aws logo
AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi

    Requests automatic route propagation between a VPN gateway and a route table.

    Note: This resource should not be used with a route table that has the propagating_vgws argument set. If that argument is set, any route propagation not explicitly listed in its value will be removed.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = new aws.ec2.VpnGatewayRoutePropagation("example", {
        vpnGatewayId: exampleAwsVpnGateway.id,
        routeTableId: exampleAwsRouteTable.id,
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.ec2.VpnGatewayRoutePropagation("example",
        vpn_gateway_id=example_aws_vpn_gateway["id"],
        route_table_id=example_aws_route_table["id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ec2.NewVpnGatewayRoutePropagation(ctx, "example", &ec2.VpnGatewayRoutePropagationArgs{
    			VpnGatewayId: pulumi.Any(exampleAwsVpnGateway.Id),
    			RouteTableId: pulumi.Any(exampleAwsRouteTable.Id),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Aws.Ec2.VpnGatewayRoutePropagation("example", new()
        {
            VpnGatewayId = exampleAwsVpnGateway.Id,
            RouteTableId = exampleAwsRouteTable.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.ec2.VpnGatewayRoutePropagation;
    import com.pulumi.aws.ec2.VpnGatewayRoutePropagationArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new VpnGatewayRoutePropagation("example", VpnGatewayRoutePropagationArgs.builder()
                .vpnGatewayId(exampleAwsVpnGateway.id())
                .routeTableId(exampleAwsRouteTable.id())
                .build());
    
        }
    }
    
    resources:
      example:
        type: aws:ec2:VpnGatewayRoutePropagation
        properties:
          vpnGatewayId: ${exampleAwsVpnGateway.id}
          routeTableId: ${exampleAwsRouteTable.id}
    

    Create VpnGatewayRoutePropagation Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new VpnGatewayRoutePropagation(name: string, args: VpnGatewayRoutePropagationArgs, opts?: CustomResourceOptions);
    @overload
    def VpnGatewayRoutePropagation(resource_name: str,
                                   args: VpnGatewayRoutePropagationArgs,
                                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def VpnGatewayRoutePropagation(resource_name: str,
                                   opts: Optional[ResourceOptions] = None,
                                   route_table_id: Optional[str] = None,
                                   vpn_gateway_id: Optional[str] = None)
    func NewVpnGatewayRoutePropagation(ctx *Context, name string, args VpnGatewayRoutePropagationArgs, opts ...ResourceOption) (*VpnGatewayRoutePropagation, error)
    public VpnGatewayRoutePropagation(string name, VpnGatewayRoutePropagationArgs args, CustomResourceOptions? opts = null)
    public VpnGatewayRoutePropagation(String name, VpnGatewayRoutePropagationArgs args)
    public VpnGatewayRoutePropagation(String name, VpnGatewayRoutePropagationArgs args, CustomResourceOptions options)
    
    type: aws:ec2:VpnGatewayRoutePropagation
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args VpnGatewayRoutePropagationArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args VpnGatewayRoutePropagationArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args VpnGatewayRoutePropagationArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args VpnGatewayRoutePropagationArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args VpnGatewayRoutePropagationArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var vpnGatewayRoutePropagationResource = new Aws.Ec2.VpnGatewayRoutePropagation("vpnGatewayRoutePropagationResource", new()
    {
        RouteTableId = "string",
        VpnGatewayId = "string",
    });
    
    example, err := ec2.NewVpnGatewayRoutePropagation(ctx, "vpnGatewayRoutePropagationResource", &ec2.VpnGatewayRoutePropagationArgs{
    	RouteTableId: pulumi.String("string"),
    	VpnGatewayId: pulumi.String("string"),
    })
    
    var vpnGatewayRoutePropagationResource = new VpnGatewayRoutePropagation("vpnGatewayRoutePropagationResource", VpnGatewayRoutePropagationArgs.builder()
        .routeTableId("string")
        .vpnGatewayId("string")
        .build());
    
    vpn_gateway_route_propagation_resource = aws.ec2.VpnGatewayRoutePropagation("vpnGatewayRoutePropagationResource",
        route_table_id="string",
        vpn_gateway_id="string")
    
    const vpnGatewayRoutePropagationResource = new aws.ec2.VpnGatewayRoutePropagation("vpnGatewayRoutePropagationResource", {
        routeTableId: "string",
        vpnGatewayId: "string",
    });
    
    type: aws:ec2:VpnGatewayRoutePropagation
    properties:
        routeTableId: string
        vpnGatewayId: string
    

    VpnGatewayRoutePropagation Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The VpnGatewayRoutePropagation resource accepts the following input properties:

    RouteTableId string
    The id of the aws.ec2.RouteTable to propagate routes into.
    VpnGatewayId string
    The id of the aws.ec2.VpnGateway to propagate routes from.
    RouteTableId string
    The id of the aws.ec2.RouteTable to propagate routes into.
    VpnGatewayId string
    The id of the aws.ec2.VpnGateway to propagate routes from.
    routeTableId String
    The id of the aws.ec2.RouteTable to propagate routes into.
    vpnGatewayId String
    The id of the aws.ec2.VpnGateway to propagate routes from.
    routeTableId string
    The id of the aws.ec2.RouteTable to propagate routes into.
    vpnGatewayId string
    The id of the aws.ec2.VpnGateway to propagate routes from.
    route_table_id str
    The id of the aws.ec2.RouteTable to propagate routes into.
    vpn_gateway_id str
    The id of the aws.ec2.VpnGateway to propagate routes from.
    routeTableId String
    The id of the aws.ec2.RouteTable to propagate routes into.
    vpnGatewayId String
    The id of the aws.ec2.VpnGateway to propagate routes from.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the VpnGatewayRoutePropagation resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing VpnGatewayRoutePropagation Resource

    Get an existing VpnGatewayRoutePropagation resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: VpnGatewayRoutePropagationState, opts?: CustomResourceOptions): VpnGatewayRoutePropagation
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            route_table_id: Optional[str] = None,
            vpn_gateway_id: Optional[str] = None) -> VpnGatewayRoutePropagation
    func GetVpnGatewayRoutePropagation(ctx *Context, name string, id IDInput, state *VpnGatewayRoutePropagationState, opts ...ResourceOption) (*VpnGatewayRoutePropagation, error)
    public static VpnGatewayRoutePropagation Get(string name, Input<string> id, VpnGatewayRoutePropagationState? state, CustomResourceOptions? opts = null)
    public static VpnGatewayRoutePropagation get(String name, Output<String> id, VpnGatewayRoutePropagationState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    RouteTableId string
    The id of the aws.ec2.RouteTable to propagate routes into.
    VpnGatewayId string
    The id of the aws.ec2.VpnGateway to propagate routes from.
    RouteTableId string
    The id of the aws.ec2.RouteTable to propagate routes into.
    VpnGatewayId string
    The id of the aws.ec2.VpnGateway to propagate routes from.
    routeTableId String
    The id of the aws.ec2.RouteTable to propagate routes into.
    vpnGatewayId String
    The id of the aws.ec2.VpnGateway to propagate routes from.
    routeTableId string
    The id of the aws.ec2.RouteTable to propagate routes into.
    vpnGatewayId string
    The id of the aws.ec2.VpnGateway to propagate routes from.
    route_table_id str
    The id of the aws.ec2.RouteTable to propagate routes into.
    vpn_gateway_id str
    The id of the aws.ec2.VpnGateway to propagate routes from.
    routeTableId String
    The id of the aws.ec2.RouteTable to propagate routes into.
    vpnGatewayId String
    The id of the aws.ec2.VpnGateway to propagate routes from.

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aws Terraform Provider.
    aws logo
    AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi