terraform-aws-tfstate-backend
terraform-aws-tfstate-backend copied to clipboard
Possible to add ability to use KMS over AES?
Would like to be able to encrypt via KMS. Wondering if it is possible to add this ability.
https://www.terraform.io/docs/backends/types/s3.html#kms_key_id
This can be done by overwriting the var terraform_backend_config_template_file
with your own template file that includes the kms_key_id
.
terraform {
required_version = ">= ${terraform_version}"
backend "s3" {
region = "${region}"
bucket = "${bucket}"
key = "${terraform_state_file}"
dynamodb_table = "${dynamodb_table}"
profile = "${profile}"
role_arn = "${role_arn}"
encrypt = "${encrypt}"
kms_key_id = "arn:aws:..."
}
}