-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Add WaitForReady flag to check container readiness state before exec a hook #6918
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need changelog file
Created a changelog file or added /kind changelog-not-required as a comment on this pull request.
I think it is possible for someone to have a workload such that it isn't ready until the hook runs to do something such as adding data. Perhaps a new kind of hook could be reasonable.. |
ie. this change can break an existing workload that is only ready by manually running a script when prehook is run on restore. |
@kaovilai @Ripolin or perhaps instead of a new hook type, a new bool field added to https://github.com/vmware-tanzu/velero/blob/main/pkg/apis/velero/v1/restore_types.go#L194 |
Having something like |
Like that 1e211ae ? |
@Ripolin Yes, I was thinking something like that. A couple things, though:
|
Since there can be multiple restore hooks, it looks like setting |
Done both |
@sseago yes I agree, the new behavior needs to be documented. |
Codecov Report
@@ Coverage Diff @@
## main #6918 +/- ##
==========================================
+ Coverage 60.78% 60.80% +0.01%
==========================================
Files 250 250
Lines 26629 26649 +20
==========================================
+ Hits 16187 16204 +17
- Misses 9293 9295 +2
- Partials 1149 1150 +1
|
@Ripolin |
…a hook Signed-off-by: Ripolin <[email protected]>
Squash and rebase done ! |
Thank you for contributing to Velero!
Before running a post restore hook, Velero test the targeted container to check if it's running or not. To me it should be better to check if targeted container is ready to run restore commands.
Please indicate you've done the following:
/kind changelog-not-required
as a comment on this pull request.site/content/docs/main
.