From f8baf4f4f06e5f64a3f503619724b87af86b6986 Mon Sep 17 00:00:00 2001 From: Matt Stump Date: Tue, 26 Mar 2019 17:30:27 -0700 Subject: [PATCH] Fix for #1312, use describe to determine if AWS EBS snapshot is encrypted and explicitly pass that value in EC2 CreateVolume call. (#1316) Signed-off-by: Matt Stump --- changelogs/unreleased/1316-mstump | 1 + pkg/cloudprovider/aws/block_store.go | 1 + 2 files changed, 2 insertions(+) create mode 100644 changelogs/unreleased/1316-mstump diff --git a/changelogs/unreleased/1316-mstump b/changelogs/unreleased/1316-mstump new file mode 100644 index 000000000..4d7e0f7fe --- /dev/null +++ b/changelogs/unreleased/1316-mstump @@ -0,0 +1 @@ +Fix for #1312, use describe to determine if AWS EBS snapshot is encrypted and explicitly pass that value in EC2 CreateVolume call. diff --git a/pkg/cloudprovider/aws/block_store.go b/pkg/cloudprovider/aws/block_store.go index 79a79a3f5..2165055e2 100644 --- a/pkg/cloudprovider/aws/block_store.go +++ b/pkg/cloudprovider/aws/block_store.go @@ -102,6 +102,7 @@ func (b *BlockStore) CreateVolumeFromSnapshot(snapshotID, volumeType, volumeAZ s SnapshotId: &snapshotID, AvailabilityZone: &volumeAZ, VolumeType: &volumeType, + Encrypted: snapRes.Snapshots[0].Encrypted, TagSpecifications: []*ec2.TagSpecification{ { ResourceType: aws.String(ec2.ResourceTypeVolume),