❗ Important note: using this method, the plaintext value of the secret will be persisted into your Terraform state file. This ideally shouldn't pose a problem as long as your Terraform state files are properly secured and encrypted too.
The Google Cloud Terraform provider provides a very clean and intuitive interface in order to store secrets in Git.
Before we can start committing our secrets in a Git repositoriy we first have to create a KMS key ring and a KMS crypto key.