Test encrypted snapshot of a encrypted disk

This commit is contained in:
Thomas Poindessous 2017-03-13 12:27:39 +01:00
parent 1dbedf26ef
commit 2d1e1741bb
1 changed files with 4 additions and 2 deletions

View File

@ -146,11 +146,13 @@ resource "google_compute_disk" "foobar" {
size = 10
type = "pd-ssd"
zone = "us-central1-a"
disk_encryption_key_raw = "SGVsbG8gZnJvbSBHb29nbGUgQ2xvdWQgUGxhdGZvcm0="
}
resource "google_compute_snapshot" "foobar" {
name = "%s"
disk = "%s"
disk = "${google_compute_disk.foobar.name}"
zone = "us-central1-a"
sourcedisk_encryption_key_raw = "SGVsbG8gZnJvbSBHb29nbGUgQ2xvdWQgUGxhdGZvcm0="
snapshot_encryption_key_raw = "SGVsbG8gZnJvbSBHb29nbGUgQ2xvdWQgUGxhdGZvcm0="
}`, diskName, snapshotName, diskName)
}`, diskName, snapshotName)
}