1. Packages
  2. Ibm Provider
  3. API Docs
  4. getIsPlacementGroups
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

ibm.getIsPlacementGroups

Explore with Pulumi AI

ibm logo
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

    Retrieve information of a placement groups as a read-only data source. For more information, about placement groups, see managing placement groups.

    Note: VPC infrastructure services are a regional specific based endpoint, by default targets to us-south. Please make sure to target right region in the provider block as shown in the provider.tf file, if VPC service is created in region other than us-south.

    provider.tf

    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) {
        }
    }
    
    {}
    

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ibm from "@pulumi/ibm";
    
    const example = ibm.getIsPlacementGroups({});
    
    import pulumi
    import pulumi_ibm as ibm
    
    example = ibm.get_is_placement_groups()
    
    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.GetIsPlacementGroups(ctx, &ibm.GetIsPlacementGroupsArgs{}, 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 example = Ibm.GetIsPlacementGroups.Invoke();
    
    });
    
    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.GetIsPlacementGroupsArgs;
    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 example = IbmFunctions.getIsPlacementGroups();
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: ibm:getIsPlacementGroups
          arguments: {}
    

    Using getIsPlacementGroups

    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 getIsPlacementGroups(args: GetIsPlacementGroupsArgs, opts?: InvokeOptions): Promise<GetIsPlacementGroupsResult>
    function getIsPlacementGroupsOutput(args: GetIsPlacementGroupsOutputArgs, opts?: InvokeOptions): Output<GetIsPlacementGroupsResult>
    def get_is_placement_groups(id: Optional[str] = None,
                                opts: Optional[InvokeOptions] = None) -> GetIsPlacementGroupsResult
    def get_is_placement_groups_output(id: Optional[pulumi.Input[str]] = None,
                                opts: Optional[InvokeOptions] = None) -> Output[GetIsPlacementGroupsResult]
    func GetIsPlacementGroups(ctx *Context, args *GetIsPlacementGroupsArgs, opts ...InvokeOption) (*GetIsPlacementGroupsResult, error)
    func GetIsPlacementGroupsOutput(ctx *Context, args *GetIsPlacementGroupsOutputArgs, opts ...InvokeOption) GetIsPlacementGroupsResultOutput

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

    public static class GetIsPlacementGroups 
    {
        public static Task<GetIsPlacementGroupsResult> InvokeAsync(GetIsPlacementGroupsArgs args, InvokeOptions? opts = null)
        public static Output<GetIsPlacementGroupsResult> Invoke(GetIsPlacementGroupsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetIsPlacementGroupsResult> getIsPlacementGroups(GetIsPlacementGroupsArgs args, InvokeOptions options)
    public static Output<GetIsPlacementGroupsResult> getIsPlacementGroups(GetIsPlacementGroupsArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ibm:index/getIsPlacementGroups:getIsPlacementGroups
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id string
    The unique identifier for this placement group.
    Id string
    The unique identifier for this placement group.
    id String
    The unique identifier for this placement group.
    id string
    The unique identifier for this placement group.
    id str
    The unique identifier for this placement group.
    id String
    The unique identifier for this placement group.

    getIsPlacementGroups Result

    The following output properties are available:

    Id string
    The unique identifier for this placement group.
    PlacementGroups List<GetIsPlacementGroupsPlacementGroup>
    Collection of placement groups. Nested placement_groups blocks have the following structure:
    TotalCount double
    The total number of resources across all pages.
    Id string
    The unique identifier for this placement group.
    PlacementGroups []GetIsPlacementGroupsPlacementGroup
    Collection of placement groups. Nested placement_groups blocks have the following structure:
    TotalCount float64
    The total number of resources across all pages.
    id String
    The unique identifier for this placement group.
    placementGroups List<GetIsPlacementGroupsPlacementGroup>
    Collection of placement groups. Nested placement_groups blocks have the following structure:
    totalCount Double
    The total number of resources across all pages.
    id string
    The unique identifier for this placement group.
    placementGroups GetIsPlacementGroupsPlacementGroup[]
    Collection of placement groups. Nested placement_groups blocks have the following structure:
    totalCount number
    The total number of resources across all pages.
    id str
    The unique identifier for this placement group.
    placement_groups Sequence[GetIsPlacementGroupsPlacementGroup]
    Collection of placement groups. Nested placement_groups blocks have the following structure:
    total_count float
    The total number of resources across all pages.
    id String
    The unique identifier for this placement group.
    placementGroups List<Property Map>
    Collection of placement groups. Nested placement_groups blocks have the following structure:
    totalCount Number
    The total number of resources across all pages.

    Supporting Types

    GetIsPlacementGroupsPlacementGroup

    AccessTags List<string>
    CreatedAt string
    The date and time that the placement group was created.
    Crn string
    The CRN for this placement group.
    Href string
    The URL for this placement group.
    Id string
    The unique identifier for this placement group.
    LifecycleState string
    The lifecycle state of the placement group.
    Name string
    The user-defined name for this placement group.
    ResourceGroups List<GetIsPlacementGroupsPlacementGroupResourceGroup>
    The unique identifier of the resource group for this placement group.
    ResourceType string
    The resource type.
    Strategy string
    The strategy for this placement group- host_spread: place on different compute hosts- power_spread: place on compute hosts that use different power sourcesThe enumerated values for this property may expand in the future. When processing this property, check for and log unknown values. Optionally halt processing and surface the error, or bypass the placement group on which the unexpected strategy was encountered.
    Tags List<string>
    AccessTags []string
    CreatedAt string
    The date and time that the placement group was created.
    Crn string
    The CRN for this placement group.
    Href string
    The URL for this placement group.
    Id string
    The unique identifier for this placement group.
    LifecycleState string
    The lifecycle state of the placement group.
    Name string
    The user-defined name for this placement group.
    ResourceGroups []GetIsPlacementGroupsPlacementGroupResourceGroup
    The unique identifier of the resource group for this placement group.
    ResourceType string
    The resource type.
    Strategy string
    The strategy for this placement group- host_spread: place on different compute hosts- power_spread: place on compute hosts that use different power sourcesThe enumerated values for this property may expand in the future. When processing this property, check for and log unknown values. Optionally halt processing and surface the error, or bypass the placement group on which the unexpected strategy was encountered.
    Tags []string
    accessTags List<String>
    createdAt String
    The date and time that the placement group was created.
    crn String
    The CRN for this placement group.
    href String
    The URL for this placement group.
    id String
    The unique identifier for this placement group.
    lifecycleState String
    The lifecycle state of the placement group.
    name String
    The user-defined name for this placement group.
    resourceGroups List<GetIsPlacementGroupsPlacementGroupResourceGroup>
    The unique identifier of the resource group for this placement group.
    resourceType String
    The resource type.
    strategy String
    The strategy for this placement group- host_spread: place on different compute hosts- power_spread: place on compute hosts that use different power sourcesThe enumerated values for this property may expand in the future. When processing this property, check for and log unknown values. Optionally halt processing and surface the error, or bypass the placement group on which the unexpected strategy was encountered.
    tags List<String>
    accessTags string[]
    createdAt string
    The date and time that the placement group was created.
    crn string
    The CRN for this placement group.
    href string
    The URL for this placement group.
    id string
    The unique identifier for this placement group.
    lifecycleState string
    The lifecycle state of the placement group.
    name string
    The user-defined name for this placement group.
    resourceGroups GetIsPlacementGroupsPlacementGroupResourceGroup[]
    The unique identifier of the resource group for this placement group.
    resourceType string
    The resource type.
    strategy string
    The strategy for this placement group- host_spread: place on different compute hosts- power_spread: place on compute hosts that use different power sourcesThe enumerated values for this property may expand in the future. When processing this property, check for and log unknown values. Optionally halt processing and surface the error, or bypass the placement group on which the unexpected strategy was encountered.
    tags string[]
    access_tags Sequence[str]
    created_at str
    The date and time that the placement group was created.
    crn str
    The CRN for this placement group.
    href str
    The URL for this placement group.
    id str
    The unique identifier for this placement group.
    lifecycle_state str
    The lifecycle state of the placement group.
    name str
    The user-defined name for this placement group.
    resource_groups Sequence[GetIsPlacementGroupsPlacementGroupResourceGroup]
    The unique identifier of the resource group for this placement group.
    resource_type str
    The resource type.
    strategy str
    The strategy for this placement group- host_spread: place on different compute hosts- power_spread: place on compute hosts that use different power sourcesThe enumerated values for this property may expand in the future. When processing this property, check for and log unknown values. Optionally halt processing and surface the error, or bypass the placement group on which the unexpected strategy was encountered.
    tags Sequence[str]
    accessTags List<String>
    createdAt String
    The date and time that the placement group was created.
    crn String
    The CRN for this placement group.
    href String
    The URL for this placement group.
    id String
    The unique identifier for this placement group.
    lifecycleState String
    The lifecycle state of the placement group.
    name String
    The user-defined name for this placement group.
    resourceGroups List<Property Map>
    The unique identifier of the resource group for this placement group.
    resourceType String
    The resource type.
    strategy String
    The strategy for this placement group- host_spread: place on different compute hosts- power_spread: place on compute hosts that use different power sourcesThe enumerated values for this property may expand in the future. When processing this property, check for and log unknown values. Optionally halt processing and surface the error, or bypass the placement group on which the unexpected strategy was encountered.
    tags List<String>

    GetIsPlacementGroupsPlacementGroupResourceGroup

    Href string
    The URL for this placement group.
    Id string
    The unique identifier for this placement group.
    Name string
    The user-defined name for this placement group.
    Href string
    The URL for this placement group.
    Id string
    The unique identifier for this placement group.
    Name string
    The user-defined name for this placement group.
    href String
    The URL for this placement group.
    id String
    The unique identifier for this placement group.
    name String
    The user-defined name for this placement group.
    href string
    The URL for this placement group.
    id string
    The unique identifier for this placement group.
    name string
    The user-defined name for this placement group.
    href str
    The URL for this placement group.
    id str
    The unique identifier for this placement group.
    name str
    The user-defined name for this placement group.
    href String
    The URL for this placement group.
    id String
    The unique identifier for this placement group.
    name String
    The user-defined name for this placement group.

    Package Details

    Repository
    ibm ibm-cloud/terraform-provider-ibm
    License
    Notes
    This Pulumi package is based on the ibm Terraform Provider.
    ibm logo
    ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud