-
Notifications
You must be signed in to change notification settings - Fork 92
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
Consolidated CLI design proposal #1144
Conversation
5defb1a
to
54da2b4
Compare
The intention is for troubleshoot to run as a kubectl/krew plugin but for our design I think it's simpler of we focus on the troubleshoot binary alone.
This fits nicer with the other subcommand names
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor comments, let's flesh this out a bit now with some technical detail on what functions need to move to where and how.
Particularly want to know about breaking changes (i.e. changes to functions that other projects are known to import) so that we can ensure these are agreed up-front.
Also; the existing CLI programs need to continue to work, let's identify what needs to happen to achieve that.
The goal here is that we agree on the desired outcome, the breaking changes that introduces, and the path to get to that point.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor comments, let's flesh this out a bit now with some technical detail on what functions need to move to where and how.
Particularly want to know about breaking changes (i.e. changes to functions that other projects are known to import) so that we can ensure these are agreed up-front.
Also; the existing CLI programs need to continue to work, let's identify what needs to happen to achieve that.
The goal here is that we agree on the desired outcome, the breaking changes that introduces, and the path to get to that point.
…hq/troubleshoot into ada/proposal-troubleshoot-cli
Removed imported flags and made things a bit easier to read
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
couple of notes, based on some discussion today
All top level commands (`support-bundle`, `preflight`, `analyze`, `redact`, and `sbctl`) of the Troubleshoot project will now be subcommands e.g `sbctl` is planned to be `troubleshoot inspect`. Some flags and subcommands names may change to best fit completeness of the CLI interface e.g `--interactive=false` will be `--no-input`. Putting the CLI interface together should aim to follow best practises from well known guidelines such as https://clig.dev/ and other mature projects. | ||
|
||
- `troubleshoot inspect` - This subcommand will be equivalent to the `sbctl` command. | ||
- `troubleshoot collect` - This subcommand will be equivalent to the `support-bundle` command. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some discussion around this - let's keep it consistent and have this troubleshoot support-bundle
|
||
## Non-Goals | ||
|
||
- Maintain backward compatibility of the CLI interface and the public APIs (new interfaces will be created) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's add a note to the effect that the existing CLI will remain supported until such time as the new CLI is in common use at least by the Replicated product set.
### Public APIs | ||
|
||
The existing package entrypoint we use from the support-bundle command is `supportbundle.CollectSupportBundleFromSpec()` | ||
which is an end-to-end function that runs collectors, redactors and then analysis. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's be sure to mention that we do not intend to break this entrypoint immediately, but that it is intended that we use this API to allow future versions to make breaking changes to that function.
Co-authored-by: Xav Paice <[email protected]>
Co-authored-by: Xav Paice <[email protected]>
Co-authored-by: Xav Paice <[email protected]>
Co-authored-by: Xav Paice <[email protected]>
Closing until we revisit the proposal |
Description, Motivation and Context
Please include a summary of the change or what problem it solves. Please also include relevant motivation and context.
Checklist
Does this PR introduce a breaking change?