mirror of
https://github.com/kubeshark/kubeshark.git
synced 2025-05-01 21:36:02 +00:00
* Remove `logger` module * Remove `shared` module * Move `cli` folder contents into project root * Fix linter * Change the module name from `github.com/kubeshark/kubeshark/cli` to `github.com/kubeshark/kubeshark` * Set the default `Makefile` rule to `build` * Add `lint` rule * Fix the linter errors
30 lines
689 B
Go
30 lines
689 B
Go
package cmd
|
|
|
|
import (
|
|
"log"
|
|
|
|
"github.com/creasty/defaults"
|
|
"github.com/kubeshark/kubeshark/config/configStructs"
|
|
"github.com/spf13/cobra"
|
|
)
|
|
|
|
var installCmd = &cobra.Command{
|
|
Use: "install",
|
|
Short: "Installs kubeshark components",
|
|
RunE: func(cmd *cobra.Command, args []string) error {
|
|
runKubesharkInstall()
|
|
return nil
|
|
},
|
|
}
|
|
|
|
func init() {
|
|
rootCmd.AddCommand(installCmd)
|
|
|
|
defaultInstallConfig := configStructs.InstallConfig{}
|
|
if err := defaults.Set(&defaultInstallConfig); err != nil {
|
|
log.Print(err)
|
|
}
|
|
|
|
installCmd.Flags().BoolP(configStructs.OutInstallName, "o", defaultInstallConfig.Out, "print (to stdout) Kubernetes manifest used to install Kubeshark Pro edition")
|
|
}
|