Remove-k8s doesn't remove storage classes that were created by add-k8s
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
Triaged
|
Low
|
Unassigned |
Bug Description
When a storage class is created by Juju because of add-k8s, issuing remove-k8s does not delete the storage class:
$ kubectl get sc
No resources found in default namespace.
$ juju add-k8s dev-k8s --cloud=devstack --storage=devstack
.
k8s substrate "openstack" added as cloud "dev-k8s" with Cinder Disk default
storage provisioned by the existing "devstack" storage class.
You can now bootstrap to this cloud by running 'juju bootstrap dev-k8s'.
$ kubectl get sc
NAME PROVISIONER AGE
devstack csi-cinderplugin 10s
$ juju remove-k8s dev-k8s
$ kubectl get sc
NAME PROVISIONER AGE
devstack csi-cinderplugin 25s
$ kubectl delete sc devstack
storageclas
Juju should clean up resources that it creates.
description: | updated |
summary: |
- Remove-k8s doesn't remove storage classes that were created for it + Remove-k8s doesn't remove storage classes that were created by add-k8s |
Yeah, this is difficult at the moment because a k8s cluster is modelled as a cloud and there's nothing in the model to record these sorts of k8s specific artefacts. It's a fair chunk of work.