com.pulumi.aws.apigateway.kotlin.VpcLinkArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-aws-kotlin Show documentation
Show all versions of pulumi-aws-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.aws.apigateway.kotlin
import com.pulumi.aws.apigateway.VpcLinkArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.collections.Map
import kotlin.jvm.JvmName
/**
* Provides an API Gateway VPC Link.
* > **Note:** Amazon API Gateway Version 1 VPC Links enable private integrations that connect REST APIs to private resources in a VPC.
* To enable private integration for HTTP APIs, use the Amazon API Gateway Version 2 VPC Link resource.
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
* const example = new aws.lb.LoadBalancer("example", {
* name: "example",
* internal: true,
* loadBalancerType: "network",
* subnetMappings: [{
* subnetId: "12345",
* }],
* });
* const exampleVpcLink = new aws.apigateway.VpcLink("example", {
* name: "example",
* description: "example description",
* targetArn: example.arn,
* });
* ```
* ```python
* import pulumi
* import pulumi_aws as aws
* example = aws.lb.LoadBalancer("example",
* name="example",
* internal=True,
* load_balancer_type="network",
* subnet_mappings=[{
* "subnet_id": "12345",
* }])
* example_vpc_link = aws.apigateway.VpcLink("example",
* name="example",
* description="example description",
* target_arn=example.arn)
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Aws = Pulumi.Aws;
* return await Deployment.RunAsync(() =>
* {
* var example = new Aws.LB.LoadBalancer("example", new()
* {
* Name = "example",
* Internal = true,
* LoadBalancerType = "network",
* SubnetMappings = new[]
* {
* new Aws.LB.Inputs.LoadBalancerSubnetMappingArgs
* {
* SubnetId = "12345",
* },
* },
* });
* var exampleVpcLink = new Aws.ApiGateway.VpcLink("example", new()
* {
* Name = "example",
* Description = "example description",
* TargetArn = example.Arn,
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/apigateway"
* "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/lb"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* example, err := lb.NewLoadBalancer(ctx, "example", &lb.LoadBalancerArgs{
* Name: pulumi.String("example"),
* Internal: pulumi.Bool(true),
* LoadBalancerType: pulumi.String("network"),
* SubnetMappings: lb.LoadBalancerSubnetMappingArray{
* &lb.LoadBalancerSubnetMappingArgs{
* SubnetId: pulumi.String("12345"),
* },
* },
* })
* if err != nil {
* return err
* }
* _, err = apigateway.NewVpcLink(ctx, "example", &apigateway.VpcLinkArgs{
* Name: pulumi.String("example"),
* Description: pulumi.String("example description"),
* TargetArn: example.Arn,
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.aws.lb.LoadBalancer;
* import com.pulumi.aws.lb.LoadBalancerArgs;
* import com.pulumi.aws.lb.inputs.LoadBalancerSubnetMappingArgs;
* import com.pulumi.aws.apigateway.VpcLink;
* import com.pulumi.aws.apigateway.VpcLinkArgs;
* 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 LoadBalancer("example", LoadBalancerArgs.builder()
* .name("example")
* .internal(true)
* .loadBalancerType("network")
* .subnetMappings(LoadBalancerSubnetMappingArgs.builder()
* .subnetId("12345")
* .build())
* .build());
* var exampleVpcLink = new VpcLink("exampleVpcLink", VpcLinkArgs.builder()
* .name("example")
* .description("example description")
* .targetArn(example.arn())
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: aws:lb:LoadBalancer
* properties:
* name: example
* internal: true
* loadBalancerType: network
* subnetMappings:
* - subnetId: '12345'
* exampleVpcLink:
* type: aws:apigateway:VpcLink
* name: example
* properties:
* name: example
* description: example description
* targetArn: ${example.arn}
* ```
*
* ## Import
* Using `pulumi import`, import API Gateway VPC Link using the `id`. For example:
* ```sh
* $ pulumi import aws:apigateway/vpcLink:VpcLink example 12345abcde
* ```
* @property description Description of the VPC link.
* @property name Name used to label and identify the VPC link.
* @property tags Key-value map of resource tags. If configured with a provider `default_tags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
* @property targetArn List of network load balancer arns in the VPC targeted by the VPC link. Currently AWS only supports 1 target.
*/
public data class VpcLinkArgs(
public val description: Output? = null,
public val name: Output? = null,
public val tags: Output
© 2015 - 2024 Weber Informatics LLC | Privacy Policy