Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi
oci.Core.getDedicatedVmHostInstances
Explore with Pulumi AI
This data source provides the list of Dedicated Vm Hosts Instances in Oracle Cloud Infrastructure Core service.
Returns the list of instances on the dedicated virtual machine hosts that match the specified criteria.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testDedicatedVmHostsInstances = oci.Core.getDedicatedVmHostInstances({
compartmentId: compartmentId,
dedicatedVmHostId: testDedicatedVmHost.id,
availabilityDomain: dedicatedVmHostsInstanceAvailabilityDomain,
});
import pulumi
import pulumi_oci as oci
test_dedicated_vm_hosts_instances = oci.Core.get_dedicated_vm_host_instances(compartment_id=compartment_id,
dedicated_vm_host_id=test_dedicated_vm_host["id"],
availability_domain=dedicated_vm_hosts_instance_availability_domain)
package main
import (
"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/Core"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := Core.GetDedicatedVmHostInstances(ctx, &core.GetDedicatedVmHostInstancesArgs{
CompartmentId: compartmentId,
DedicatedVmHostId: testDedicatedVmHost.Id,
AvailabilityDomain: pulumi.StringRef(dedicatedVmHostsInstanceAvailabilityDomain),
}, 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 testDedicatedVmHostsInstances = Oci.Core.GetDedicatedVmHostInstances.Invoke(new()
{
CompartmentId = compartmentId,
DedicatedVmHostId = testDedicatedVmHost.Id,
AvailabilityDomain = dedicatedVmHostsInstanceAvailabilityDomain,
});
});
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.GetDedicatedVmHostInstancesArgs;
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 testDedicatedVmHostsInstances = CoreFunctions.getDedicatedVmHostInstances(GetDedicatedVmHostInstancesArgs.builder()
.compartmentId(compartmentId)
.dedicatedVmHostId(testDedicatedVmHost.id())
.availabilityDomain(dedicatedVmHostsInstanceAvailabilityDomain)
.build());
}
}
variables:
testDedicatedVmHostsInstances:
fn::invoke:
Function: oci:Core:getDedicatedVmHostInstances
Arguments:
compartmentId: ${compartmentId}
dedicatedVmHostId: ${testDedicatedVmHost.id}
availabilityDomain: ${dedicatedVmHostsInstanceAvailabilityDomain}
Using getDedicatedVmHostInstances
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 getDedicatedVmHostInstances(args: GetDedicatedVmHostInstancesArgs, opts?: InvokeOptions): Promise<GetDedicatedVmHostInstancesResult>
function getDedicatedVmHostInstancesOutput(args: GetDedicatedVmHostInstancesOutputArgs, opts?: InvokeOptions): Output<GetDedicatedVmHostInstancesResult>
def get_dedicated_vm_host_instances(availability_domain: Optional[str] = None,
compartment_id: Optional[str] = None,
dedicated_vm_host_id: Optional[str] = None,
filters: Optional[Sequence[_core.GetDedicatedVmHostInstancesFilter]] = None,
opts: Optional[InvokeOptions] = None) -> GetDedicatedVmHostInstancesResult
def get_dedicated_vm_host_instances_output(availability_domain: Optional[pulumi.Input[str]] = None,
compartment_id: Optional[pulumi.Input[str]] = None,
dedicated_vm_host_id: Optional[pulumi.Input[str]] = None,
filters: Optional[pulumi.Input[Sequence[pulumi.Input[_core.GetDedicatedVmHostInstancesFilterArgs]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetDedicatedVmHostInstancesResult]
func GetDedicatedVmHostInstances(ctx *Context, args *GetDedicatedVmHostInstancesArgs, opts ...InvokeOption) (*GetDedicatedVmHostInstancesResult, error)
func GetDedicatedVmHostInstancesOutput(ctx *Context, args *GetDedicatedVmHostInstancesOutputArgs, opts ...InvokeOption) GetDedicatedVmHostInstancesResultOutput
> Note: This function is named GetDedicatedVmHostInstances
in the Go SDK.
public static class GetDedicatedVmHostInstances
{
public static Task<GetDedicatedVmHostInstancesResult> InvokeAsync(GetDedicatedVmHostInstancesArgs args, InvokeOptions? opts = null)
public static Output<GetDedicatedVmHostInstancesResult> Invoke(GetDedicatedVmHostInstancesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetDedicatedVmHostInstancesResult> getDedicatedVmHostInstances(GetDedicatedVmHostInstancesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: oci:Core/getDedicatedVmHostInstances:getDedicatedVmHostInstances
arguments:
# arguments dictionary
The following arguments are supported:
- Compartment
Id string - The OCID of the compartment.
- Dedicated
Vm stringHost Id - The OCID of the dedicated VM host.
- Availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- Filters
List<Get
Dedicated Vm Host Instances Filter>
- Compartment
Id string - The OCID of the compartment.
- Dedicated
Vm stringHost Id - The OCID of the dedicated VM host.
- Availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- Filters
[]Get
Dedicated Vm Host Instances Filter
- compartment
Id String - The OCID of the compartment.
- dedicated
Vm StringHost Id - The OCID of the dedicated VM host.
- availability
Domain String - The name of the availability domain. Example:
Uocm:PHX-AD-1
- filters
List<Get
Dedicated Vm Host Instances Filter>
- compartment
Id string - The OCID of the compartment.
- dedicated
Vm stringHost Id - The OCID of the dedicated VM host.
- availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- filters
Get
Dedicated Vm Host Instances Filter[]
- compartment_
id str - The OCID of the compartment.
- dedicated_
vm_ strhost_ id - The OCID of the dedicated VM host.
- availability_
domain str - The name of the availability domain. Example:
Uocm:PHX-AD-1
- filters
Sequence[core.
Get Dedicated Vm Host Instances Filter]
- compartment
Id String - The OCID of the compartment.
- dedicated
Vm StringHost Id - The OCID of the dedicated VM host.
- availability
Domain String - The name of the availability domain. Example:
Uocm:PHX-AD-1
- filters List<Property Map>
getDedicatedVmHostInstances Result
The following output properties are available:
- Compartment
Id string - The OCID of the compartment that contains the virtual machine instance.
- Dedicated
Vm stringHost Id - Dedicated
Vm List<GetHost Instances Dedicated Vm Host Instances Dedicated Vm Host Instance> - The list of dedicated_vm_host_instances.
- Id string
- The provider-assigned unique ID for this managed resource.
- Availability
Domain string - The availability domain the virtual machine instance is running in. Example:
Uocm:PHX-AD-1
- Filters
List<Get
Dedicated Vm Host Instances Filter>
- Compartment
Id string - The OCID of the compartment that contains the virtual machine instance.
- Dedicated
Vm stringHost Id - Dedicated
Vm []GetHost Instances Dedicated Vm Host Instances Dedicated Vm Host Instance - The list of dedicated_vm_host_instances.
- Id string
- The provider-assigned unique ID for this managed resource.
- Availability
Domain string - The availability domain the virtual machine instance is running in. Example:
Uocm:PHX-AD-1
- Filters
[]Get
Dedicated Vm Host Instances Filter
- compartment
Id String - The OCID of the compartment that contains the virtual machine instance.
- dedicated
Vm StringHost Id - dedicated
Vm List<GetHost Instances Dedicated Vm Host Instances Dedicated Vm Host Instance> - The list of dedicated_vm_host_instances.
- id String
- The provider-assigned unique ID for this managed resource.
- availability
Domain String - The availability domain the virtual machine instance is running in. Example:
Uocm:PHX-AD-1
- filters
List<Get
Dedicated Vm Host Instances Filter>
- compartment
Id string - The OCID of the compartment that contains the virtual machine instance.
- dedicated
Vm stringHost Id - dedicated
Vm GetHost Instances Dedicated Vm Host Instances Dedicated Vm Host Instance[] - The list of dedicated_vm_host_instances.
- id string
- The provider-assigned unique ID for this managed resource.
- availability
Domain string - The availability domain the virtual machine instance is running in. Example:
Uocm:PHX-AD-1
- filters
Get
Dedicated Vm Host Instances Filter[]
- compartment_
id str - The OCID of the compartment that contains the virtual machine instance.
- dedicated_
vm_ strhost_ id - dedicated_
vm_ Sequence[core.host_ instances Get Dedicated Vm Host Instances Dedicated Vm Host Instance] - The list of dedicated_vm_host_instances.
- id str
- The provider-assigned unique ID for this managed resource.
- availability_
domain str - The availability domain the virtual machine instance is running in. Example:
Uocm:PHX-AD-1
- filters
Sequence[core.
Get Dedicated Vm Host Instances Filter]
- compartment
Id String - The OCID of the compartment that contains the virtual machine instance.
- dedicated
Vm StringHost Id - dedicated
Vm List<Property Map>Host Instances - The list of dedicated_vm_host_instances.
- id String
- The provider-assigned unique ID for this managed resource.
- availability
Domain String - The availability domain the virtual machine instance is running in. Example:
Uocm:PHX-AD-1
- filters List<Property Map>
Supporting Types
GetDedicatedVmHostInstancesDedicatedVmHostInstance
- Availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- Compartment
Id string - The OCID of the compartment.
- Instance
Id string - The OCID of the virtual machine instance.
- Shape string
- The shape of the VM instance.
- Time
Created string - The date and time the virtual machine instance was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- Availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- Compartment
Id string - The OCID of the compartment.
- Instance
Id string - The OCID of the virtual machine instance.
- Shape string
- The shape of the VM instance.
- Time
Created string - The date and time the virtual machine instance was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- availability
Domain String - The name of the availability domain. Example:
Uocm:PHX-AD-1
- compartment
Id String - The OCID of the compartment.
- instance
Id String - The OCID of the virtual machine instance.
- shape String
- The shape of the VM instance.
- time
Created String - The date and time the virtual machine instance was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- compartment
Id string - The OCID of the compartment.
- instance
Id string - The OCID of the virtual machine instance.
- shape string
- The shape of the VM instance.
- time
Created string - The date and time the virtual machine instance was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- availability_
domain str - The name of the availability domain. Example:
Uocm:PHX-AD-1
- compartment_
id str - The OCID of the compartment.
- instance_
id str - The OCID of the virtual machine instance.
- shape str
- The shape of the VM instance.
- time_
created str - The date and time the virtual machine instance was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- availability
Domain String - The name of the availability domain. Example:
Uocm:PHX-AD-1
- compartment
Id String - The OCID of the compartment.
- instance
Id String - The OCID of the virtual machine instance.
- shape String
- The shape of the VM instance.
- time
Created String - The date and time the virtual machine instance was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
GetDedicatedVmHostInstancesFilter
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.