-
Notifications
You must be signed in to change notification settings - Fork 7
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
Delete NS openstad get stuck on digital ocean #31
Comments
Hello @ToshKoevoets, Thanks for reporting the issue. We have found that this issue is caused by the CRD's of Cert-Manager. These are not being uninstalled and therefore halt the uninstall process. I will work on implementing a fix! |
As a temporary fix, I will share how I resolved it locally:
Here I see that the CRD's of Cert-Manager are still on the cluster. I manually removed all cert-manager CRD's.
I manually did a
After deleting the last Cert-Manager CRD, the namespace finished terminating and disappeared. I will work on a fix that will either keep the CRD's or delete them correctly and automatically. |
Also found this in the Helm Documentation: https://helm.sh/docs/topics/charts/#limitations-on-crds CRDs are never deleted. Deleting a CRD automatically deletes all of the CRD's contents across all namespaces in the cluster. Consequently, Helm will not delete CRDs. Which means we shouldn't delete the CRD's but rather keep them. |
I don't see a good workaround for this bug inside the Helm Charts itself. On the Helm Chart page for Cert-Manager I find next to the For now, I consider this a bug in the Cert-Manager Chart and will create an OpenStad-CRD chart. This makes it so that ClusterIssuer can be installed without multiple steps and prevents hanging on deleting the NS of the OpenStad Chart. In the future, we may want to look into a better option. |
Or actually, as its the only CRD's that are used till now, it may be better to manually install it Cert-Manager instead. |
Interestingly enough I have tried the following and got it working on DigitalOcean: Install:
Upgrade (for ClusterIssuer):
Uninstall:
When I replaced the uninstall step with:
It started hanging and couldn't delete the ns After that I used this to delete the cert-man CRDs:
And it deleted the ns successfully |
I'm not sure when it happens, but it happened twice now, did you have working cers? So it's reproducable. |
I did get working certificates. |
I have added a section in troubleshooting.md for this issue. The fix for when I have deleted the namespace before uninstalling the chart seems to work. But I'm not sure whether there are other causes. (Nor do I know whether the second named cause in troubleshooting.md is relevant) I will not consider this issue fixed yet. If anyone reaches this problem again after following the prevention section under the header |
Causation 2 is an edge case, another but unlikely method to get the same error.
@S-Nigel My bad, I didn't read your comment correctly, the uninstall step I haven't tried, that seems to makes sense that that is the better way to do it. Will try it coming days when I do some debugging. |
@ToshKoevoets No worries. Let me know after you have debugged a bit whether you can find other ways to break it ;) |
Still an issue, helm uninstall doesn't delete the crd's |
This is kinda an interesting issue. From the Helm Documentation:
Operators who want to upgrade or delete CRDs are encouraged to do this manually and with great care. |
I've now had it for second time that NS delete got stuck in terminating phase while deleting from Digital Ocean. Not sure if it's a problem with the repo or with vendor/ way it's installed.
The text was updated successfully, but these errors were encountered: