1. Packages
  2. Hsdp Provider
  3. API Docs
  4. getContainerHostInstances
hsdp 0.65.3 published on Tuesday, Apr 15, 2025 by philips-software

hsdp.getContainerHostInstances

Explore with Pulumi AI

Retrieve a list of container hosts instances

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as hsdp from "@pulumi/hsdp";

const all = hsdp.getContainerHostInstances({});
export const allContainerHosts = all.then(all => all.ids);
Copy
import pulumi
import pulumi_hsdp as hsdp

all = hsdp.get_container_host_instances()
pulumi.export("allContainerHosts", all.ids)
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/hsdp/hsdp"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		all, err := hsdp.GetContainerHostInstances(ctx, &hsdp.GetContainerHostInstancesArgs{}, nil)
		if err != nil {
			return err
		}
		ctx.Export("allContainerHosts", all.Ids)
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Hsdp = Pulumi.Hsdp;

return await Deployment.RunAsync(() => 
{
    var all = Hsdp.GetContainerHostInstances.Invoke();

    return new Dictionary<string, object?>
    {
        ["allContainerHosts"] = all.Apply(getContainerHostInstancesResult => getContainerHostInstancesResult.Ids),
    };
});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.hsdp.HsdpFunctions;
import com.pulumi.hsdp.inputs.GetContainerHostInstancesArgs;
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 all = HsdpFunctions.getContainerHostInstances();

        ctx.export("allContainerHosts", all.applyValue(getContainerHostInstancesResult -> getContainerHostInstancesResult.ids()));
    }
}
Copy
variables:
  all:
    fn::invoke:
      function: hsdp:getContainerHostInstances
      arguments: {}
outputs:
  allContainerHosts: ${all.ids}
Copy

Using getContainerHostInstances

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 getContainerHostInstances(args: GetContainerHostInstancesArgs, opts?: InvokeOptions): Promise<GetContainerHostInstancesResult>
function getContainerHostInstancesOutput(args: GetContainerHostInstancesOutputArgs, opts?: InvokeOptions): Output<GetContainerHostInstancesResult>
Copy
def get_container_host_instances(id: Optional[str] = None,
                                 opts: Optional[InvokeOptions] = None) -> GetContainerHostInstancesResult
def get_container_host_instances_output(id: Optional[pulumi.Input[str]] = None,
                                 opts: Optional[InvokeOptions] = None) -> Output[GetContainerHostInstancesResult]
Copy
func GetContainerHostInstances(ctx *Context, args *GetContainerHostInstancesArgs, opts ...InvokeOption) (*GetContainerHostInstancesResult, error)
func GetContainerHostInstancesOutput(ctx *Context, args *GetContainerHostInstancesOutputArgs, opts ...InvokeOption) GetContainerHostInstancesResultOutput
Copy

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

public static class GetContainerHostInstances 
{
    public static Task<GetContainerHostInstancesResult> InvokeAsync(GetContainerHostInstancesArgs args, InvokeOptions? opts = null)
    public static Output<GetContainerHostInstancesResult> Invoke(GetContainerHostInstancesInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetContainerHostInstancesResult> getContainerHostInstances(GetContainerHostInstancesArgs args, InvokeOptions options)
public static Output<GetContainerHostInstancesResult> getContainerHostInstances(GetContainerHostInstancesArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: hsdp:index/getContainerHostInstances:getContainerHostInstances
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Id string
Id string
id String
id string
id str
id String

getContainerHostInstances Result

The following output properties are available:

Id string
Ids List<string>
The list of container host IDs
Names List<string>
The list of container host names. This matches up with the ids list index.
Owners List<string>
The list of container host owners. This matches up with the ids list index.
Roles List<string>
The list of container host roles. This matches up with the ids list index.
Id string
Ids []string
The list of container host IDs
Names []string
The list of container host names. This matches up with the ids list index.
Owners []string
The list of container host owners. This matches up with the ids list index.
Roles []string
The list of container host roles. This matches up with the ids list index.
id String
ids List<String>
The list of container host IDs
names List<String>
The list of container host names. This matches up with the ids list index.
owners List<String>
The list of container host owners. This matches up with the ids list index.
roles List<String>
The list of container host roles. This matches up with the ids list index.
id string
ids string[]
The list of container host IDs
names string[]
The list of container host names. This matches up with the ids list index.
owners string[]
The list of container host owners. This matches up with the ids list index.
roles string[]
The list of container host roles. This matches up with the ids list index.
id str
ids Sequence[str]
The list of container host IDs
names Sequence[str]
The list of container host names. This matches up with the ids list index.
owners Sequence[str]
The list of container host owners. This matches up with the ids list index.
roles Sequence[str]
The list of container host roles. This matches up with the ids list index.
id String
ids List<String>
The list of container host IDs
names List<String>
The list of container host names. This matches up with the ids list index.
owners List<String>
The list of container host owners. This matches up with the ids list index.
roles List<String>
The list of container host roles. This matches up with the ids list index.

Package Details

Repository
hsdp philips-software/terraform-provider-hsdp
License
Notes
This Pulumi package is based on the hsdp Terraform Provider.