Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewDebugCmd ¶
func NewDebugCmd(streams genericclioptions.IOStreams) *cobra.Command
NewDebugCmd returns a cobra command wrapping DebugOptions
Types ¶
type Config ¶
type Config struct { AgentPort int `yaml:"agentPort,omitempty"` Image string `yaml:"image,omitempty"` DebugAgentDaemonSet string `yaml:"debugAgentDaemonset,omitempty"` DebugAgentNamespace string `yaml:"debugAgentNamespace,omitempty"` Command []string `yaml:"command,omitempty"` PortForward bool `yaml:"portForward,omitempty"` Agentless bool `yaml:"agentless,omitempty"` AgentPodNamePrefix string `yaml:"agentPodNamePrefix,omitempty"` AgentPodNamespace string `yaml:"agentPodNamespace,omitempty"` AgentImage string `yaml:"agentImage,omitempty"` // deprecated AgentPortOld int `yaml:"agent_port,omitempty"` }
type DebugOptions ¶
type DebugOptions struct { // Pod select options Namespace string PodName string // Debug options Image string ContainerName string Command []string AgentPort int AppName string ConfigLocation string Fork bool //used for agentless mode AgentLess bool AgentImage string // agentPodName = agentPodNamePrefix + nodeName AgentPodName string AgentPodNamespace string AgentPodNode string Flags *genericclioptions.ConfigFlags CoreClient coreclient.CoreV1Interface KubeCli *kubernetes.Clientset Args []string Config *restclient.Config // use for port-forward RESTClient *restclient.RESTClient PortForwarder portForwarder Ports []string StopChannel chan struct{} ReadyChannel chan struct{} PortForward bool DebugAgentDaemonSet string DebugAgentNamespace string genericclioptions.IOStreams // contains filtered or unexported fields }
DebugOptions specify how to run debug container in a running pod
func NewDebugOptions ¶
func NewDebugOptions(streams genericclioptions.IOStreams) *DebugOptions
NewDebugOptions new debug options
func (*DebugOptions) Run ¶
func (o *DebugOptions) Run() error
TODO: refactor Run() spaghetti code Run run
Click to show internal directories.
Click to hide internal directories.