Ready to level-up your engineering skills? Join a Pulumi Workshop. Register Now

VpcPeeringConnection

# VPC Peering Connection Resource

The VPC Peering Connection resource allows the creation and management of Aiven VPC Peering Connections.

Example Usage

using Pulumi;
using Aiven = Pulumi.Aiven;

class MyStack : Stack
{
    public MyStack()
    {
        var mypeeringconnection = new Aiven.VpcPeeringConnection("mypeeringconnection", new Aiven.VpcPeeringConnectionArgs
        {
            PeerCloudAccount = "<PEER_ACCOUNT_ID>",
            PeerRegion = "<PEER_REGION>",
            PeerVpc = "<PEER_VPC_ID/NAME>",
            VpcId = aiven_project_vpc.Myvpc.Id,
        });
    }

}
package main

import (
    "github.com/pulumi/pulumi-aiven/sdk/v3/go/aiven"
    "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
    pulumi.Run(func(ctx *pulumi.Context) error {
        _, err := aiven.NewVpcPeeringConnection(ctx, "mypeeringconnection", &aiven.VpcPeeringConnectionArgs{
            PeerCloudAccount: pulumi.String("<PEER_ACCOUNT_ID>"),
            PeerRegion:       pulumi.String("<PEER_REGION>"),
            PeerVpc:          pulumi.String("<PEER_VPC_ID/NAME>"),
            VpcId:            pulumi.Any(aiven_project_vpc.Myvpc.Id),
        })
        if err != nil {
            return err
        }
        return nil
    })
}
import pulumi
import pulumi_aiven as aiven

mypeeringconnection = aiven.VpcPeeringConnection("mypeeringconnection",
    peer_cloud_account="<PEER_ACCOUNT_ID>",
    peer_region="<PEER_REGION>",
    peer_vpc="<PEER_VPC_ID/NAME>",
    vpc_id=aiven_project_vpc["myvpc"]["id"])
import * as pulumi from "@pulumi/pulumi";
import * as aiven from "@pulumi/aiven";

const mypeeringconnection = new aiven.VpcPeeringConnection("mypeeringconnection", {
    peerCloudAccount: "<PEER_ACCOUNT_ID>",
    peerRegion: "<PEER_REGION>",
    peerVpc: "<PEER_VPC_ID/NAME>",
    vpcId: aiven_project_vpc_myvpc.id,
}, { timeouts: {
    create: "10m",
} });

Create a VpcPeeringConnection Resource

new VpcPeeringConnection(name: string, args: VpcPeeringConnectionArgs, opts?: CustomResourceOptions);
def VpcPeeringConnection(resource_name: str, opts: Optional[ResourceOptions] = None, peer_azure_app_id: Optional[str] = None, peer_azure_tenant_id: Optional[str] = None, peer_cloud_account: Optional[str] = None, peer_region: Optional[str] = None, peer_resource_group: Optional[str] = None, peer_vpc: Optional[str] = None, vpc_id: Optional[str] = None)
func NewVpcPeeringConnection(ctx *Context, name string, args VpcPeeringConnectionArgs, opts ...ResourceOption) (*VpcPeeringConnection, error)
public VpcPeeringConnection(string name, VpcPeeringConnectionArgs args, CustomResourceOptions? opts = null)
name string
The unique name of the resource.
args VpcPeeringConnectionArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
opts ResourceOptions
A bag of options that control this resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args VpcPeeringConnectionArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args VpcPeeringConnectionArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

VpcPeeringConnection Resource Properties

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

Inputs

The VpcPeeringConnection resource accepts the following input properties:

PeerCloudAccount string

defines the identifier of the cloud account the VPC is being peered with.

PeerVpc string

defines the identifier or name of the remote VPC.

VpcId string

is the Aiven VPC the peering connection is associated with.

PeerAzureAppId string

an Azure app registration id in UUID4 form that is allowed to create a peering to the peer vnet.

PeerAzureTenantId string

an Azure tenant id in UUID4 form.

PeerRegion string

defines the region of the remote VPC if it is not in the same region as Aiven VPC.

PeerResourceGroup string

an Azure resource group name of the peered VPC.

PeerCloudAccount string

defines the identifier of the cloud account the VPC is being peered with.

PeerVpc string

defines the identifier or name of the remote VPC.

VpcId string

is the Aiven VPC the peering connection is associated with.

PeerAzureAppId string

an Azure app registration id in UUID4 form that is allowed to create a peering to the peer vnet.

PeerAzureTenantId string

an Azure tenant id in UUID4 form.

PeerRegion string

defines the region of the remote VPC if it is not in the same region as Aiven VPC.

PeerResourceGroup string

an Azure resource group name of the peered VPC.

peerCloudAccount string

defines the identifier of the cloud account the VPC is being peered with.

peerVpc string

defines the identifier or name of the remote VPC.

vpcId string

is the Aiven VPC the peering connection is associated with.

peerAzureAppId string

an Azure app registration id in UUID4 form that is allowed to create a peering to the peer vnet.

peerAzureTenantId string

an Azure tenant id in UUID4 form.

peerRegion string

defines the region of the remote VPC if it is not in the same region as Aiven VPC.

peerResourceGroup string

an Azure resource group name of the peered VPC.

peer_cloud_account str

defines the identifier of the cloud account the VPC is being peered with.

peer_vpc str

defines the identifier or name of the remote VPC.

vpc_id str

is the Aiven VPC the peering connection is associated with.

peer_azure_app_id str

an Azure app registration id in UUID4 form that is allowed to create a peering to the peer vnet.

peer_azure_tenant_id str

an Azure tenant id in UUID4 form.

peer_region str

defines the region of the remote VPC if it is not in the same region as Aiven VPC.

peer_resource_group str

an Azure resource group name of the peered VPC.

Outputs

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

Id string
The provider-assigned unique ID for this managed resource.
PeeringConnectionId string

a cloud provider identifier for the peering connection if available.

State string

is the state of the peering connection. This property is computed by Aiven therefore cannot be set, only read. Where state can be one of: APPROVED, PENDING_PEER, ACTIVE, DELETED, DELETED_BY_PEER, REJECTED_BY_PEER and INVALID_SPECIFICATION.

StateInfo Dictionary<string, object>

state-specific help or error information.

Id string
The provider-assigned unique ID for this managed resource.
PeeringConnectionId string

a cloud provider identifier for the peering connection if available.

State string

is the state of the peering connection. This property is computed by Aiven therefore cannot be set, only read. Where state can be one of: APPROVED, PENDING_PEER, ACTIVE, DELETED, DELETED_BY_PEER, REJECTED_BY_PEER and INVALID_SPECIFICATION.

StateInfo map[string]interface{}

state-specific help or error information.

id string
The provider-assigned unique ID for this managed resource.
peeringConnectionId string

a cloud provider identifier for the peering connection if available.

state string

is the state of the peering connection. This property is computed by Aiven therefore cannot be set, only read. Where state can be one of: APPROVED, PENDING_PEER, ACTIVE, DELETED, DELETED_BY_PEER, REJECTED_BY_PEER and INVALID_SPECIFICATION.

stateInfo {[key: string]: any}

state-specific help or error information.

id str
The provider-assigned unique ID for this managed resource.
peering_connection_id str

a cloud provider identifier for the peering connection if available.

state str

is the state of the peering connection. This property is computed by Aiven therefore cannot be set, only read. Where state can be one of: APPROVED, PENDING_PEER, ACTIVE, DELETED, DELETED_BY_PEER, REJECTED_BY_PEER and INVALID_SPECIFICATION.

state_info Mapping[str, Any]

state-specific help or error information.

Look up an Existing VpcPeeringConnection Resource

Get an existing VpcPeeringConnection 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?: VpcPeeringConnectionState, opts?: CustomResourceOptions): VpcPeeringConnection
@staticmethod
def get(resource_name: str, id: str, opts: Optional[ResourceOptions] = None, peer_azure_app_id: Optional[str] = None, peer_azure_tenant_id: Optional[str] = None, peer_cloud_account: Optional[str] = None, peer_region: Optional[str] = None, peer_resource_group: Optional[str] = None, peer_vpc: Optional[str] = None, peering_connection_id: Optional[str] = None, state: Optional[str] = None, state_info: Optional[Mapping[str, Any]] = None, vpc_id: Optional[str] = None) -> VpcPeeringConnection
func GetVpcPeeringConnection(ctx *Context, name string, id IDInput, state *VpcPeeringConnectionState, opts ...ResourceOption) (*VpcPeeringConnection, error)
public static VpcPeeringConnection Get(string name, Input<string> id, VpcPeeringConnectionState? state, CustomResourceOptions? opts = null)
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.

The following state arguments are supported:

PeerAzureAppId string

an Azure app registration id in UUID4 form that is allowed to create a peering to the peer vnet.

PeerAzureTenantId string

an Azure tenant id in UUID4 form.

PeerCloudAccount string

defines the identifier of the cloud account the VPC is being peered with.

PeerRegion string

defines the region of the remote VPC if it is not in the same region as Aiven VPC.

PeerResourceGroup string

an Azure resource group name of the peered VPC.

PeerVpc string

defines the identifier or name of the remote VPC.

PeeringConnectionId string

a cloud provider identifier for the peering connection if available.

State string

is the state of the peering connection. This property is computed by Aiven therefore cannot be set, only read. Where state can be one of: APPROVED, PENDING_PEER, ACTIVE, DELETED, DELETED_BY_PEER, REJECTED_BY_PEER and INVALID_SPECIFICATION.

StateInfo Dictionary<string, object>

state-specific help or error information.

VpcId string

is the Aiven VPC the peering connection is associated with.

PeerAzureAppId string

an Azure app registration id in UUID4 form that is allowed to create a peering to the peer vnet.

PeerAzureTenantId string

an Azure tenant id in UUID4 form.

PeerCloudAccount string

defines the identifier of the cloud account the VPC is being peered with.

PeerRegion string

defines the region of the remote VPC if it is not in the same region as Aiven VPC.

PeerResourceGroup string

an Azure resource group name of the peered VPC.

PeerVpc string

defines the identifier or name of the remote VPC.

PeeringConnectionId string

a cloud provider identifier for the peering connection if available.

State string

is the state of the peering connection. This property is computed by Aiven therefore cannot be set, only read. Where state can be one of: APPROVED, PENDING_PEER, ACTIVE, DELETED, DELETED_BY_PEER, REJECTED_BY_PEER and INVALID_SPECIFICATION.

StateInfo map[string]interface{}

state-specific help or error information.

VpcId string

is the Aiven VPC the peering connection is associated with.

peerAzureAppId string

an Azure app registration id in UUID4 form that is allowed to create a peering to the peer vnet.

peerAzureTenantId string

an Azure tenant id in UUID4 form.

peerCloudAccount string

defines the identifier of the cloud account the VPC is being peered with.

peerRegion string

defines the region of the remote VPC if it is not in the same region as Aiven VPC.

peerResourceGroup string

an Azure resource group name of the peered VPC.

peerVpc string

defines the identifier or name of the remote VPC.

peeringConnectionId string

a cloud provider identifier for the peering connection if available.

state string

is the state of the peering connection. This property is computed by Aiven therefore cannot be set, only read. Where state can be one of: APPROVED, PENDING_PEER, ACTIVE, DELETED, DELETED_BY_PEER, REJECTED_BY_PEER and INVALID_SPECIFICATION.

stateInfo {[key: string]: any}

state-specific help or error information.

vpcId string

is the Aiven VPC the peering connection is associated with.

peer_azure_app_id str

an Azure app registration id in UUID4 form that is allowed to create a peering to the peer vnet.

peer_azure_tenant_id str

an Azure tenant id in UUID4 form.

peer_cloud_account str

defines the identifier of the cloud account the VPC is being peered with.

peer_region str

defines the region of the remote VPC if it is not in the same region as Aiven VPC.

peer_resource_group str

an Azure resource group name of the peered VPC.

peer_vpc str

defines the identifier or name of the remote VPC.

peering_connection_id str

a cloud provider identifier for the peering connection if available.

state str

is the state of the peering connection. This property is computed by Aiven therefore cannot be set, only read. Where state can be one of: APPROVED, PENDING_PEER, ACTIVE, DELETED, DELETED_BY_PEER, REJECTED_BY_PEER and INVALID_SPECIFICATION.

state_info Mapping[str, Any]

state-specific help or error information.

vpc_id str

is the Aiven VPC the peering connection is associated with.

Package Details

Repository
https://github.com/pulumi/pulumi-aiven
License
Apache-2.0
Notes
This Pulumi package is based on the aiven Terraform Provider.