From fc3bf69348190ae45e3bb46ebfbe036c9e080fed Mon Sep 17 00:00:00 2001 From: "M. Mert Yildiran" Date: Mon, 31 Jul 2023 23:09:04 +0300 Subject: [PATCH] :zap: Add `-s` flag to set release namespace into `console`, `proxy` and `scripts` --- cmd/console.go | 1 + cmd/proxy.go | 1 + cmd/scripts.go | 1 + 3 files changed, 3 insertions(+) diff --git a/cmd/console.go b/cmd/console.go index 98250fb10..15539a226 100644 --- a/cmd/console.go +++ b/cmd/console.go @@ -38,6 +38,7 @@ func init() { consoleCmd.Flags().Uint16(configStructs.ProxyHubPortLabel, defaultTapConfig.Proxy.Hub.Port, "Provide a custom port for the Hub") consoleCmd.Flags().String(configStructs.ProxyHostLabel, defaultTapConfig.Proxy.Host, "Provide a custom host for the Hub") + cleanCmd.Flags().StringP(configStructs.ReleaseNamespaceLabel, "s", defaultTapConfig.Release.Namespace, "Release namespace of Kubeshark") } func runConsole() { diff --git a/cmd/proxy.go b/cmd/proxy.go index 7fa8a97b8..b9ce97efe 100644 --- a/cmd/proxy.go +++ b/cmd/proxy.go @@ -27,4 +27,5 @@ func init() { proxyCmd.Flags().Uint16(configStructs.ProxyFrontPortLabel, defaultTapConfig.Proxy.Front.Port, "Provide a custom port for the front-end proxy/port-forward") proxyCmd.Flags().Uint16(configStructs.ProxyHubPortLabel, defaultTapConfig.Proxy.Hub.Port, "Provide a custom port for the Hub proxy/port-forward") proxyCmd.Flags().String(configStructs.ProxyHostLabel, defaultTapConfig.Proxy.Host, "Provide a custom host for the proxy/port-forward") + cleanCmd.Flags().StringP(configStructs.ReleaseNamespaceLabel, "s", defaultTapConfig.Release.Namespace, "Release namespace of Kubeshark") } diff --git a/cmd/scripts.go b/cmd/scripts.go index f7f287021..a4366c56f 100644 --- a/cmd/scripts.go +++ b/cmd/scripts.go @@ -36,6 +36,7 @@ func init() { scriptsCmd.Flags().Uint16(configStructs.ProxyHubPortLabel, defaultTapConfig.Proxy.Hub.Port, "Provide a custom port for the Hub") scriptsCmd.Flags().String(configStructs.ProxyHostLabel, defaultTapConfig.Proxy.Host, "Provide a custom host for the Hub") + cleanCmd.Flags().StringP(configStructs.ReleaseNamespaceLabel, "s", defaultTapConfig.Release.Namespace, "Release namespace of Kubeshark") } func runScripts() {