Application status could indicate service failures
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Kubernetes Control Plane Charm |
Triaged
|
High
|
Unassigned | ||
Openstack Integrator Charm |
Triaged
|
High
|
Unassigned |
Bug Description
After deploying the integrator to a cluster, 'juju status' suggests all is well:
App Version Status Scale Charm Store Rev OS Notes
openstack-
Unit Workload Agent Machine Public address Ports Message
openstack-
And the storage class certainly shows up:
$ kubectl get sc --all-namespaces
NAME PROVISIONER AGE
cdk-cinder csi-cinderplugin 9d
But on closer inspection:
$ kubectl get po --all-namespaces | grep csi-cinder
kube-system csi-cinder-
kube-system csi-cinder-
kube-system csi-cinder-
See LP:1868368 for the above issue itself, but is it possible (and if so, is it a good idea) for the charm to notice that the pods haven't started, and adjust application status to e.g. "blocked"?
description: | updated |
tags: | added: canonical-is |
Changed in charm-kubernetes-master: | |
importance: | Undecided → High |
Changed in charm-openstack-integrator: | |
importance: | Undecided → High |
Changed in charm-kubernetes-master: | |
status: | New → Triaged |
Changed in charm-openstack-integrator: | |
status: | New → Triaged |
Pods mentioned in the description (along with some other k8s resources) are currently "managed" by cdk-addons. integrator" joins with "kubernetes- master" , the k8s-master executes "cdk-addons" with parameter "openstack- enabled= true" which deploys appropriate k8s resources. However, there's no mechanism that would let "kubernetes-master" unit know which resources were created so it can not monitor if they were created successfully.
When "openstack-
There's currently an effort to make cdk-addons obsolete and replace them with standalone charms. I think that instead of inventing a mechanism that would let "kubernetes-master" know which kubernetes resources were created by cdk-addons, we could instead make it a responsibility of "openstack- integrator" to create and monitor these resources. integrator" and using k8s API to directly create resources from the charm.
In practice, this would involve moving k8s resource templates from cdk-addons to "openstack-
There's only one drawback to this approach, we would have to require that the "openstack- integrator" is a subordinate charm of the "kubernetes-master" so that it can have direct access to the kube config, and use kubernetes API directly.
What do you all think about this approach?