ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud
ibm.getTgLocation
Explore with Pulumi AI
Retreive information of an existing IBM Cloud infrastructure transit location as a read only data source. For more information, about transit location, see about IBM Cloud Transit Gateway.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ibm from "@pulumi/ibm";
const dsTgLocation = ibm.getTgLocation({
name: "us-south",
});
import pulumi
import pulumi_ibm as ibm
ds_tg_location = ibm.get_tg_location(name="us-south")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ibm.GetTgLocation(ctx, &ibm.GetTgLocationArgs{
Name: "us-south",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ibm = Pulumi.Ibm;
return await Deployment.RunAsync(() =>
{
var dsTgLocation = Ibm.GetTgLocation.Invoke(new()
{
Name = "us-south",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ibm.IbmFunctions;
import com.pulumi.ibm.inputs.GetTgLocationArgs;
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 dsTgLocation = IbmFunctions.getTgLocation(GetTgLocationArgs.builder()
.name("us-south")
.build());
}
}
variables:
dsTgLocation:
fn::invoke:
function: ibm:getTgLocation
arguments:
name: us-south
Using getTgLocation
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 getTgLocation(args: GetTgLocationArgs, opts?: InvokeOptions): Promise<GetTgLocationResult>
function getTgLocationOutput(args: GetTgLocationOutputArgs, opts?: InvokeOptions): Output<GetTgLocationResult>
def get_tg_location(id: Optional[str] = None,
name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetTgLocationResult
def get_tg_location_output(id: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetTgLocationResult]
func GetTgLocation(ctx *Context, args *GetTgLocationArgs, opts ...InvokeOption) (*GetTgLocationResult, error)
func GetTgLocationOutput(ctx *Context, args *GetTgLocationOutputArgs, opts ...InvokeOption) GetTgLocationResultOutput
> Note: This function is named GetTgLocation
in the Go SDK.
public static class GetTgLocation
{
public static Task<GetTgLocationResult> InvokeAsync(GetTgLocationArgs args, InvokeOptions? opts = null)
public static Output<GetTgLocationResult> Invoke(GetTgLocationInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetTgLocationResult> getTgLocation(GetTgLocationArgs args, InvokeOptions options)
public static Output<GetTgLocationResult> getTgLocation(GetTgLocationArgs args, InvokeOptions options)
fn::invoke:
function: ibm:index/getTgLocation:getTgLocation
arguments:
# arguments dictionary
The following arguments are supported:
getTgLocation Result
The following output properties are available:
- Billing
Location string - (String) The geographical location of the location, used for billing purposes.
- Id string
- Local
Connection List<GetLocations Tg Location Local Connection Location> - (String) The set of network locations that are considered local for the transit gateway location.
- Name string
- (String) The name of the location.
- Type string
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- Billing
Location string - (String) The geographical location of the location, used for billing purposes.
- Id string
- Local
Connection []GetLocations Tg Location Local Connection Location - (String) The set of network locations that are considered local for the transit gateway location.
- Name string
- (String) The name of the location.
- Type string
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- billing
Location String - (String) The geographical location of the location, used for billing purposes.
- id String
- local
Connection List<GetLocations Tg Location Local Connection Location> - (String) The set of network locations that are considered local for the transit gateway location.
- name String
- (String) The name of the location.
- type String
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- billing
Location string - (String) The geographical location of the location, used for billing purposes.
- id string
- local
Connection GetLocations Tg Location Local Connection Location[] - (String) The set of network locations that are considered local for the transit gateway location.
- name string
- (String) The name of the location.
- type string
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- billing_
location str - (String) The geographical location of the location, used for billing purposes.
- id str
- local_
connection_ Sequence[Getlocations Tg Location Local Connection Location] - (String) The set of network locations that are considered local for the transit gateway location.
- name str
- (String) The name of the location.
- type str
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- billing
Location String - (String) The geographical location of the location, used for billing purposes.
- id String
- local
Connection List<Property Map>Locations - (String) The set of network locations that are considered local for the transit gateway location.
- name String
- (String) The name of the location.
- type String
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
Supporting Types
GetTgLocationLocalConnectionLocation
- Display
Name string - (String) The descriptive display name for the location.
- Name string
- The name of the transit gateway location.
- Type string
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- Display
Name string - (String) The descriptive display name for the location.
- Name string
- The name of the transit gateway location.
- Type string
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- display
Name String - (String) The descriptive display name for the location.
- name String
- The name of the transit gateway location.
- type String
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- display
Name string - (String) The descriptive display name for the location.
- name string
- The name of the transit gateway location.
- type string
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- display_
name str - (String) The descriptive display name for the location.
- name str
- The name of the transit gateway location.
- type str
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
- display
Name String - (String) The descriptive display name for the location.
- name String
- The name of the transit gateway location.
- type String
- (String) The type of the location, determining a
multi-zone region
, asingle data center
, or apoint of presence
.
Package Details
- Repository
- ibm ibm-cloud/terraform-provider-ibm
- License
- Notes
- This Pulumi package is based on the
ibm
Terraform Provider.