Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- What is the terraform syntax to encrypt the google_compute_disk using a custom managed KMS key in the google cloud platform.
- Referring the documentation and using the KMS key self_link for disk_encryption_key.raw_key seems to not work. The resulting disk generated shows the disk is encrypted via google managed key.
- Please let me know if I am using a wrong format.
- **resource "google_compute_disk" "ext_disk" {
- name = "testdisk"
- type = "pd-ssd"
- zone = "${var.zone}"
- size = 16
- labels {
- environment = "${var.target_environment}"
- }
- disk_encryption_key {
- raw_key = "${google_kms_crypto_key.crypto_key.self_link}"
- }
- }**
Add Comment
Please, Sign In to add comment