UNPKG

@pulumi/aws

Version:

A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.

154 lines (153 loc) 5.89 kB
import * as pulumi from "@pulumi/pulumi"; /** * Provides additional routes for AWS Client VPN endpoints. For more information on usage, please see the * [AWS Client VPN Administrator's Guide](https://docs.aws.amazon.com/vpn/latest/clientvpn-admin/what-is.html). * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const exampleEndpoint = new aws.ec2clientvpn.Endpoint("example", { * description: "Example Client VPN endpoint", * serverCertificateArn: exampleAwsAcmCertificate.arn, * clientCidrBlock: "10.0.0.0/16", * authenticationOptions: [{ * type: "certificate-authentication", * rootCertificateChainArn: exampleAwsAcmCertificate.arn, * }], * connectionLogOptions: { * enabled: false, * }, * }); * const exampleNetworkAssociation = new aws.ec2clientvpn.NetworkAssociation("example", { * clientVpnEndpointId: exampleEndpoint.id, * subnetId: exampleAwsSubnet.id, * }); * const example = new aws.ec2clientvpn.Route("example", { * clientVpnEndpointId: exampleEndpoint.id, * destinationCidrBlock: "0.0.0.0/0", * targetVpcSubnetId: exampleNetworkAssociation.subnetId, * }); * ``` * * ## Import * * Using `pulumi import`, import AWS Client VPN routes using the endpoint ID, target subnet ID, and destination CIDR block. All values are separated by a `,`. For example: * * ```sh * $ pulumi import aws:ec2clientvpn/route:Route example cvpn-endpoint-1234567890abcdef,subnet-9876543210fedcba,10.1.0.0/24 * ``` */ export declare class Route extends pulumi.CustomResource { /** * Get an existing Route resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: RouteState, opts?: pulumi.CustomResourceOptions): Route; /** * Returns true if the given object is an instance of Route. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is Route; /** * The ID of the Client VPN endpoint. */ readonly clientVpnEndpointId: pulumi.Output<string>; /** * A brief description of the route. */ readonly description: pulumi.Output<string | undefined>; /** * The IPv4 or IPv6 address range, in CIDR notation, of the route destination. */ readonly destinationCidrBlock: pulumi.Output<string>; /** * Indicates how the Client VPN route was added. Will be `add-route` for routes created by this resource. */ readonly origin: pulumi.Output<string>; /** * Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration. */ readonly region: pulumi.Output<string>; /** * The ID of the Subnet to route the traffic through. It must already be attached to the Client VPN. */ readonly targetVpcSubnetId: pulumi.Output<string>; /** * The type of the route. */ readonly type: pulumi.Output<string>; /** * Create a Route resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: RouteArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering Route resources. */ export interface RouteState { /** * The ID of the Client VPN endpoint. */ clientVpnEndpointId?: pulumi.Input<string>; /** * A brief description of the route. */ description?: pulumi.Input<string>; /** * The IPv4 or IPv6 address range, in CIDR notation, of the route destination. */ destinationCidrBlock?: pulumi.Input<string>; /** * Indicates how the Client VPN route was added. Will be `add-route` for routes created by this resource. */ origin?: pulumi.Input<string>; /** * Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration. */ region?: pulumi.Input<string>; /** * The ID of the Subnet to route the traffic through. It must already be attached to the Client VPN. */ targetVpcSubnetId?: pulumi.Input<string>; /** * The type of the route. */ type?: pulumi.Input<string>; } /** * The set of arguments for constructing a Route resource. */ export interface RouteArgs { /** * The ID of the Client VPN endpoint. */ clientVpnEndpointId: pulumi.Input<string>; /** * A brief description of the route. */ description?: pulumi.Input<string>; /** * The IPv4 or IPv6 address range, in CIDR notation, of the route destination. */ destinationCidrBlock: pulumi.Input<string>; /** * Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration. */ region?: pulumi.Input<string>; /** * The ID of the Subnet to route the traffic through. It must already be attached to the Client VPN. */ targetVpcSubnetId: pulumi.Input<string>; }