-
Notifications
You must be signed in to change notification settings - Fork 270
🐛 Fix nil pointer reference during bastion deletion #1231
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
🐛 Fix nil pointer reference during bastion deletion #1231
Conversation
✅ Deploy Preview for kubernetes-sigs-cluster-api-openstack ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
Hi @mkjpryor. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
This is currently blocking me from upgrading to the |
/ok-to-test |
/ok-to-test |
So once |
So the edge case I think you were worried about is if However, given the fact that the spec is immutable, it seems a lot like we can just not bother reconciling the bastion at all when |
However the case where |
So it turns out you can go from Not sure what the implications are for the edge cases from that, and don't have time to think about them now until after the weekend unfortunately. It seems like the proper solution would be to allow |
Having said all that, at the moment it isn’t even possible to make a cluster without a bastion which seems worse than these edge cases… 🤕 |
Looking at the code for |
I'm going to revisit this because idempotent delete is something I'm very keen on for a number of reasons (for example moving the somewhat complicated port cleanup out of create). However, lets not hold up this real fix for that. /approve |
@mdbooth Thanks for approving. I appreciate that this still leaves some edge cases when bastion instance creation fails that may cause issues, but that is better than not being able to create clusters without bastions at all IMHO. Is it worth just creating an issue for the idempotent instance deletion, which as you say is the real fix, so it doesn’t get forgotten about? I think it just needs a second review and the hold removing then it can be merged. Any thoughts on when we can do a 0.6.2 containing this change? It is a bit of a showstopper for us using the 0.6.x releases. |
Any chance we can get this reviewed, merged and in a point release ASAP? It is a bit of a showstopper so hopefully you agree getting that done quickly is appropriate 🙂 I’m currently running the fix in my staging environment with no issues, but would prefer to run an actual release in prod. |
/lgtm |
/lgtm @mkjpryor once you remove the hold the PR will be merged. IMO we can cut another patch release in the next days, this is a critical bug. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: mdbooth, mkjpryor, seanschneeweiss The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/hold cancel @seanschneeweiss @apricote Thanks! As @mdbooth says, this is not the final fix as it leaves some edge cases unsolved when bastion creation fails. However fixing that properly would require a rewrite of the machine deletion to be idempotent I think. |
/cherry-pick release-0.6 |
@mdbooth: new pull request created: #1232 In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
What this PR does / why we need it:
Fixes a nil pointer reference when a cluster does not have a bastion configured.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #1230
Special notes for your reviewer:
TODOs:
/hold