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

Mock kubebuilder integration with 'operator-sdk alpha kubebuilder' cmd #2396

Merged
merged 1 commit into from
Jan 13, 2020

Conversation

hasbro17
Copy link
Contributor

Description of the change:

  • Added a hidden subcommand operator-sdk alpha kubebuilder ... that calls out to the kubebuilder binary for Kubebuilder cmds, e.g:
    • operator-sdk alpha kubebuilder init ==> kubebuilder init.
  • SDK specific subcommands are not shimmed out to the kubebuilder binary and will be handled separately, e.g:
    • operator-sdk alpha kubebuilder olm-catalog gen-csv ...
  • Flags for Kubebuilder specific subcommands are passed in via the flag --kb-flags, e.g:
    • operator-sdk alpha kubebuilder create api --kb-flags="--group cache --version v1 --kind Memcached"
  • Updated ExecCmd() util to read from stdin for kubebuilder command prompts.

Motivation for the change:
While the upstream proposal for Kubebuilder CLI extensibility is under consideration this mock integration provides a starting point to work on aligning the SDK specific commands like olm-catalog gen-csv, scorecard and test.
This will be replaced by whatever the final plugin interface ends up being.

See kubebuilder-integration proposal.

@hasbro17 hasbro17 added the kubebuilder-integration Relates to rewriting the SDK in Kubebuilder plugin form label Jan 13, 2020
@openshift-ci-robot openshift-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Jan 13, 2020
Copy link
Member

@joelanford joelanford left a comment

Choose a reason for hiding this comment

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

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Jan 13, 2020
Copy link
Member

@estroz estroz left a comment

Choose a reason for hiding this comment

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

/lgtm

@hasbro17 hasbro17 merged commit 70856cf into operator-framework:master Jan 13, 2020
@hasbro17 hasbro17 deleted the mock-kb-integration branch January 13, 2020 19:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kubebuilder-integration Relates to rewriting the SDK in Kubebuilder plugin form lgtm Indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants