-
Notifications
You must be signed in to change notification settings - Fork 9.8k
Open
Labels
enhancementRequests to existing resources that expand the functionality or scope.Requests to existing resources that expand the functionality or scope.needs-triageWaiting for first response or review from a maintainer.Waiting for first response or review from a maintainer.service/ebsIssues and PRs that pertain to the ebs service.Issues and PRs that pertain to the ebs service.service/ec2ebsIssues and PRs that pertain to the ec2ebs service.Issues and PRs that pertain to the ec2ebs service.
Description
Description
AWS has recently introduced the ability to copy an EBS volume using the CopyVolumes API. I would like to be able to use this API to create EBS volume clones using Terraform.
Affected Resource(s) or Data Source(s)
aws_ebs_volume
Potential Terraform Configuration
One potential design would be to work this into a new field on the aws_ebs_volume
resource:
# Look up the source volume
data "aws_ebs_volume" "source" {
most_recent = true
filter {
name = "tag:Name"
values = ["Example"]
}
}
# Create a clone
resource "aws_ebs_volume" "clone" {
availability_zone = data.aws_ebs_volume.source.availability_zone // must match AZ of source
source_volume_id = data.aws_ebs_volume.source.id
tags = {
Name = "ExampleClone"
}
}
In this example, source_volume_id
is the new argument that triggers calling the CopyVolumes
API instead of CreateVolume
.
References
AWS announcement posts:
- Amazon EBS now supports Volume Clones for instant volume copies
- Introducing Amazon EBS Volume Clones: Create instant copies of your EBS volumes
SDK support:
- AWS Go SDK v2 added support in release-2025-10-14.
- SDK docs:
Client.CopyVolumes
in github.com/aws/aws-sdk-go-v2/service/ec2@v1.257.2
Would you like to implement the enhancement?
No
jdx, mattmoyer, cshi-figma and wkhan-figma
Metadata
Metadata
Assignees
Labels
enhancementRequests to existing resources that expand the functionality or scope.Requests to existing resources that expand the functionality or scope.needs-triageWaiting for first response or review from a maintainer.Waiting for first response or review from a maintainer.service/ebsIssues and PRs that pertain to the ebs service.Issues and PRs that pertain to the ebs service.service/ec2ebsIssues and PRs that pertain to the ec2ebs service.Issues and PRs that pertain to the ec2ebs service.