anil@Alchemist ~/secrets [1]> credstash -p anil get ping
pong
anil@Alchemist ~/secrets> terraform plan
Refreshing Terraform state in-memory prior to plan...
The refreshed state will be used to calculate this plan, but will not be
persisted to local or remote state storage.
data.credstash_secret.ping123: Refreshing state...
Error: Error refreshing state: 1 error(s) occurred:
* data.credstash_secret.ping123: 1 error(s) occurred:
* data.credstash_secret.ping123: data.credstash_secret.ping123: secret with name ping could not be found
For secret.tf
provider "credstash" {
table = "credential-store"
region = "us-east-1"
profile = "anil"
}
data "credstash_secret" "ping123" {
name = "ping"
}
output "secret" {
value = "${data.credstash_secret.ping123.value}"
}
For secret.tf