cmd: Hint the user about the list command
Make the user to use 'lokoctl component list' to list the available
components manually rather than listing them automatically for them
when they don't provide the right component name with
'lokoctl component install'.
@@ -25,7 +25,7 @@ func init() {
func runInstall(cmd *cobra.Command, args []string) {
contextLogger := log.WithFields(log.Fields{
- "command": "lokoctl components install",
+ "command": "lokoctl component install",
"namespace": namespace,
"args": args,
})
@@ -36,7 +36,7 @@ func runInstall(cmd *cobra.Command, args []string) {
c, err := components.Get(args[0])
if err != nil {
- contextLogger.Fatalf("No such component %q: %q. Must be one of: %q", args[0], err, components.List())
+ contextLogger.Fatalf("No such component %q: %q. See 'lokoctl component list' for available components", args[0], err)
}
installOpts := &components.InstallOptions{
