Hello,
I am trying to understand something about v1beta2 Go client API. Sorry, but I am new to Kubernetes. Please help me out. It says:
// Label selector for pods. Existing ReplicaSets whose pods are
// selected by this will be the ones affected by this deployment.
// It must match the pod template's labels.
Selector *metav1.LabelSelector `json:"selector" protobuf:"bytes,2,opt,name=selector"`
I have a "custom" label, say color that I want to change from blue or green to solve my CD/CI task. From CLI, I can pass --overwrite and kubectl changes the label's value just fine.
When I am trying to use the API to change just the labels, it returns: the "selector does not match template labels" error. What do I need to do for the label change to succeed? How to I make it "match the template?"
I also see https://github.com/kubernetes/kubernetes/pull/50719 and the selector is now immutable. If selector has to match the labels and selector is immutable, how do I change the labels, now?
Right now, it is either the error: `failed to update deployment: Deployment.apps ... field is immutable` when I try to change both `MatchLabels` and `Labels` or ``selector` does not match template `labels``.
What do I need to do for the label to get changed/patched?
Thank you
--
You received this message because you are subscribed to the Google Groups "Kubernetes developer/contributor discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kubernetes-de...@googlegroups.com.
To post to this group, send email to kuberne...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kubernetes-dev/8dba56a5-d04f-4a6f-aad5-2e5c216a1e1f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.