1. Packages
  2. Event Store Cloud
  3. API Docs
  4. Peering
Event Store Cloud v0.2.10 published on Thursday, Aug 31, 2023 by EventStore

eventstorecloud.Peering

Explore with Pulumi AI

eventstorecloud logo
Event Store Cloud v0.2.10 published on Thursday, Aug 31, 2023 by EventStore

    Manages peering connections between Event Store Cloud VPCs and customer own VPCs

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using EventStoreCloud = Pulumi.EventStoreCloud;
    
    return await Deployment.RunAsync(() => 
    {
        // Example for AWS
        var exampleProject = new EventStoreCloud.Project("exampleProject");
    
        var exampleNetwork = new EventStoreCloud.Network("exampleNetwork", new()
        {
            ProjectId = exampleProject.Id,
            ResourceProvider = "aws",
            Region = "us-west-2",
            CidrBlock = "172.21.0.0/16",
        });
    
        var examplePeering = new EventStoreCloud.Peering("examplePeering", new()
        {
            ProjectId = exampleNetwork.ProjectId,
            NetworkId = exampleNetwork.Id,
            PeerResourceProvider = exampleNetwork.ResourceProvider,
            PeerNetworkRegion = exampleNetwork.Region,
            PeerAccountId = "<Customer AWS Account ID>",
            PeerNetworkId = "<Customer VPC ID>",
            Routes = new[]
            {
                "<Address space of the customer VPC>",
            },
        });
    
    });
    
    package main
    
    import (
    	"github.com/EventStore/pulumi-eventstorecloud/sdk/go/eventstorecloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		exampleProject, err := eventstorecloud.NewProject(ctx, "exampleProject", nil)
    		if err != nil {
    			return err
    		}
    		exampleNetwork, err := eventstorecloud.NewNetwork(ctx, "exampleNetwork", &eventstorecloud.NetworkArgs{
    			ProjectId:        exampleProject.ID(),
    			ResourceProvider: pulumi.String("aws"),
    			Region:           pulumi.String("us-west-2"),
    			CidrBlock:        pulumi.String("172.21.0.0/16"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = eventstorecloud.NewPeering(ctx, "examplePeering", &eventstorecloud.PeeringArgs{
    			ProjectId:            exampleNetwork.ProjectId,
    			NetworkId:            exampleNetwork.ID(),
    			PeerResourceProvider: exampleNetwork.ResourceProvider,
    			PeerNetworkRegion:    exampleNetwork.Region,
    			PeerAccountId:        pulumi.String("<Customer AWS Account ID>"),
    			PeerNetworkId:        pulumi.String("<Customer VPC ID>"),
    			Routes: pulumi.StringArray{
    				pulumi.String("<Address space of the customer VPC>"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.eventstorecloud.Project;
    import com.pulumi.eventstorecloud.Network;
    import com.pulumi.eventstorecloud.NetworkArgs;
    import com.pulumi.eventstorecloud.Peering;
    import com.pulumi.eventstorecloud.PeeringArgs;
    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 exampleProject = new Project("exampleProject");
    
            var exampleNetwork = new Network("exampleNetwork", NetworkArgs.builder()        
                .projectId(exampleProject.id())
                .resourceProvider("aws")
                .region("us-west-2")
                .cidrBlock("172.21.0.0/16")
                .build());
    
            var examplePeering = new Peering("examplePeering", PeeringArgs.builder()        
                .projectId(exampleNetwork.projectId())
                .networkId(exampleNetwork.id())
                .peerResourceProvider(exampleNetwork.resourceProvider())
                .peerNetworkRegion(exampleNetwork.region())
                .peerAccountId("<Customer AWS Account ID>")
                .peerNetworkId("<Customer VPC ID>")
                .routes("<Address space of the customer VPC>")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_eventstorecloud as eventstorecloud
    
    # Example for AWS
    example_project = eventstorecloud.Project("exampleProject")
    example_network = eventstorecloud.Network("exampleNetwork",
        project_id=example_project.id,
        resource_provider="aws",
        region="us-west-2",
        cidr_block="172.21.0.0/16")
    example_peering = eventstorecloud.Peering("examplePeering",
        project_id=example_network.project_id,
        network_id=example_network.id,
        peer_resource_provider=example_network.resource_provider,
        peer_network_region=example_network.region,
        peer_account_id="<Customer AWS Account ID>",
        peer_network_id="<Customer VPC ID>",
        routes=["<Address space of the customer VPC>"])
    
    import * as pulumi from "@pulumi/pulumi";
    import * as eventstorecloud from "@eventstore/pulumi-eventstorecloud";
    
    // Example for AWS
    const exampleProject = new eventstorecloud.Project("exampleProject", {});
    const exampleNetwork = new eventstorecloud.Network("exampleNetwork", {
        projectId: exampleProject.id,
        resourceProvider: "aws",
        region: "us-west-2",
        cidrBlock: "172.21.0.0/16",
    });
    const examplePeering = new eventstorecloud.Peering("examplePeering", {
        projectId: exampleNetwork.projectId,
        networkId: exampleNetwork.id,
        peerResourceProvider: exampleNetwork.resourceProvider,
        peerNetworkRegion: exampleNetwork.region,
        peerAccountId: "<Customer AWS Account ID>",
        peerNetworkId: "<Customer VPC ID>",
        routes: ["<Address space of the customer VPC>"],
    });
    
    resources:
      # Example for AWS
      exampleProject:
        type: eventstorecloud:Project
      exampleNetwork:
        type: eventstorecloud:Network
        properties:
          projectId: ${exampleProject.id}
          resourceProvider: aws
          region: us-west-2
          cidrBlock: 172.21.0.0/16
      examplePeering:
        type: eventstorecloud:Peering
        properties:
          projectId: ${exampleNetwork.projectId}
          networkId: ${exampleNetwork.id}
          peerResourceProvider: ${exampleNetwork.resourceProvider}
          peerNetworkRegion: ${exampleNetwork.region}
          peerAccountId: <Customer AWS Account ID>
          peerNetworkId: <Customer VPC ID>
          routes:
            - <Address space of the customer VPC>
    

    Create Peering Resource

    new Peering(name: string, args: PeeringArgs, opts?: CustomResourceOptions);
    @overload
    def Peering(resource_name: str,
                opts: Optional[ResourceOptions] = None,
                name: Optional[str] = None,
                network_id: Optional[str] = None,
                peer_account_id: Optional[str] = None,
                peer_network_id: Optional[str] = None,
                peer_network_region: Optional[str] = None,
                peer_resource_provider: Optional[str] = None,
                project_id: Optional[str] = None,
                routes: Optional[Sequence[str]] = None)
    @overload
    def Peering(resource_name: str,
                args: PeeringArgs,
                opts: Optional[ResourceOptions] = None)
    func NewPeering(ctx *Context, name string, args PeeringArgs, opts ...ResourceOption) (*Peering, error)
    public Peering(string name, PeeringArgs args, CustomResourceOptions? opts = null)
    public Peering(String name, PeeringArgs args)
    public Peering(String name, PeeringArgs args, CustomResourceOptions options)
    
    type: eventstorecloud:Peering
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args PeeringArgs
    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 PeeringArgs
    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 PeeringArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args PeeringArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args PeeringArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Peering Resource Properties

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

    Inputs

    The Peering resource accepts the following input properties:

    NetworkId string
    Network ID
    PeerAccountId string
    Account identifier in which to the peer network exists
    PeerNetworkId string
    Network identifier of the peer network exists
    PeerNetworkRegion string
    Provider region in which to the peer network exists
    PeerResourceProvider string
    Cloud Provider in which the target network exists
    ProjectId string
    Project ID
    Routes List<string>
    Routes to create from the Event Store network to the peer network
    Name string
    Human-friendly name for the network
    NetworkId string
    Network ID
    PeerAccountId string
    Account identifier in which to the peer network exists
    PeerNetworkId string
    Network identifier of the peer network exists
    PeerNetworkRegion string
    Provider region in which to the peer network exists
    PeerResourceProvider string
    Cloud Provider in which the target network exists
    ProjectId string
    Project ID
    Routes []string
    Routes to create from the Event Store network to the peer network
    Name string
    Human-friendly name for the network
    networkId String
    Network ID
    peerAccountId String
    Account identifier in which to the peer network exists
    peerNetworkId String
    Network identifier of the peer network exists
    peerNetworkRegion String
    Provider region in which to the peer network exists
    peerResourceProvider String
    Cloud Provider in which the target network exists
    projectId String
    Project ID
    routes List<String>
    Routes to create from the Event Store network to the peer network
    name String
    Human-friendly name for the network
    networkId string
    Network ID
    peerAccountId string
    Account identifier in which to the peer network exists
    peerNetworkId string
    Network identifier of the peer network exists
    peerNetworkRegion string
    Provider region in which to the peer network exists
    peerResourceProvider string
    Cloud Provider in which the target network exists
    projectId string
    Project ID
    routes string[]
    Routes to create from the Event Store network to the peer network
    name string
    Human-friendly name for the network
    network_id str
    Network ID
    peer_account_id str
    Account identifier in which to the peer network exists
    peer_network_id str
    Network identifier of the peer network exists
    peer_network_region str
    Provider region in which to the peer network exists
    peer_resource_provider str
    Cloud Provider in which the target network exists
    project_id str
    Project ID
    routes Sequence[str]
    Routes to create from the Event Store network to the peer network
    name str
    Human-friendly name for the network
    networkId String
    Network ID
    peerAccountId String
    Account identifier in which to the peer network exists
    peerNetworkId String
    Network identifier of the peer network exists
    peerNetworkRegion String
    Provider region in which to the peer network exists
    peerResourceProvider String
    Cloud Provider in which the target network exists
    projectId String
    Project ID
    routes List<String>
    Routes to create from the Event Store network to the peer network
    name String
    Human-friendly name for the network

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    ProviderMetadata Dictionary<string, string>
    Metadata about the remote end of the peering connection
    Id string
    The provider-assigned unique ID for this managed resource.
    ProviderMetadata map[string]string
    Metadata about the remote end of the peering connection
    id String
    The provider-assigned unique ID for this managed resource.
    providerMetadata Map<String,String>
    Metadata about the remote end of the peering connection
    id string
    The provider-assigned unique ID for this managed resource.
    providerMetadata {[key: string]: string}
    Metadata about the remote end of the peering connection
    id str
    The provider-assigned unique ID for this managed resource.
    provider_metadata Mapping[str, str]
    Metadata about the remote end of the peering connection
    id String
    The provider-assigned unique ID for this managed resource.
    providerMetadata Map<String>
    Metadata about the remote end of the peering connection

    Look up Existing Peering Resource

    Get an existing Peering 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?: PeeringState, opts?: CustomResourceOptions): Peering
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            name: Optional[str] = None,
            network_id: Optional[str] = None,
            peer_account_id: Optional[str] = None,
            peer_network_id: Optional[str] = None,
            peer_network_region: Optional[str] = None,
            peer_resource_provider: Optional[str] = None,
            project_id: Optional[str] = None,
            provider_metadata: Optional[Mapping[str, str]] = None,
            routes: Optional[Sequence[str]] = None) -> Peering
    func GetPeering(ctx *Context, name string, id IDInput, state *PeeringState, opts ...ResourceOption) (*Peering, error)
    public static Peering Get(string name, Input<string> id, PeeringState? state, CustomResourceOptions? opts = null)
    public static Peering get(String name, Output<String> id, PeeringState 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:
    Name string
    Human-friendly name for the network
    NetworkId string
    Network ID
    PeerAccountId string
    Account identifier in which to the peer network exists
    PeerNetworkId string
    Network identifier of the peer network exists
    PeerNetworkRegion string
    Provider region in which to the peer network exists
    PeerResourceProvider string
    Cloud Provider in which the target network exists
    ProjectId string
    Project ID
    ProviderMetadata Dictionary<string, string>
    Metadata about the remote end of the peering connection
    Routes List<string>
    Routes to create from the Event Store network to the peer network
    Name string
    Human-friendly name for the network
    NetworkId string
    Network ID
    PeerAccountId string
    Account identifier in which to the peer network exists
    PeerNetworkId string
    Network identifier of the peer network exists
    PeerNetworkRegion string
    Provider region in which to the peer network exists
    PeerResourceProvider string
    Cloud Provider in which the target network exists
    ProjectId string
    Project ID
    ProviderMetadata map[string]string
    Metadata about the remote end of the peering connection
    Routes []string
    Routes to create from the Event Store network to the peer network
    name String
    Human-friendly name for the network
    networkId String
    Network ID
    peerAccountId String
    Account identifier in which to the peer network exists
    peerNetworkId String
    Network identifier of the peer network exists
    peerNetworkRegion String
    Provider region in which to the peer network exists
    peerResourceProvider String
    Cloud Provider in which the target network exists
    projectId String
    Project ID
    providerMetadata Map<String,String>
    Metadata about the remote end of the peering connection
    routes List<String>
    Routes to create from the Event Store network to the peer network
    name string
    Human-friendly name for the network
    networkId string
    Network ID
    peerAccountId string
    Account identifier in which to the peer network exists
    peerNetworkId string
    Network identifier of the peer network exists
    peerNetworkRegion string
    Provider region in which to the peer network exists
    peerResourceProvider string
    Cloud Provider in which the target network exists
    projectId string
    Project ID
    providerMetadata {[key: string]: string}
    Metadata about the remote end of the peering connection
    routes string[]
    Routes to create from the Event Store network to the peer network
    name str
    Human-friendly name for the network
    network_id str
    Network ID
    peer_account_id str
    Account identifier in which to the peer network exists
    peer_network_id str
    Network identifier of the peer network exists
    peer_network_region str
    Provider region in which to the peer network exists
    peer_resource_provider str
    Cloud Provider in which the target network exists
    project_id str
    Project ID
    provider_metadata Mapping[str, str]
    Metadata about the remote end of the peering connection
    routes Sequence[str]
    Routes to create from the Event Store network to the peer network
    name String
    Human-friendly name for the network
    networkId String
    Network ID
    peerAccountId String
    Account identifier in which to the peer network exists
    peerNetworkId String
    Network identifier of the peer network exists
    peerNetworkRegion String
    Provider region in which to the peer network exists
    peerResourceProvider String
    Cloud Provider in which the target network exists
    projectId String
    Project ID
    providerMetadata Map<String>
    Metadata about the remote end of the peering connection
    routes List<String>
    Routes to create from the Event Store network to the peer network

    Import

     $ pulumi import eventstorecloud:index/peering:Peering example project_id:peering_id
    

    ~> Keep in mind that additional operations might be required to activate the peering link. Check our provisioning guidelines for each of the supported cloud providers to know more.

    Package Details

    Repository
    eventstorecloud EventStore/pulumi-eventstorecloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the eventstorecloud Terraform Provider.
    eventstorecloud logo
    Event Store Cloud v0.2.10 published on Thursday, Aug 31, 2023 by EventStore