Difference between revisions of "Vault curl"
Jump to navigation
Jump to search
| Line 2: | Line 2: | ||
https://developer.hashicorp.com/vault/api-docs/auth/token | https://developer.hashicorp.com/vault/api-docs/auth/token | ||
| + | |||
| + | |||
``` | ``` | ||
curl -sS --fail -X POST -d '{"increment": "24h"}' -H "X-Vault-Token: $VAULT_TOKEN" ${VAULT_ADDR}/v1/auth/ | curl -sS --fail -X POST -d '{"increment": "24h"}' -H "X-Vault-Token: $VAULT_TOKEN" ${VAULT_ADDR}/v1/auth/ | ||
| Line 9: | Line 11: | ||
``` | ``` | ||
curl -sS -H "X-Vault-Token: $VAULT_TOKEN" https://vault.example.com:8200/v1/auth/token/lookup-self | curl -sS -H "X-Vault-Token: $VAULT_TOKEN" https://vault.example.com:8200/v1/auth/token/lookup-self | ||
| + | curl -sS --fail -X POST -d '{"increment": "145h"}' -H "X-Vault-Token: $VAULT_TOKEN" https://vault.example.com:8200/v1/auth/token/renew-self | ||
| + | curl --request POST -d '{"token": "$VAULT_TOKEN"}' -H "X-Vault-Token: $VAULT_TOKEN" https://vault.example.com:8200/v1/auth/token/renew | ||
``` | ``` | ||
Latest revision as of 17:57, 17 July 2023
https://www.ge.com/digital/documentation/predix-platforms/vault-service-managing-paths-secrets.html
https://developer.hashicorp.com/vault/api-docs/auth/token
curl -sS --fail -X POST -d '{"increment": "24h"}' -H "X-Vault-Token: $VAULT_TOKEN" ${VAULT_ADDR}/v1/auth/
token/renew-self
curl -sS -H "X-Vault-Token: $VAULT_TOKEN" https://vault.example.com:8200/v1/auth/token/lookup-self
curl -sS --fail -X POST -d '{"increment": "145h"}' -H "X-Vault-Token: $VAULT_TOKEN" https://vault.example.com:8200/v1/auth/token/renew-self
curl --request POST -d '{"token": "$VAULT_TOKEN"}' -H "X-Vault-Token: $VAULT_TOKEN" https://vault.example.com:8200/v1/auth/token/renew