ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud
ibm.getPiPlacementGroup
Explore with Pulumi AI
Retrieve information about a placement group. For more information, about placement groups, see Managing server placement groups.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ibm from "@pulumi/ibm";
const dsPlacementGroup = ibm.getPiPlacementGroup({
piCloudInstanceId: "49fba6c9-23f8-40bc-9899-aca322ee7d5b",
piPlacementGroupName: "my-pg",
});
import pulumi
import pulumi_ibm as ibm
ds_placement_group = ibm.get_pi_placement_group(pi_cloud_instance_id="49fba6c9-23f8-40bc-9899-aca322ee7d5b",
pi_placement_group_name="my-pg")
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.LookupPiPlacementGroup(ctx, &ibm.LookupPiPlacementGroupArgs{
PiCloudInstanceId: "49fba6c9-23f8-40bc-9899-aca322ee7d5b",
PiPlacementGroupName: "my-pg",
}, 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 dsPlacementGroup = Ibm.GetPiPlacementGroup.Invoke(new()
{
PiCloudInstanceId = "49fba6c9-23f8-40bc-9899-aca322ee7d5b",
PiPlacementGroupName = "my-pg",
});
});
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.GetPiPlacementGroupArgs;
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 dsPlacementGroup = IbmFunctions.getPiPlacementGroup(GetPiPlacementGroupArgs.builder()
.piCloudInstanceId("49fba6c9-23f8-40bc-9899-aca322ee7d5b")
.piPlacementGroupName("my-pg")
.build());
}
}
variables:
dsPlacementGroup:
fn::invoke:
function: ibm:getPiPlacementGroup
arguments:
piCloudInstanceId: 49fba6c9-23f8-40bc-9899-aca322ee7d5b
piPlacementGroupName: my-pg
Notes
- Please find supported Regions for endpoints.
- If a Power cloud instance is provisioned at
lon04
, The provider level attributes should be as follows:region
-lon
zone
-lon04
Example usage:
import * as pulumi from "@pulumi/pulumi";
import pulumi
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
return await Deployment.RunAsync(() =>
{
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
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) {
}
}
{}
Using getPiPlacementGroup
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 getPiPlacementGroup(args: GetPiPlacementGroupArgs, opts?: InvokeOptions): Promise<GetPiPlacementGroupResult>
function getPiPlacementGroupOutput(args: GetPiPlacementGroupOutputArgs, opts?: InvokeOptions): Output<GetPiPlacementGroupResult>
def get_pi_placement_group(id: Optional[str] = None,
pi_cloud_instance_id: Optional[str] = None,
pi_placement_group_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetPiPlacementGroupResult
def get_pi_placement_group_output(id: Optional[pulumi.Input[str]] = None,
pi_cloud_instance_id: Optional[pulumi.Input[str]] = None,
pi_placement_group_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetPiPlacementGroupResult]
func LookupPiPlacementGroup(ctx *Context, args *LookupPiPlacementGroupArgs, opts ...InvokeOption) (*LookupPiPlacementGroupResult, error)
func LookupPiPlacementGroupOutput(ctx *Context, args *LookupPiPlacementGroupOutputArgs, opts ...InvokeOption) LookupPiPlacementGroupResultOutput
> Note: This function is named LookupPiPlacementGroup
in the Go SDK.
public static class GetPiPlacementGroup
{
public static Task<GetPiPlacementGroupResult> InvokeAsync(GetPiPlacementGroupArgs args, InvokeOptions? opts = null)
public static Output<GetPiPlacementGroupResult> Invoke(GetPiPlacementGroupInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetPiPlacementGroupResult> getPiPlacementGroup(GetPiPlacementGroupArgs args, InvokeOptions options)
public static Output<GetPiPlacementGroupResult> getPiPlacementGroup(GetPiPlacementGroupArgs args, InvokeOptions options)
fn::invoke:
function: ibm:index/getPiPlacementGroup:getPiPlacementGroup
arguments:
# arguments dictionary
The following arguments are supported:
- Pi
Cloud stringInstance Id - The GUID of the service instance associated with an account.
- Pi
Placement stringGroup Name - The name of the placement group.
- Id string
- (String) The ID of the placement group.
- Pi
Cloud stringInstance Id - The GUID of the service instance associated with an account.
- Pi
Placement stringGroup Name - The name of the placement group.
- Id string
- (String) The ID of the placement group.
- pi
Cloud StringInstance Id - The GUID of the service instance associated with an account.
- pi
Placement StringGroup Name - The name of the placement group.
- id String
- (String) The ID of the placement group.
- pi
Cloud stringInstance Id - The GUID of the service instance associated with an account.
- pi
Placement stringGroup Name - The name of the placement group.
- id string
- (String) The ID of the placement group.
- pi_
cloud_ strinstance_ id - The GUID of the service instance associated with an account.
- pi_
placement_ strgroup_ name - The name of the placement group.
- id str
- (String) The ID of the placement group.
- pi
Cloud StringInstance Id - The GUID of the service instance associated with an account.
- pi
Placement StringGroup Name - The name of the placement group.
- id String
- (String) The ID of the placement group.
getPiPlacementGroup Result
The following output properties are available:
- Id string
- (String) The ID of the placement group.
- Members List<string>
- (List) List of server instances IDs that are members of the placement group.
- Pi
Cloud stringInstance Id - Pi
Placement stringGroup Name - Policy string
- (String) The value of the group's affinity policy. Valid values are affinity and anti-affinity.
- Id string
- (String) The ID of the placement group.
- Members []string
- (List) List of server instances IDs that are members of the placement group.
- Pi
Cloud stringInstance Id - Pi
Placement stringGroup Name - Policy string
- (String) The value of the group's affinity policy. Valid values are affinity and anti-affinity.
- id String
- (String) The ID of the placement group.
- members List<String>
- (List) List of server instances IDs that are members of the placement group.
- pi
Cloud StringInstance Id - pi
Placement StringGroup Name - policy String
- (String) The value of the group's affinity policy. Valid values are affinity and anti-affinity.
- id string
- (String) The ID of the placement group.
- members string[]
- (List) List of server instances IDs that are members of the placement group.
- pi
Cloud stringInstance Id - pi
Placement stringGroup Name - policy string
- (String) The value of the group's affinity policy. Valid values are affinity and anti-affinity.
- id str
- (String) The ID of the placement group.
- members Sequence[str]
- (List) List of server instances IDs that are members of the placement group.
- pi_
cloud_ strinstance_ id - pi_
placement_ strgroup_ name - policy str
- (String) The value of the group's affinity policy. Valid values are affinity and anti-affinity.
- id String
- (String) The ID of the placement group.
- members List<String>
- (List) List of server instances IDs that are members of the placement group.
- pi
Cloud StringInstance Id - pi
Placement StringGroup Name - policy String
- (String) The value of the group's affinity policy. Valid values are affinity and anti-affinity.
Package Details
- Repository
- ibm ibm-cloud/terraform-provider-ibm
- License
- Notes
- This Pulumi package is based on the
ibm
Terraform Provider.