consul-template Vault KV integration
What can I do if I am asked to learn different programming languages very frequently?
Extract substring according to regexp with sed or grep
Is there a POSIX way to shutdown a UNIX machine?
Is there a distance limit for minecart tracks?
Why can't I get pgrep output right to variable on bash script?
New Order #2: Turn My Way
How do you justify more code being written by following clean code practices?
C++ lambda syntax
Capacitor electron flow
Output visual diagram of picture
Are hand made posters acceptable in Academia?
Why would five hundred and five same as one?
What do the positive and negative (+/-) transmit and receive pins mean on Ethernet cables?
Is this saw blade faulty?
Pre-Employment Background Check With Consent For Future Checks
Friend wants my recommendation but I don't want to give it to him
Connection Between Knot Theory and Number Theory
Non-Borel set in arbitrary metric space
Is there any common country to visit for persons holding UK and Schengen visas?
Reason why a kingside attack is not justified
Turning a hard to access nut?
How do I prevent inappropriate ads from appearing in my game?
I keep switching characters, how do I stop?
Why is indicated airspeed rather than ground speed used during the takeoff roll?
consul-template Vault KV integration
I'm trying to pull Vault secrets from the KV store. I wish to do 2 things:
When using Vault in non-dev mode, we get Vault KV version 1 (since versions are not displayed while updating a secret). I want
consul-template
to pull secrets from KV v1 automatically when it is updated in Vault, which is not happening.When using dev mode, we get KV version 2 (as versions are maintained on each secret update).
consul-template
successfully update pulls the secrets after some time and update the destination config file automatically without restartingconsul-tempate
.
Questions:
- How can I use
consul-template
with KV v1 with automatic secret updates? - How can we reduce the time to update the destination configs via
consul-template
whenever secrets are updated in KV v2 store.
Below are my configs:
consul-template.hcl
vault {
address = "http://localhost:8200"
token = "x.xxxxxxxxxxxxx"
renew_token = true
}
template {
source = "./templates/config.ctmpl"
destination = "./templates/config.txt"
}
config.ctmpl
{{ with secret "secret/data/database" }}{{ .Data.data.url }}{{ end }}
Command:
vault kv put secret/database url=me.example.com
Vault v1.0.3
consul-template v0.20.0
consul vault
New contributor
add a comment |
I'm trying to pull Vault secrets from the KV store. I wish to do 2 things:
When using Vault in non-dev mode, we get Vault KV version 1 (since versions are not displayed while updating a secret). I want
consul-template
to pull secrets from KV v1 automatically when it is updated in Vault, which is not happening.When using dev mode, we get KV version 2 (as versions are maintained on each secret update).
consul-template
successfully update pulls the secrets after some time and update the destination config file automatically without restartingconsul-tempate
.
Questions:
- How can I use
consul-template
with KV v1 with automatic secret updates? - How can we reduce the time to update the destination configs via
consul-template
whenever secrets are updated in KV v2 store.
Below are my configs:
consul-template.hcl
vault {
address = "http://localhost:8200"
token = "x.xxxxxxxxxxxxx"
renew_token = true
}
template {
source = "./templates/config.ctmpl"
destination = "./templates/config.txt"
}
config.ctmpl
{{ with secret "secret/data/database" }}{{ .Data.data.url }}{{ end }}
Command:
vault kv put secret/database url=me.example.com
Vault v1.0.3
consul-template v0.20.0
consul vault
New contributor
add a comment |
I'm trying to pull Vault secrets from the KV store. I wish to do 2 things:
When using Vault in non-dev mode, we get Vault KV version 1 (since versions are not displayed while updating a secret). I want
consul-template
to pull secrets from KV v1 automatically when it is updated in Vault, which is not happening.When using dev mode, we get KV version 2 (as versions are maintained on each secret update).
consul-template
successfully update pulls the secrets after some time and update the destination config file automatically without restartingconsul-tempate
.
Questions:
- How can I use
consul-template
with KV v1 with automatic secret updates? - How can we reduce the time to update the destination configs via
consul-template
whenever secrets are updated in KV v2 store.
Below are my configs:
consul-template.hcl
vault {
address = "http://localhost:8200"
token = "x.xxxxxxxxxxxxx"
renew_token = true
}
template {
source = "./templates/config.ctmpl"
destination = "./templates/config.txt"
}
config.ctmpl
{{ with secret "secret/data/database" }}{{ .Data.data.url }}{{ end }}
Command:
vault kv put secret/database url=me.example.com
Vault v1.0.3
consul-template v0.20.0
consul vault
New contributor
I'm trying to pull Vault secrets from the KV store. I wish to do 2 things:
When using Vault in non-dev mode, we get Vault KV version 1 (since versions are not displayed while updating a secret). I want
consul-template
to pull secrets from KV v1 automatically when it is updated in Vault, which is not happening.When using dev mode, we get KV version 2 (as versions are maintained on each secret update).
consul-template
successfully update pulls the secrets after some time and update the destination config file automatically without restartingconsul-tempate
.
Questions:
- How can I use
consul-template
with KV v1 with automatic secret updates? - How can we reduce the time to update the destination configs via
consul-template
whenever secrets are updated in KV v2 store.
Below are my configs:
consul-template.hcl
vault {
address = "http://localhost:8200"
token = "x.xxxxxxxxxxxxx"
renew_token = true
}
template {
source = "./templates/config.ctmpl"
destination = "./templates/config.txt"
}
config.ctmpl
{{ with secret "secret/data/database" }}{{ .Data.data.url }}{{ end }}
Command:
vault kv put secret/database url=me.example.com
Vault v1.0.3
consul-template v0.20.0
consul vault
consul vault
New contributor
New contributor
New contributor
asked 20 secs ago
Janshair KhanJanshair Khan
101
101
New contributor
New contributor
add a comment |
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "2"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Janshair Khan is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f959062%2fconsul-template-vault-kv-integration%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Janshair Khan is a new contributor. Be nice, and check out our Code of Conduct.
Janshair Khan is a new contributor. Be nice, and check out our Code of Conduct.
Janshair Khan is a new contributor. Be nice, and check out our Code of Conduct.
Janshair Khan is a new contributor. Be nice, and check out our Code of Conduct.
Thanks for contributing an answer to Server Fault!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f959062%2fconsul-template-vault-kv-integration%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown