mirror of
https://github.com/kubeshark/kubeshark.git
synced 2026-05-06 17:27:24 +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
34 lines
964 B
Go
34 lines
964 B
Go
package cmd
|
|
|
|
import (
|
|
"fmt"
|
|
"log"
|
|
"strings"
|
|
|
|
"github.com/kubeshark/kubeshark/bucket"
|
|
"github.com/kubeshark/kubeshark/config"
|
|
)
|
|
|
|
func runKubesharkInstall() {
|
|
// TODO: Remove this function
|
|
if config.Config.Install.Out {
|
|
bucketProvider := bucket.NewProvider(config.Config.Install.TemplateUrl, bucket.DefaultTimeout)
|
|
installTemplate, err := bucketProvider.GetInstallTemplate(config.Config.Install.TemplateName)
|
|
if err != nil {
|
|
log.Printf("Failed getting install template, err: %v", err)
|
|
return
|
|
}
|
|
|
|
fmt.Print(installTemplate)
|
|
return
|
|
}
|
|
|
|
var sb strings.Builder
|
|
sb.WriteString("Hello! This command can be used to install Kubeshark Pro edition on your Kubernetes cluster.")
|
|
sb.WriteString("\nPlease run:")
|
|
sb.WriteString("\n\tkubeshark install -o | kubectl apply -n kubeshark -f -")
|
|
sb.WriteString("\n\nor use helm chart as described in https://getkubeshark.io/docs/installing-kubeshark/centralized-installation\n")
|
|
|
|
fmt.Print(sb.String())
|
|
}
|