Restart task's that uses secrets that rendered throw consultemplate when nomad client restarts #6324
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request was created as replacement for #6059
This PR try solve problem which described in #4226
This is a second our try to push this in nomad mainline, first was declined due huge code changes between 0.8.x and 0.9.x
The key idea of this patch is, in fact that consul-template doesn't persisted it state between nomad agent restarts(for example systemctl restart nomad) and regenerate dynamic secrets(for example https://www.vaultproject.io/docs/secrets/aws/index.html) but in case of restart nomad doesn't inform about this fact tasks(this happens only when agent restarts), and there can be situations when secrets already revoked by vault, but task still running
Some remarks from @nickethier (from #6059) we will fix, after some times
Sorry for our mistake in git branches management :-(