Skip to content
This repository has been archived by the owner on Jun 18, 2022. It is now read-only.

rio uninstall does not cleanup all the rio resources #613

Closed
rancher-max opened this issue Oct 28, 2019 · 7 comments
Closed

rio uninstall does not cleanup all the rio resources #613

rancher-max opened this issue Oct 28, 2019 · 7 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@rancher-max
Copy link
Contributor

Describe the bug
Running rio uninstall leaves some rio resources in the cluster.

To Reproduce

  1. Run rio uninstall in a cluster that has rio installed.
    It removes everything from kubectl api-resources and kubectl get crds -A as expected, but there are three unexpected items with kubectl get clusterroles -A:
...
rio-rio-system-autoscaler                                              2d14h
rio-rio-system-cert-manager                                            2d14h
rio-rio-system-webhook                                                 2d14h
...

Running kubectl get validatingwebhookconfigurations.admissionregistration.k8s.io -A yields No resources found as expected.

Kubernetes version & type (GKE, on-prem): kubectl version -- multiple versions, but most recently:

Client Version: version.Info{Major:"1", Minor:"16", GitVersion:"v1.16.0", GitCommit:"2bd9643cee5b3b3a5ecbd3af49d09018f0773c77", GitTreeState:"clean", BuildDate:"2019-09-19T13:57:45Z", GoVersion:"go1.12.9", Compiler:"gc", Platform:"darwin/amd64"}
Server Version: version.Info{Major:"1", Minor:"16", GitVersion:"v1.16.2", GitCommit:"c97fe5036ef3df2967d086711e6c0c405941e14b", GitTreeState:"clean", BuildDate:"2019-10-15T19:09:08Z", GoVersion:"go1.12.10", Compiler:"gc", Platform:"linux/amd64"}

Rio version: rio info
Uninstalled, but this was on v0.6.0-alpha.1

@rancher-max
Copy link
Contributor Author

Also, kubectl get clusterrolebindings leaves these resoures as well:

...
rio-rio-system-cert-manager-rio-rio-system-cert-manager   4d
rio-rio-system-autoscaler-rio-rio-system-autoscaler       4d
rio-rio-system-webhook-rio-rio-system-webhook             4d
...

@davidnuzik davidnuzik added this to the v0.6.x milestone Nov 1, 2019
@davidnuzik davidnuzik added [zube]: To Triage bug Something isn't working labels Nov 1, 2019
@rancher-max
Copy link
Contributor Author

Also does not remove any secrets that were added with rio (githubtoken in my case)

@daxmc99
Copy link
Contributor

daxmc99 commented Nov 27, 2019

Rio uninstall should wait for CRDS to be cleaned up before deleting the controller. This avoids cert-manager CRDS blocking rio-system ns deletion.

@StrongMonkey
Copy link
Contributor

@rancher-max Available to test in master.

@rancher-max
Copy link
Contributor Author

This gave a fatal error, but actually did clean up the resources. We should remove the FATAL though:

$ rio uninstall
Waiting for linkerd uninstall job to be finished
Cleaning up CRDs...
Deleting System Namespace rio-system...
Delete validating webhook
FATA[0049] clusterroles.rbac.authorization.k8s.io "rio-privileged" not found 

@daxmc99
Copy link
Contributor

daxmc99 commented Dec 10, 2019

Riofile that I used for testing https://github.com/daxmc99/rio-demo/tree/rio-permissions-test

@rancher-max
Copy link
Contributor Author

Looks like it's all fixed! Uninstalling and reinstalling successfully, and resources are cleaned up on uninstall.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants