Vault Approle: extend / refresh token lease outside from the application (curl + cron)

hi,

we use Rundeck with the Vault plugin, which works great :slight_smile: But at the moment Rundeck isn’t able to refresh the token with the Approle. So after the lease time (5h), Rundeck isn’t able to connect to the Vault anymore. Sure, I can switch to “token”, but we want to stay with the Approle and we have to restart Rundeck to get a new access token.
My question is: can I do “something” with cUrl + Cron, to refresh the token outside from the Rundeck context ?

cu denny

You can use https://www.vaultproject.io/api/auth/token/index.html#renew-a-token-accessor- in Vault 1.3.0 with an accessor, or you can use https://www.vaultproject.io/api/auth/token/index.html#renew-a-token-self- with any version of Vault if you have the token value.