1. Packages
  2. Cloudamqp Provider
  3. API Docs
  4. getVpcGcpInfo
CloudAMQP v3.20.2 published on Tuesday, Oct 29, 2024 by Pulumi

cloudamqp.getVpcGcpInfo

Explore with Pulumi AI

cloudamqp logo
CloudAMQP v3.20.2 published on Tuesday, Oct 29, 2024 by Pulumi

    Use this data source to retrieve information about VPC for a CloudAMQP instance hosted in GCP.

    Example Usage

    AWS VPC peering pre v1.16.0
    import * as pulumi from "@pulumi/pulumi";
    import * as cloudamqp from "@pulumi/cloudamqp";
    
    const vpcInfo = cloudamqp.getVpcGcpInfo({
        instanceId: instance.id,
    });
    
    import pulumi
    import pulumi_cloudamqp as cloudamqp
    
    vpc_info = cloudamqp.get_vpc_gcp_info(instance_id=instance["id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-cloudamqp/sdk/v3/go/cloudamqp"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cloudamqp.GetVpcGcpInfo(ctx, &cloudamqp.GetVpcGcpInfoArgs{
    			InstanceId: pulumi.IntRef(instance.Id),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using CloudAmqp = Pulumi.CloudAmqp;
    
    return await Deployment.RunAsync(() => 
    {
        var vpcInfo = CloudAmqp.GetVpcGcpInfo.Invoke(new()
        {
            InstanceId = instance.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.cloudamqp.CloudamqpFunctions;
    import com.pulumi.cloudamqp.inputs.GetVpcGcpInfoArgs;
    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) {
            final var vpcInfo = CloudamqpFunctions.getVpcGcpInfo(GetVpcGcpInfoArgs.builder()
                .instanceId(instance.id())
                .build());
    
        }
    }
    
    variables:
      vpcInfo:
        fn::invoke:
          Function: cloudamqp:getVpcGcpInfo
          Arguments:
            instanceId: ${instance.id}
    
    AWS VPC peering post v1.16.0 (Managed VPC)
    import * as pulumi from "@pulumi/pulumi";
    import * as cloudamqp from "@pulumi/cloudamqp";
    
    const vpcInfo = cloudamqp.getVpcGcpInfo({
        vpcId: vpc.id,
    });
    
    import pulumi
    import pulumi_cloudamqp as cloudamqp
    
    vpc_info = cloudamqp.get_vpc_gcp_info(vpc_id=vpc["id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-cloudamqp/sdk/v3/go/cloudamqp"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cloudamqp.GetVpcGcpInfo(ctx, &cloudamqp.GetVpcGcpInfoArgs{
    			VpcId: pulumi.StringRef(vpc.Id),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using CloudAmqp = Pulumi.CloudAmqp;
    
    return await Deployment.RunAsync(() => 
    {
        var vpcInfo = CloudAmqp.GetVpcGcpInfo.Invoke(new()
        {
            VpcId = vpc.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.cloudamqp.CloudamqpFunctions;
    import com.pulumi.cloudamqp.inputs.GetVpcGcpInfoArgs;
    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) {
            final var vpcInfo = CloudamqpFunctions.getVpcGcpInfo(GetVpcGcpInfoArgs.builder()
                .vpcId(vpc.id())
                .build());
    
        }
    }
    
    variables:
      vpcInfo:
        fn::invoke:
          Function: cloudamqp:getVpcGcpInfo
          Arguments:
            vpcId: ${vpc.id}
    

    Attributes reference

    All attributes reference are computed

    • id - The identifier for this resource.
    • name - The name of the VPC.
    • vpc_subnet - Dedicated VPC subnet.
    • network - VPC network uri.

    Dependency

    Pre v1.16.0 This resource depends on CloudAMQP instance identifier, cloudamqp_instance.instance.id.

    Post v1.16.0 This resource depends on CloudAMQP managed VPC identifier, cloudamqp_vpc.vpc.id or instance identifier, cloudamqp_instance.instance.id.

    Using getVpcGcpInfo

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getVpcGcpInfo(args: GetVpcGcpInfoArgs, opts?: InvokeOptions): Promise<GetVpcGcpInfoResult>
    function getVpcGcpInfoOutput(args: GetVpcGcpInfoOutputArgs, opts?: InvokeOptions): Output<GetVpcGcpInfoResult>
    def get_vpc_gcp_info(instance_id: Optional[int] = None,
                         sleep: Optional[int] = None,
                         timeout: Optional[int] = None,
                         vpc_id: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetVpcGcpInfoResult
    def get_vpc_gcp_info_output(instance_id: Optional[pulumi.Input[int]] = None,
                         sleep: Optional[pulumi.Input[int]] = None,
                         timeout: Optional[pulumi.Input[int]] = None,
                         vpc_id: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetVpcGcpInfoResult]
    func GetVpcGcpInfo(ctx *Context, args *GetVpcGcpInfoArgs, opts ...InvokeOption) (*GetVpcGcpInfoResult, error)
    func GetVpcGcpInfoOutput(ctx *Context, args *GetVpcGcpInfoOutputArgs, opts ...InvokeOption) GetVpcGcpInfoResultOutput

    > Note: This function is named GetVpcGcpInfo in the Go SDK.

    public static class GetVpcGcpInfo 
    {
        public static Task<GetVpcGcpInfoResult> InvokeAsync(GetVpcGcpInfoArgs args, InvokeOptions? opts = null)
        public static Output<GetVpcGcpInfoResult> Invoke(GetVpcGcpInfoInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetVpcGcpInfoResult> getVpcGcpInfo(GetVpcGcpInfoArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: cloudamqp:index/getVpcGcpInfo:getVpcGcpInfo
      arguments:
        # arguments dictionary

    The following arguments are supported:

    InstanceId int

    The CloudAMQP instance identifier.

    Deprecated: Changed from required to optional in v1.16.0 will be removed in next major version (v2.0)

    Sleep int
    Configurable sleep time (seconds) between retries when reading peering. Default set to 10 seconds.
    Timeout int
    Configurable timeout time (seconds) before retries times out. Default set to 1800 seconds.
    VpcId string

    The managed VPC identifier.

    Note: Added as optional in version v1.16.0 and will be required in next major version (v2.0)

    InstanceId int

    The CloudAMQP instance identifier.

    Deprecated: Changed from required to optional in v1.16.0 will be removed in next major version (v2.0)

    Sleep int
    Configurable sleep time (seconds) between retries when reading peering. Default set to 10 seconds.
    Timeout int
    Configurable timeout time (seconds) before retries times out. Default set to 1800 seconds.
    VpcId string

    The managed VPC identifier.

    Note: Added as optional in version v1.16.0 and will be required in next major version (v2.0)

    instanceId Integer

    The CloudAMQP instance identifier.

    Deprecated: Changed from required to optional in v1.16.0 will be removed in next major version (v2.0)

    sleep Integer
    Configurable sleep time (seconds) between retries when reading peering. Default set to 10 seconds.
    timeout Integer
    Configurable timeout time (seconds) before retries times out. Default set to 1800 seconds.
    vpcId String

    The managed VPC identifier.

    Note: Added as optional in version v1.16.0 and will be required in next major version (v2.0)

    instanceId number

    The CloudAMQP instance identifier.

    Deprecated: Changed from required to optional in v1.16.0 will be removed in next major version (v2.0)

    sleep number
    Configurable sleep time (seconds) between retries when reading peering. Default set to 10 seconds.
    timeout number
    Configurable timeout time (seconds) before retries times out. Default set to 1800 seconds.
    vpcId string

    The managed VPC identifier.

    Note: Added as optional in version v1.16.0 and will be required in next major version (v2.0)

    instance_id int

    The CloudAMQP instance identifier.

    Deprecated: Changed from required to optional in v1.16.0 will be removed in next major version (v2.0)

    sleep int
    Configurable sleep time (seconds) between retries when reading peering. Default set to 10 seconds.
    timeout int
    Configurable timeout time (seconds) before retries times out. Default set to 1800 seconds.
    vpc_id str

    The managed VPC identifier.

    Note: Added as optional in version v1.16.0 and will be required in next major version (v2.0)

    instanceId Number

    The CloudAMQP instance identifier.

    Deprecated: Changed from required to optional in v1.16.0 will be removed in next major version (v2.0)

    sleep Number
    Configurable sleep time (seconds) between retries when reading peering. Default set to 10 seconds.
    timeout Number
    Configurable timeout time (seconds) before retries times out. Default set to 1800 seconds.
    vpcId String

    The managed VPC identifier.

    Note: Added as optional in version v1.16.0 and will be required in next major version (v2.0)

    getVpcGcpInfo Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    Network string
    VpcSubnet string
    InstanceId int
    Sleep int
    Timeout int
    VpcId string
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    Network string
    VpcSubnet string
    InstanceId int
    Sleep int
    Timeout int
    VpcId string
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    network String
    vpcSubnet String
    instanceId Integer
    sleep Integer
    timeout Integer
    vpcId String
    id string
    The provider-assigned unique ID for this managed resource.
    name string
    network string
    vpcSubnet string
    instanceId number
    sleep number
    timeout number
    vpcId string
    id str
    The provider-assigned unique ID for this managed resource.
    name str
    network str
    vpc_subnet str
    instance_id int
    sleep int
    timeout int
    vpc_id str
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    network String
    vpcSubnet String
    instanceId Number
    sleep Number
    timeout Number
    vpcId String

    Package Details

    Repository
    CloudAMQP pulumi/pulumi-cloudamqp
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the cloudamqp Terraform Provider.
    cloudamqp logo
    CloudAMQP v3.20.2 published on Tuesday, Oct 29, 2024 by Pulumi