expose the vault token to jsonnet
For vault scraping, prometheus needs to have access to the vault bearer token from a file
https://medium.com/@mwieczorek/yet-another-vault-monitoring-with-prometheus-blog-post-f525c862baca
We could add a token backend for that purpose that expose the auth response to the template
{
"token.jsonnet": {
"token:str:auth/client_token": "token"
}
}
token.jsonnet
local secrets = std.extVar("secrets");
{
"/tmp/vault-token": secrets["token"]
}
Edited by Éric BURGHARD