Skip to content
v2.277.0

CfnVolumeAssociationProps Struct ​

Properties for defining a CfnVolumeAssociation.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_workspacesinstances as workspacesinstances } from 'aws-cdk-lib';
const cfnVolumeAssociationProps: workspacesinstances.CfnVolumeAssociationProps = {
  device: 'device',
  volumeId: 'volumeId',
  workspaceInstanceId: 'workspaceInstanceId',

  // the properties below are optional
  disassociateMode: 'disassociateMode',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_workspacesinstances as workspacesinstances

cfn_volume_association_props = workspacesinstances.CfnVolumeAssociationProps(
    device="device",
    volume_id="volumeId",
    workspace_instance_id="workspaceInstanceId",

    # the properties below are optional
    disassociate_mode="disassociateMode"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.workspacesinstances.*;

CfnVolumeAssociationProps cfnVolumeAssociationProps = CfnVolumeAssociationProps.builder()
        .device("device")
        .volumeId("volumeId")
        .workspaceInstanceId("workspaceInstanceId")

        // the properties below are optional
        .disassociateMode("disassociateMode")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.WorkspacesInstances;

var cfnVolumeAssociationProps = new CfnVolumeAssociationProps {
    Device = "device",
    VolumeId = "volumeId",
    WorkspaceInstanceId = "workspaceInstanceId",

    // the properties below are optional
    DisassociateMode = "disassociateMode"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

cfnVolumeAssociationProps := &CfnVolumeAssociationProps{
	Device: jsii.String("device"),
	VolumeId: jsii.String("volumeId"),
	WorkspaceInstanceId: jsii.String("workspaceInstanceId"),

	// the properties below are optional
	DisassociateMode: jsii.String("disassociateMode"),
}

Properties ​

devicestringdevicestrdeviceStringDevicestringDevice*stringrequired#
The device name for the volume attachment.
disassociateModeoptionalstringdisassociate_modeoptionalstrdisassociateModeoptionalStringDisassociateModeoptionalstringDisassociateModeoptional*string#
Mode to use when disassociating the volume.
volumeIdstringvolume_idstrvolumeIdStringVolumeIdstringVolumeId*stringrequired#
ID of the volume to attach to the workspace instance.
workspaceInstanceIdstringworkspace_instance_idstrworkspaceInstanceIdStringWorkspaceInstanceIdstringWorkspaceInstanceId*stringrequired#
ID of the workspace instance to associate with the volume.