mirror of
https://github.com/kubeshark/kubeshark.git
synced 2025-09-21 10:06:58 +00:00
Removed flags without implementation (#38)
This commit is contained in:
@@ -31,11 +31,8 @@ var tapCmd = &cobra.Command{
|
||||
func init() {
|
||||
rootCmd.AddCommand(tapCmd)
|
||||
|
||||
// tapCmd.Flags().BoolVarP(&config.Configuration.Quiet, "quiet", "q", false, "No stdout output")
|
||||
tapCmd.Flags().BoolVarP(&config.Configuration.NoGUI, "no-gui", "", false, "Do not open web interface")
|
||||
tapCmd.Flags().Uint16VarP(&config.Configuration.GuiPort, "gui-port", "p", 8899, "Provide a custom port for the web interface webserver")
|
||||
tapCmd.Flags().StringVarP(&config.Configuration.Namespace, "namespace", "n", "", "Namespace selector")
|
||||
// tapCmd.Flags().BoolVarP(&config.Configuration.AllNamespaces, "all-namespaces", "A", false, "Select all namespaces")
|
||||
tapCmd.Flags().StringVarP(&config.Configuration.KubeConfigPath, "kubeconfig", "k", "", "Path to kubeconfig file")
|
||||
tapCmd.Flags().StringVarP(&config.Configuration.MizuImage, "mizu-image", "", "gcr.io/up9-docker-hub/mizu/develop:latest", "Custom image for mizu collector")
|
||||
tapCmd.Flags().Uint16VarP(&config.Configuration.MizuPodPort, "mizu-port", "", 8899, "Port which mizu cli will attempt to forward from the mizu collector pod")
|
||||
|
@@ -1,7 +1,6 @@
|
||||
package config
|
||||
|
||||
type Options struct {
|
||||
NoGUI bool
|
||||
GuiPort uint16
|
||||
Namespace string
|
||||
KubeConfigPath string
|
||||
|
@@ -76,9 +76,7 @@ func createPodAndPortForward(ctx context.Context, kubernetesProvider *kubernetes
|
||||
isPodReady = true
|
||||
var err error
|
||||
portForward, err = kubernetes.NewPortForward(kubernetesProvider, kubernetesProvider.Namespace, podName, config.Configuration.GuiPort, config.Configuration.MizuPodPort, cancel)
|
||||
if !config.Configuration.NoGUI {
|
||||
fmt.Printf("Web interface is now available at http://localhost:%d\n", config.Configuration.GuiPort)
|
||||
}
|
||||
fmt.Printf("Web interface is now available at http://localhost:%d\n", config.Configuration.GuiPort)
|
||||
if err != nil {
|
||||
fmt.Printf("error forwarding port to pod %s\n", err)
|
||||
cancel()
|
||||
|
Reference in New Issue
Block a user