Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi
oci.Core.getBootVolumeAttachments
Explore with Pulumi AI
This data source provides the list of Boot Volume Attachments in Oracle Cloud Infrastructure Core service.
Lists the boot volume attachments in the specified compartment. You can filter the list by specifying an instance OCID, boot volume OCID, or both.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testBootVolumeAttachments = oci.Core.getBootVolumeAttachments({
availabilityDomain: bootVolumeAttachmentAvailabilityDomain,
compartmentId: compartmentId,
bootVolumeId: testBootVolume.id,
instanceId: testInstance.id,
});
import pulumi
import pulumi_oci as oci
test_boot_volume_attachments = oci.Core.get_boot_volume_attachments(availability_domain=boot_volume_attachment_availability_domain,
compartment_id=compartment_id,
boot_volume_id=test_boot_volume["id"],
instance_id=test_instance["id"])
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.GetBootVolumeAttachments(ctx, &core.GetBootVolumeAttachmentsArgs{
AvailabilityDomain: bootVolumeAttachmentAvailabilityDomain,
CompartmentId: compartmentId,
BootVolumeId: pulumi.StringRef(testBootVolume.Id),
InstanceId: pulumi.StringRef(testInstance.Id),
}, 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 testBootVolumeAttachments = Oci.Core.GetBootVolumeAttachments.Invoke(new()
{
AvailabilityDomain = bootVolumeAttachmentAvailabilityDomain,
CompartmentId = compartmentId,
BootVolumeId = testBootVolume.Id,
InstanceId = testInstance.Id,
});
});
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.GetBootVolumeAttachmentsArgs;
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 testBootVolumeAttachments = CoreFunctions.getBootVolumeAttachments(GetBootVolumeAttachmentsArgs.builder()
.availabilityDomain(bootVolumeAttachmentAvailabilityDomain)
.compartmentId(compartmentId)
.bootVolumeId(testBootVolume.id())
.instanceId(testInstance.id())
.build());
}
}
variables:
testBootVolumeAttachments:
fn::invoke:
Function: oci:Core:getBootVolumeAttachments
Arguments:
availabilityDomain: ${bootVolumeAttachmentAvailabilityDomain}
compartmentId: ${compartmentId}
bootVolumeId: ${testBootVolume.id}
instanceId: ${testInstance.id}
For more detailed implementation refer the instance example
Using getBootVolumeAttachments
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 getBootVolumeAttachments(args: GetBootVolumeAttachmentsArgs, opts?: InvokeOptions): Promise<GetBootVolumeAttachmentsResult>
function getBootVolumeAttachmentsOutput(args: GetBootVolumeAttachmentsOutputArgs, opts?: InvokeOptions): Output<GetBootVolumeAttachmentsResult>
def get_boot_volume_attachments(availability_domain: Optional[str] = None,
boot_volume_id: Optional[str] = None,
compartment_id: Optional[str] = None,
filters: Optional[Sequence[_core.GetBootVolumeAttachmentsFilter]] = None,
instance_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetBootVolumeAttachmentsResult
def get_boot_volume_attachments_output(availability_domain: Optional[pulumi.Input[str]] = None,
boot_volume_id: Optional[pulumi.Input[str]] = None,
compartment_id: Optional[pulumi.Input[str]] = None,
filters: Optional[pulumi.Input[Sequence[pulumi.Input[_core.GetBootVolumeAttachmentsFilterArgs]]]] = None,
instance_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetBootVolumeAttachmentsResult]
func GetBootVolumeAttachments(ctx *Context, args *GetBootVolumeAttachmentsArgs, opts ...InvokeOption) (*GetBootVolumeAttachmentsResult, error)
func GetBootVolumeAttachmentsOutput(ctx *Context, args *GetBootVolumeAttachmentsOutputArgs, opts ...InvokeOption) GetBootVolumeAttachmentsResultOutput
> Note: This function is named GetBootVolumeAttachments
in the Go SDK.
public static class GetBootVolumeAttachments
{
public static Task<GetBootVolumeAttachmentsResult> InvokeAsync(GetBootVolumeAttachmentsArgs args, InvokeOptions? opts = null)
public static Output<GetBootVolumeAttachmentsResult> Invoke(GetBootVolumeAttachmentsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetBootVolumeAttachmentsResult> getBootVolumeAttachments(GetBootVolumeAttachmentsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: oci:Core/getBootVolumeAttachments:getBootVolumeAttachments
arguments:
# arguments dictionary
The following arguments are supported:
- Availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- Compartment
Id string - The OCID of the compartment.
- Boot
Volume stringId - The OCID of the boot volume.
- Filters
List<Get
Boot Volume Attachments Filter> - Instance
Id string - The OCID of the instance.
- Availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- Compartment
Id string - The OCID of the compartment.
- Boot
Volume stringId - The OCID of the boot volume.
- Filters
[]Get
Boot Volume Attachments Filter - Instance
Id string - The OCID of the instance.
- availability
Domain String - The name of the availability domain. Example:
Uocm:PHX-AD-1
- compartment
Id String - The OCID of the compartment.
- boot
Volume StringId - The OCID of the boot volume.
- filters
List<Get
Boot Volume Attachments Filter> - instance
Id String - The OCID of the instance.
- availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- compartment
Id string - The OCID of the compartment.
- boot
Volume stringId - The OCID of the boot volume.
- filters
Get
Boot Volume Attachments Filter[] - instance
Id string - The OCID of the instance.
- availability_
domain str - The name of the availability domain. Example:
Uocm:PHX-AD-1
- compartment_
id str - The OCID of the compartment.
- boot_
volume_ strid - The OCID of the boot volume.
- filters
Sequence[core.
Get Boot Volume Attachments Filter] - instance_
id str - The OCID of the instance.
- availability
Domain String - The name of the availability domain. Example:
Uocm:PHX-AD-1
- compartment
Id String - The OCID of the compartment.
- boot
Volume StringId - The OCID of the boot volume.
- filters List<Property Map>
- instance
Id String - The OCID of the instance.
getBootVolumeAttachments Result
The following output properties are available:
- Availability
Domain string - The availability domain of an instance. Example:
Uocm:PHX-AD-1
- Boot
Volume List<GetAttachments Boot Volume Attachments Boot Volume Attachment> - The list of boot_volume_attachments.
- Compartment
Id string - The OCID of the compartment.
- Id string
- The provider-assigned unique ID for this managed resource.
- Boot
Volume stringId - The OCID of the boot volume.
- Filters
List<Get
Boot Volume Attachments Filter> - Instance
Id string - The OCID of the instance the boot volume is attached to.
- Availability
Domain string - The availability domain of an instance. Example:
Uocm:PHX-AD-1
- Boot
Volume []GetAttachments Boot Volume Attachments Boot Volume Attachment - The list of boot_volume_attachments.
- Compartment
Id string - The OCID of the compartment.
- Id string
- The provider-assigned unique ID for this managed resource.
- Boot
Volume stringId - The OCID of the boot volume.
- Filters
[]Get
Boot Volume Attachments Filter - Instance
Id string - The OCID of the instance the boot volume is attached to.
- availability
Domain String - The availability domain of an instance. Example:
Uocm:PHX-AD-1
- boot
Volume List<GetAttachments Boot Volume Attachments Boot Volume Attachment> - The list of boot_volume_attachments.
- compartment
Id String - The OCID of the compartment.
- id String
- The provider-assigned unique ID for this managed resource.
- boot
Volume StringId - The OCID of the boot volume.
- filters
List<Get
Boot Volume Attachments Filter> - instance
Id String - The OCID of the instance the boot volume is attached to.
- availability
Domain string - The availability domain of an instance. Example:
Uocm:PHX-AD-1
- boot
Volume GetAttachments Boot Volume Attachments Boot Volume Attachment[] - The list of boot_volume_attachments.
- compartment
Id string - The OCID of the compartment.
- id string
- The provider-assigned unique ID for this managed resource.
- boot
Volume stringId - The OCID of the boot volume.
- filters
Get
Boot Volume Attachments Filter[] - instance
Id string - The OCID of the instance the boot volume is attached to.
- availability_
domain str - The availability domain of an instance. Example:
Uocm:PHX-AD-1
- boot_
volume_ Sequence[core.attachments Get Boot Volume Attachments Boot Volume Attachment] - The list of boot_volume_attachments.
- compartment_
id str - The OCID of the compartment.
- id str
- The provider-assigned unique ID for this managed resource.
- boot_
volume_ strid - The OCID of the boot volume.
- filters
Sequence[core.
Get Boot Volume Attachments Filter] - instance_
id str - The OCID of the instance the boot volume is attached to.
- availability
Domain String - The availability domain of an instance. Example:
Uocm:PHX-AD-1
- boot
Volume List<Property Map>Attachments - The list of boot_volume_attachments.
- compartment
Id String - The OCID of the compartment.
- id String
- The provider-assigned unique ID for this managed resource.
- boot
Volume StringId - The OCID of the boot volume.
- filters List<Property Map>
- instance
Id String - The OCID of the instance the boot volume is attached to.
Supporting Types
GetBootVolumeAttachmentsBootVolumeAttachment
- Availability
Domain string - The name of the availability domain. Example:
Uocm:PHX-AD-1
- Boot
Volume stringId - The OCID of the boot volume.
- Compartment
Id string - The OCID of the compartment.
- Display
Name string - A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- Encryption
In stringTransit Type - Refer the top-level definition of encryptionInTransitType. The default value is NONE.
- Id string
- The OCID of the boot volume attachment.
- Instance
Id string - The OCID of the instance.
- Is
Pv boolEncryption In Transit Enabled - Whether in-transit encryption for the boot volume's paravirtualized attachment is enabled or not.
- State string
- The current state of the boot volume attachment.
- Time
Created string - The date and time the boot volume was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- Time
Updated string - The date and time the boot volume attachment was updated, 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
- Boot
Volume stringId - The OCID of the boot volume.
- Compartment
Id string - The OCID of the compartment.
- Display
Name string - A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- Encryption
In stringTransit Type - Refer the top-level definition of encryptionInTransitType. The default value is NONE.
- Id string
- The OCID of the boot volume attachment.
- Instance
Id string - The OCID of the instance.
- Is
Pv boolEncryption In Transit Enabled - Whether in-transit encryption for the boot volume's paravirtualized attachment is enabled or not.
- State string
- The current state of the boot volume attachment.
- Time
Created string - The date and time the boot volume was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- Time
Updated string - The date and time the boot volume attachment was updated, 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
- boot
Volume StringId - The OCID of the boot volume.
- compartment
Id String - The OCID of the compartment.
- display
Name String - A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- encryption
In StringTransit Type - Refer the top-level definition of encryptionInTransitType. The default value is NONE.
- id String
- The OCID of the boot volume attachment.
- instance
Id String - The OCID of the instance.
- is
Pv BooleanEncryption In Transit Enabled - Whether in-transit encryption for the boot volume's paravirtualized attachment is enabled or not.
- state String
- The current state of the boot volume attachment.
- time
Created String - The date and time the boot volume was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- time
Updated String - The date and time the boot volume attachment was updated, 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
- boot
Volume stringId - The OCID of the boot volume.
- compartment
Id string - The OCID of the compartment.
- display
Name string - A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- encryption
In stringTransit Type - Refer the top-level definition of encryptionInTransitType. The default value is NONE.
- id string
- The OCID of the boot volume attachment.
- instance
Id string - The OCID of the instance.
- is
Pv booleanEncryption In Transit Enabled - Whether in-transit encryption for the boot volume's paravirtualized attachment is enabled or not.
- state string
- The current state of the boot volume attachment.
- time
Created string - The date and time the boot volume was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- time
Updated string - The date and time the boot volume attachment was updated, 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
- boot_
volume_ strid - The OCID of the boot volume.
- compartment_
id str - The OCID of the compartment.
- display_
name str - A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- encryption_
in_ strtransit_ type - Refer the top-level definition of encryptionInTransitType. The default value is NONE.
- id str
- The OCID of the boot volume attachment.
- instance_
id str - The OCID of the instance.
- is_
pv_ boolencryption_ in_ transit_ enabled - Whether in-transit encryption for the boot volume's paravirtualized attachment is enabled or not.
- state str
- The current state of the boot volume attachment.
- time_
created str - The date and time the boot volume was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- time_
updated str - The date and time the boot volume attachment was updated, 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
- boot
Volume StringId - The OCID of the boot volume.
- compartment
Id String - The OCID of the compartment.
- display
Name String - A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- encryption
In StringTransit Type - Refer the top-level definition of encryptionInTransitType. The default value is NONE.
- id String
- The OCID of the boot volume attachment.
- instance
Id String - The OCID of the instance.
- is
Pv BooleanEncryption In Transit Enabled - Whether in-transit encryption for the boot volume's paravirtualized attachment is enabled or not.
- state String
- The current state of the boot volume attachment.
- time
Created String - The date and time the boot volume was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- time
Updated String - The date and time the boot volume attachment was updated, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
GetBootVolumeAttachmentsFilter
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.