1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Core
  5. getCrossConnectLocations
Oracle Cloud Infrastructure v1.31.0 published on Wednesday, Apr 10, 2024 by Pulumi

oci.Core.getCrossConnectLocations

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v1.31.0 published on Wednesday, Apr 10, 2024 by Pulumi

    This data source provides the list of Cross Connect Locations in Oracle Cloud Infrastructure Core service.

    Lists the available FastConnect locations for cross-connect installation. You need this information so you can specify your desired location when you create a cross-connect.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testCrossConnectLocations = oci.Core.getCrossConnectLocations({
        compartmentId: _var.compartment_id,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_cross_connect_locations = oci.Core.get_cross_connect_locations(compartment_id=var["compartment_id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/go/oci/Core"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Core.GetCrossConnectLocations(ctx, &core.GetCrossConnectLocationsArgs{
    			CompartmentId: _var.Compartment_id,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testCrossConnectLocations = Oci.Core.GetCrossConnectLocations.Invoke(new()
        {
            CompartmentId = @var.Compartment_id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Core.CoreFunctions;
    import com.pulumi.oci.Core.inputs.GetCrossConnectLocationsArgs;
    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 testCrossConnectLocations = CoreFunctions.getCrossConnectLocations(GetCrossConnectLocationsArgs.builder()
                .compartmentId(var_.compartment_id())
                .build());
    
        }
    }
    
    variables:
      testCrossConnectLocations:
        fn::invoke:
          Function: oci:Core:getCrossConnectLocations
          Arguments:
            compartmentId: ${var.compartment_id}
    

    Using getCrossConnectLocations

    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 getCrossConnectLocations(args: GetCrossConnectLocationsArgs, opts?: InvokeOptions): Promise<GetCrossConnectLocationsResult>
    function getCrossConnectLocationsOutput(args: GetCrossConnectLocationsOutputArgs, opts?: InvokeOptions): Output<GetCrossConnectLocationsResult>
    def get_cross_connect_locations(compartment_id: Optional[str] = None,
                                    filters: Optional[Sequence[_core.GetCrossConnectLocationsFilter]] = None,
                                    opts: Optional[InvokeOptions] = None) -> GetCrossConnectLocationsResult
    def get_cross_connect_locations_output(compartment_id: Optional[pulumi.Input[str]] = None,
                                    filters: Optional[pulumi.Input[Sequence[pulumi.Input[_core.GetCrossConnectLocationsFilterArgs]]]] = None,
                                    opts: Optional[InvokeOptions] = None) -> Output[GetCrossConnectLocationsResult]
    func GetCrossConnectLocations(ctx *Context, args *GetCrossConnectLocationsArgs, opts ...InvokeOption) (*GetCrossConnectLocationsResult, error)
    func GetCrossConnectLocationsOutput(ctx *Context, args *GetCrossConnectLocationsOutputArgs, opts ...InvokeOption) GetCrossConnectLocationsResultOutput

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

    public static class GetCrossConnectLocations 
    {
        public static Task<GetCrossConnectLocationsResult> InvokeAsync(GetCrossConnectLocationsArgs args, InvokeOptions? opts = null)
        public static Output<GetCrossConnectLocationsResult> Invoke(GetCrossConnectLocationsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetCrossConnectLocationsResult> getCrossConnectLocations(GetCrossConnectLocationsArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:Core/getCrossConnectLocations:getCrossConnectLocations
      arguments:
        # arguments dictionary

    The following arguments are supported:

    compartmentId String
    The OCID of the compartment.
    filters List<Property Map>

    getCrossConnectLocations Result

    The following output properties are available:

    CompartmentId string
    CrossConnectLocations List<GetCrossConnectLocationsCrossConnectLocation>
    The list of cross_connect_locations.
    Id string
    The provider-assigned unique ID for this managed resource.
    Filters List<GetCrossConnectLocationsFilter>
    CompartmentId string
    CrossConnectLocations []GetCrossConnectLocationsCrossConnectLocation
    The list of cross_connect_locations.
    Id string
    The provider-assigned unique ID for this managed resource.
    Filters []GetCrossConnectLocationsFilter
    compartmentId String
    crossConnectLocations List<GetCrossConnectLocationsCrossConnectLocation>
    The list of cross_connect_locations.
    id String
    The provider-assigned unique ID for this managed resource.
    filters List<GetCrossConnectLocationsFilter>
    compartmentId string
    crossConnectLocations GetCrossConnectLocationsCrossConnectLocation[]
    The list of cross_connect_locations.
    id string
    The provider-assigned unique ID for this managed resource.
    filters GetCrossConnectLocationsFilter[]
    compartment_id str
    cross_connect_locations Sequence[core.GetCrossConnectLocationsCrossConnectLocation]
    The list of cross_connect_locations.
    id str
    The provider-assigned unique ID for this managed resource.
    filters Sequence[core.GetCrossConnectLocationsFilter]
    compartmentId String
    crossConnectLocations List<Property Map>
    The list of cross_connect_locations.
    id String
    The provider-assigned unique ID for this managed resource.
    filters List<Property Map>

    Supporting Types

    GetCrossConnectLocationsCrossConnectLocation

    Description string
    A description of the location.
    Name string
    The name of the location. Example: CyrusOne, Chandler, AZ
    Description string
    A description of the location.
    Name string
    The name of the location. Example: CyrusOne, Chandler, AZ
    description String
    A description of the location.
    name String
    The name of the location. Example: CyrusOne, Chandler, AZ
    description string
    A description of the location.
    name string
    The name of the location. Example: CyrusOne, Chandler, AZ
    description str
    A description of the location.
    name str
    The name of the location. Example: CyrusOne, Chandler, AZ
    description String
    A description of the location.
    name String
    The name of the location. Example: CyrusOne, Chandler, AZ

    GetCrossConnectLocationsFilter

    Name string
    The name of the location. Example: CyrusOne, Chandler, AZ
    Values List<string>
    Regex bool
    Name string
    The name of the location. Example: CyrusOne, Chandler, AZ
    Values []string
    Regex bool
    name String
    The name of the location. Example: CyrusOne, Chandler, AZ
    values List<String>
    regex Boolean
    name string
    The name of the location. Example: CyrusOne, Chandler, AZ
    values string[]
    regex boolean
    name str
    The name of the location. Example: CyrusOne, Chandler, AZ
    values Sequence[str]
    regex bool
    name String
    The name of the location. Example: CyrusOne, Chandler, AZ
    values List<String>
    regex Boolean

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo
    Oracle Cloud Infrastructure v1.31.0 published on Wednesday, Apr 10, 2024 by Pulumi