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

Add kubebuilder markers for resource path and shortname #63

Conversation

shubham-pampattiwar
Copy link
Member

@shubham-pampattiwar shubham-pampattiwar commented May 9, 2024

This PR adds kubebuilder markers to support Non-Admin backups CR's short name.

What this means ?
Earlier to fetch non-admin backups CRs you would execute the command
oc get nonadminbackups
After this PR, you could use the shortname nab instead of the fullname nonadminbackups

How to test ?

  • Install the non-admin backup CRD from this PR
  • Try to execute CRUD commands on nonadminbackups CRD/API endpoint using nab shortname instead of full name nonadminbackups
    for example:
    oc get nab

Copy link
Contributor

@mateusoliveira43 mateusoliveira43 left a comment

Choose a reason for hiding this comment

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

No PR description

Please add motivation and how to test

@shubham-pampattiwar
Copy link
Member Author

@mateusoliveira43 I have updated the PR description PTAL, Thanks !

Copy link
Contributor

@mateusoliveira43 mateusoliveira43 left a comment

Choose a reason for hiding this comment

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

tested running

./bin/kustomize-v5.3.0 build config/crd | oc apply -f -
oc get nab
./bin/kustomize-v5.3.0 build config/crd | oc delete -f -

in this branch and master. In master, it errors out error: the server doesn't have a resource type "nab" and in the PR branch it works No resources found in default namespace..
/lgtm

Copy link

openshift-ci bot commented May 13, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: kaovilai, mateusoliveira43, shubham-pampattiwar

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:
  • OWNERS [kaovilai,mateusoliveira43,shubham-pampattiwar]

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

@openshift-merge-bot openshift-merge-bot bot merged commit b521e5c into migtools:master May 13, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Merged / Ready for build
Development

Successfully merging this pull request may close these issues.

3 participants