Documentation ¶
Overview ¶
Package cmd provides viper/cobra for shared command line flags
Index ¶
- func AddEnvToUsage(cmd *cobra.Command, argToEnv map[string]string)
- func ApplyCRDs(ctx context.Context, apply ApplyFn, restConfig *rest.Config) error
- func ApplyCRDsFlags(pf *flag.FlagSet, argToEnv map[string]string)
- func CtxTimeOut(cfg *config.Config)
- func CtxTimeOutFlags(pf *flag.FlagSet, argToEnv map[string]string)
- func DockerImage() error
- func DockerImageFlags(pf *flag.FlagSet, argToEnv map[string]string, repo string, tag string)
- func GenCLIDocsyMarkDown(cmd *cobra.Command, docDir string) error
- func KubeConfig(log *zap.SugaredLogger) (*rest.Config, error)
- func KubeConfigFlags(pf *flag.FlagSet, argToEnv map[string]string)
- func LogLevel() string
- func LoggerFlags(pf *flag.FlagSet, argToEnv map[string]string)
- func Meltdown(cfg *config.Config)
- func MeltdownFlags(pf *flag.FlagSet, argToEnv map[string]string)
- func MonitoredID(cfg *config.Config)
- func MonitoredIDFlags(pf *flag.FlagSet, argToEnv map[string]string)
- func OperatorNamespace(cfg *config.Config, log *zap.SugaredLogger, name string) string
- func OperatorNamespaceFlags(pf *flag.FlagSet, argToEnv map[string]string, name string)
- type ApplyFn
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddEnvToUsage ¶
AddEnvToUsage adds env variables to help
func ApplyCRDsFlags ¶
ApplyCRDsFlags adds to viper flags
func CtxTimeOut ¶
CtxTimeOut sets the context timeout from viper
func CtxTimeOutFlags ¶
CtxTimeOutFlags adds to viper flags
func DockerImage ¶
func DockerImage() error
DockerImage sets the docker image, which the operator uses to execute commands in pods
func DockerImageFlags ¶
DockerImageFlags adds to viper flags
func GenCLIDocsyMarkDown ¶
GenCLIDocsyMarkDown generates docsy-markdown files from cobra commands
func KubeConfig ¶
func KubeConfig(log *zap.SugaredLogger) (*rest.Config, error)
KubeConfig uses kubeconfig pkg to return a valid kube config
func KubeConfigFlags ¶
KubeConfigFlags adds to viper flags
func LoggerFlags ¶
LoggerFlags adds to viper flags
func MeltdownFlags ¶
MeltdownFlags adds to viper flags
func MonitoredIDFlags ¶
MonitoredIDFlags adds to viper flags
func OperatorNamespace ¶
OperatorNamespace is the namespace of the service, which points to the webhook server