Skip to content
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

Adds the recommended k8s labels to lvmo pods #217

Merged
merged 2 commits into from
Jun 24, 2022
Merged

Adds the recommended k8s labels to lvmo pods #217

merged 2 commits into from
Jun 24, 2022

Conversation

nbalacha
Copy link
Contributor

No description provided.

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 23, 2022
Copy link
Contributor

@sp98 sp98 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might want to update the selector labels in the service as well

TopolvmControllerLabelVal = "topolvm-controller"
TopolvmNodeLabelVal = "topolvm-node"
VGManagerLabelVal = "vg-manager"
ManagedByLabelValue = "lvm-operator"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some variables end with val and some with value. We should make it consistent.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

// labels and values

// AppKubernetesPartOfLabel is the Kubernetes recommended part-of label
AppKubernetesPartOfLabel = "app.kubernetes.io/part-of"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit. Label keys could end with with key. AppKubernetesPartOfLabelKey or PartOfLabelKey

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can leave it as it is.

This commit adds the recommended k8s labels listed in the link
https://kubernetes.io/docs/concepts/overview/working-with-objects/common-labels
to the pods and services. Other resources will be labeled in the
future.

Signed-off-by: N Balachandran <[email protected]>
This commit updates the bundle manifests with the newly
added recommended kubernetes labels.

Signed-off-by: N Balachandran <[email protected]>
@nbalacha
Copy link
Contributor Author

NAME                                                              READY   STATUS      RESTARTS   AGE    LABELS
lvm-operator-controller-manager-85bf85957f-89l8k                  3/3     Running     0          125m   app.kubernetes.io/component=lvm-operator,app.kubernetes.io/name=lvm-operator,app.kubernetes.io/part-of=odf-lvm-provisioner,exporter=lvm-operator,pod-template-hash=85bf85957f
topolvm-controller-658b8c89d9-sgbrk                               5/5     Running     0          122m   app.kubernetes.io/component=topolvm-csi-driver,app.kubernetes.io/managed-by=lvm-operator,app.kubernetes.io/name=topolvm-controller,app.kubernetes.io/part-of=odf-lvm-provisioner,pod-template-hash=658b8c89d9
topolvm-node-4xkmm                                                4/4     Running     0          122m   app.kubernetes.io/component=topolvm-csi-driver,app.kubernetes.io/managed-by=lvm-operator,app.kubernetes.io/name=topolvm-node,app.kubernetes.io/part-of=odf-lvm-provisioner,controller-revision-hash=754f4b64c4,pod-template-generation=1
vg-manager-zzc8v                                                  1/1     Running     0          122m   app.kubernetes.io/component=vg-manager,app.kubernetes.io/managed-by=lvm-operator,app.kubernetes.io/name=vg-manager,app.kubernetes.io/part-of=odf-lvm-provisioner,controller-revision-hash=688768987b,pod-template-generation=1

@nbalacha nbalacha requested a review from sp98 June 24, 2022 04:55
@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jun 24, 2022
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 24, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: nbalacha, sp98

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot merged commit 9c6ae94 into openshift:main Jun 24, 2022
@nbalacha
Copy link
Contributor Author

/cherry-pick release-4.11

@openshift-cherrypick-robot

@nbalacha: #217 failed to apply on top of branch "release-4.11":

Applying: fix: adds the recommended k8s labels
Applying: fix: update the bundle manifests
Using index info to reconstruct a base tree...
M	bundle/manifests/lvm-operator-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml
M	bundle/manifests/lvm-operator.clusterserviceversion.yaml
Falling back to patching base and 3-way merge...
Auto-merging bundle/manifests/lvm-operator.clusterserviceversion.yaml
CONFLICT (content): Merge conflict in bundle/manifests/lvm-operator.clusterserviceversion.yaml
Auto-merging bundle/manifests/lvm-operator-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml
CONFLICT (content): Merge conflict in bundle/manifests/lvm-operator-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0002 fix: update the bundle manifests
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".

In response to this:

/cherry-pick release-4.11

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@nbalacha nbalacha deleted the labels branch September 6, 2022 04:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants