I am creating a GKE cluster with Terraform script, I need to use Application layer secrets encryption in the cluster so I am not getting a block for this on terraform's official documentation can anyone please tell me how to enable Application layer secrets encryption in terraform script
I used this one:
database_encryption {
state = "ENCRYPTED"
key_name = google_kms_crypto_key.encryption-kms-key.self_link
}
And this depends_on for used the kKMS keyring created with Terraform.
depends_on = [
google_kms_key_ring.keyring
]
Ref: https://www.terraform.io/docs/providers/google/d/google_kms_crypto_key.html
To enable it you need to set database_encryption
of google_container_cluster
resource
https://www.terraform.io/docs/providers/google/r/container_cluster.html#database_encryption