Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vault Agent: Add option to wait for sealed=false, intialized=true #8970

Closed
avoidik opened this issue May 11, 2020 · 1 comment · Fixed by #9200
Closed

Vault Agent: Add option to wait for sealed=false, intialized=true #8970

avoidik opened this issue May 11, 2020 · 1 comment · Fixed by #9200

Comments

@avoidik
Copy link
Contributor

avoidik commented May 11, 2020

Is your feature request related to a problem? Please describe.

yes, it is related to a synchronization problem, when a vault-agent started it doesn't know about the vault service status (i.e. was it unsealed and initialized), in the same time it is trying to retrieve the data requested by a template no matter of the vault status, in the end transferring the vault-agent systemd service into the dormant state, and the only way to bring it back is to restart the vault-agent systemd service manually

related error

* permission denied (exceeded maximum retries)

comes from - https://github.com/hashicorp/consul-template/blob/master/watch/view.go#L164

Describe the solution you'd like

An additional flag to the vault-agent configuration to define a certain behavior to postpone any operations with the templates up until the vault status becomes unsealed and initialized

vault {
        address = "https://127.0.0.1:8200"
        wait_for_status = FLAG # true - to enabled, false - to disable this behavior
}

Describe alternatives you've considered

there is wait flag available, it might help or might not, vault status might be undetermined after the wait interval ends

Explain any additional use-cases

potential use-case is to render templates with the vault agent on the consul instances of a vault ha cluster where the consul instances being used as storage backend (cyclic dependency)

Additional context

vault-agent being starting as systemd service

@avoidik
Copy link
Contributor Author

avoidik commented May 29, 2020

relevant to #6001 and #8135

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants