Documentation ¶
Index ¶
- func NewClusterRESTClientGetter(kubeconfig, namespace string) genericclioptions.RESTClientGetter
- func NewMemoryRESTClientGetter(kubeConfig []byte, namespace string) genericclioptions.RESTClientGetter
- type Executor
- type MemoryRESTClientGetter
- func (c *MemoryRESTClientGetter) ToDiscoveryClient() (discovery.CachedDiscoveryInterface, error)
- func (c *MemoryRESTClientGetter) ToRESTConfig() (*rest.Config, error)
- func (c *MemoryRESTClientGetter) ToRESTMapper() (meta.RESTMapper, error)
- func (c *MemoryRESTClientGetter) ToRawKubeConfigLoader() clientcmd.ClientConfig
- type Option
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewClusterRESTClientGetter ¶
func NewClusterRESTClientGetter(kubeconfig, namespace string) genericclioptions.RESTClientGetter
func NewMemoryRESTClientGetter ¶
func NewMemoryRESTClientGetter(kubeConfig []byte, namespace string) genericclioptions.RESTClientGetter
Types ¶
type Executor ¶
type Executor interface { // Install installs the specified chart and returns the name of the Job that executed the task. Install(ctx context.Context, chartName string, chartData, values []byte) (string, error) // Upgrade upgrades the specified chart and returns the name of the Job that executed the task. Upgrade(ctx context.Context, chartName string, chartData, values []byte) (string, error) // Uninstall is used to uninstall the specified chart and returns the name of the Job that executed the task. Uninstall(ctx context.Context) (string, error) // Manifest returns the manifest data for this release. Manifest() (string, error) // IsReleaseReady checks if the helm release is ready. IsReleaseReady(timeout time.Duration) (bool, error) }
Executor is used to manage a helm release, you can install/uninstall and upgrade a chart or get the status and manifest data of the release, etc.
func NewExecutor ¶
NewExecutor generates a new Executor instance with the following parameters:
- namespace: the namespace of the helm release
- releaseName: the helm release name
- options: functions to set optional parameters
type MemoryRESTClientGetter ¶
type MemoryRESTClientGetter struct {
// contains filtered or unexported fields
}
MemoryRESTClientGetter is an implementation of the genericclioptions.RESTClientGetter.
func (*MemoryRESTClientGetter) ToDiscoveryClient ¶
func (c *MemoryRESTClientGetter) ToDiscoveryClient() (discovery.CachedDiscoveryInterface, error)
func (*MemoryRESTClientGetter) ToRESTConfig ¶
func (c *MemoryRESTClientGetter) ToRESTConfig() (*rest.Config, error)
func (*MemoryRESTClientGetter) ToRESTMapper ¶
func (c *MemoryRESTClientGetter) ToRESTMapper() (meta.RESTMapper, error)
func (*MemoryRESTClientGetter) ToRawKubeConfigLoader ¶
func (c *MemoryRESTClientGetter) ToRawKubeConfigLoader() clientcmd.ClientConfig
type Option ¶
type Option func(*executor)
func SetAnnotations ¶
SetAnnotations sets extra annotations added to all resources in chart.
func SetCreateNamespace ¶
SetCreateNamespace sets the createNamespace option.
func SetHelmImage ¶
SetHelmImage sets the helmImage option.
func SetKubeConfig ¶
SetKubeConfig sets the kube config data of the target cluster.
Click to show internal directories.
Click to hide internal directories.