Resource: awsFsxOpenzfsSnapshot
Manages an Amazon FSx for OpenZFS volume. See the FSx OpenZFS User Guide for more information.
Example Usage
Root volume Example
/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as aws from "./.gen/providers/aws";
const awsFsxOpenzfsFileSystemExample =
new aws.fsxOpenzfsFileSystem.FsxOpenzfsFileSystem(this, "example", {
deploymentType: "SINGLE_AZ_1",
storageCapacity: 64,
subnetIds: ["${aws_subnet.example.id}"],
throughputCapacity: 64,
});
const awsFsxOpenzfsSnapshotExample =
new aws.fsxOpenzfsSnapshot.FsxOpenzfsSnapshot(this, "example_1", {
name: "example",
volumeId: awsFsxOpenzfsFileSystemExample.rootVolumeId,
});
/*This allows the Terraform resource name to match the original name. You can remove the call if you don't need them to match.*/
awsFsxOpenzfsSnapshotExample.overrideLogicalId("example");
Child volume Example
/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as aws from "./.gen/providers/aws";
const awsFsxOpenzfsFileSystemExample =
new aws.fsxOpenzfsFileSystem.FsxOpenzfsFileSystem(this, "example", {
deploymentType: "SINGLE_AZ_1",
storageCapacity: 64,
subnetIds: ["${aws_subnet.example.id}"],
throughputCapacity: 64,
});
const awsFsxOpenzfsVolumeExample = new aws.fsxOpenzfsVolume.FsxOpenzfsVolume(
this,
"example_1",
{
name: "example",
parentVolumeId: awsFsxOpenzfsFileSystemExample.rootVolumeId,
}
);
/*This allows the Terraform resource name to match the original name. You can remove the call if you don't need them to match.*/
awsFsxOpenzfsVolumeExample.overrideLogicalId("example");
const awsFsxOpenzfsSnapshotExample =
new aws.fsxOpenzfsSnapshot.FsxOpenzfsSnapshot(this, "example_2", {
name: "example",
volumeId: awsFsxOpenzfsVolumeExample.id,
});
/*This allows the Terraform resource name to match the original name. You can remove the call if you don't need them to match.*/
awsFsxOpenzfsSnapshotExample.overrideLogicalId("example");
Argument Reference
The following arguments are supported:
name
- (Required) The name of the Snapshot. You can use a maximum of 203 alphanumeric characters plus either _ or - or : or . for the name.tags
- (Optional) A map of tags to assign to the file system. If configured with a providerdefaultTags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. If you have setcopyTagsToBackups
to true, and you specify one or more tags, no existing file system tags are copied from the file system to the backup.volumeId
- (Optional) The ID of the volume to snapshot. This can be the root volume or a child volume.
Attributes Reference
In addition to all arguments above, the following attributes are exported:
arn
- Amazon Resource Name of the snapshot.id
- Identifier of the snapshot, e.g.,fsvolsnap12345678
tagsAll
- A map of tags assigned to the resource, including those inherited from the providerdefaultTags
configuration block.
Timeouts
create
- (Default30M
)delete
- (Default30M
)update
- (Default30M
)
Import
FSx OpenZFS snapshot can be imported using the id
, e.g.,