# Hashicorp Vault

**URL:** <https://discuss.hashicorp.com/t/hashicorp-vault/21179>\
**Category:** Vault\
**Created:** [February 19, 2021, 1:53pm UTC](https://discuss.hashicorp.com/t/hashicorp-vault/21179 "2021-02-19T13:53:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![rahulagalcha97](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/rahulagalcha97/32/8751_2.png) [@rahulagalcha97](https://discuss.hashicorp.com/u/rahulagalcha97)\
**Post date:** [February 19, 2021, 1:53pm UTC](https://discuss.hashicorp.com/t/hashicorp-vault/21179/1 "2021-02-19T13:53:48Z")

</div>

I am using the hashicorp vault to generate the Dynamic secret key and access key for aws and using terraform to create resources.

Now I am facing an issue that I want AWS CLI configured with the generated (Short lived keys) automatically.

Required for EKS setup

AWS CLI( Credentials file) …should have the vaults generated keys.

---

<div class="post-metadata">

**Author:** ![btkrausen](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/btkrausen/32/1115_2.png) [@btkrausen](https://discuss.hashicorp.com/u/btkrausen)\
**Post date:** [February 19, 2021, 2:33pm UTC](https://discuss.hashicorp.com/t/hashicorp-vault/21179/2 "2021-02-19T14:33:24Z")

</div>

You could possibly use `envconsul` to query Vault for new credentials and set them as environment variables.

Or you can run the `vault read -format=json aws/creds/<role>` command and then parse through the output using `jq` to grab the username and password.

Just a few suggestions here.
