action

package
v1.17.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 13, 2025 License: Apache-2.0 Imports: 62 Imported by: 17

Documentation

Index

Constants

View Source
const (
	DefaultReleaseGetOutputFormat = common.OutputFormatYAML
	DefaultReleaseGetLogLevel     = log.ErrorLevel
)
View Source
const (
	DefaultReleaseListOutputFormat = common.OutputFormatTable
	DefaultReleaseListLogLevel     = log.ErrorLevel
)
View Source
const (
	DefaultVersionOutputFormat = common.OutputFormatYAML
	DefaultVersionLogLevel     = log.ErrorLevel
)
View Source
const (
	DefaultChartLintLogLevel = log.InfoLevel
)
View Source
const (
	DefaultChartRenderLogLevel = log.ErrorLevel
)
View Source
const (
	DefaultLegacyReleaseUninstallLogLevel = log.InfoLevel
)
View Source
const (
	DefaultReleaseInstallLogLevel = log.InfoLevel
)
View Source
const (
	DefaultReleasePlanInstallLogLevel = log.InfoLevel
)
View Source
const (
	DefaultReleaseRollbackLogLevel = log.InfoLevel
)
View Source
const (
	DefaultReleaseUninstallLogLevel = log.InfoLevel
)
View Source
const (
	DefaultSecretFileDecryptLogLevel = log.ErrorLevel
)
View Source
const (
	DefaultSecretFileEditLogLevel = log.ErrorLevel
)
View Source
const (
	DefaultSecretFileEncryptLogLevel = log.ErrorLevel
)
View Source
const (
	DefaultSecretKeyCreateLogLevel = log.ErrorLevel
)
View Source
const (
	DefaultSecretKeyRotateLogLevel = log.InfoLevel
)
View Source
const (
	DefaultSecretValuesFileDecryptLogLevel = log.ErrorLevel
)
View Source
const (
	DefaultSecretValuesFileEditLogLevel = log.ErrorLevel
)
View Source
const (
	DefaultSecretValuesFileEncryptLogLevel = log.ErrorLevel
)

Variables

View Source
var ErrChangesPlanned = errors.New("changes planned")

Functions

func ChartLint

func ChartLint(ctx context.Context, opts ChartLintOptions) error

func LegacyReleaseUninstall added in v1.5.0

func LegacyReleaseUninstall(ctx context.Context, releaseName, releaseNamespace string, opts LegacyReleaseUninstallOptions) error

func ReleaseInstall

func ReleaseInstall(ctx context.Context, releaseName, releaseNamespace string, opts ReleaseInstallOptions) error

func ReleasePlanInstall

func ReleasePlanInstall(ctx context.Context, releaseName, releaseNamespace string, opts ReleasePlanInstallOptions) error

func ReleaseRollback

func ReleaseRollback(ctx context.Context, releaseName, releaseNamespace string, opts ReleaseRollbackOptions) error

func ReleaseUninstall

func ReleaseUninstall(ctx context.Context, releaseName, releaseNamespace string, opts ReleaseUninstallOptions) error

func SecretFileDecrypt

func SecretFileDecrypt(ctx context.Context, filePath string, opts SecretFileDecryptOptions) error

func SecretFileEdit

func SecretFileEdit(ctx context.Context, filePath string, opts SecretFileEditOptions) error

func SecretFileEncrypt

func SecretFileEncrypt(ctx context.Context, filePath string, opts SecretFileEncryptOptions) error

func SecretKeyCreate

func SecretKeyCreate(ctx context.Context, opts SecretKeyCreateOptions) (string, error)

func SecretKeyRotate

func SecretKeyRotate(ctx context.Context, opts SecretKeyRotateOptions) error

func SecretValuesFileDecrypt

func SecretValuesFileDecrypt(ctx context.Context, valuesFilePath string, opts SecretValuesFileDecryptOptions) error

func SecretValuesFileEdit

func SecretValuesFileEdit(ctx context.Context, valuesFilePath string, opts SecretValuesFileEditOptions) error

func SecretValuesFileEncrypt

func SecretValuesFileEncrypt(ctx context.Context, valuesFilePath string, opts SecretValuesFileEncryptOptions) error

Types

type ChartLintOptions

type ChartLintOptions struct {
	common.KubeConnectionOptions
	common.ChartRepoConnectionOptions
	common.ValuesOptions
	common.SecretValuesOptions

	Chart                       string
	ChartAppVersion             string
	ChartDirPath                string // TODO(v2): get rid
	ChartProvenanceKeyring      string
	ChartProvenanceStrategy     string
	ChartRepoSkipUpdate         bool
	ChartVersion                string
	DefaultChartAPIVersion      string
	DefaultChartName            string
	DefaultChartVersion         string
	ExtraAPIVersions            []string
	ExtraAnnotations            map[string]string
	ExtraLabels                 map[string]string
	ExtraRuntimeAnnotations     map[string]string
	ExtraRuntimeLabels          map[string]string
	ForceAdoption               bool
	LegacyChartType             helmopts.ChartType
	LegacyExtraValues           map[string]interface{}
	LegacyLogRegistryStreamOut  io.Writer
	LocalKubeVersion            string
	NetworkParallelism          int
	NoFinalTracking             bool
	NoRemoveManualChanges       bool
	RegistryCredentialsPath     string
	ReleaseName                 string
	ReleaseNamespace            string
	ReleaseStorageDriver        string
	ReleaseStorageSQLConnection string
	Remote                      bool
	TempDirPath                 string
	TemplatesAllowDNS           bool
}

type ChartRenderOptions

type ChartRenderOptions struct {
	common.KubeConnectionOptions
	common.ChartRepoConnectionOptions
	common.ValuesOptions
	common.SecretValuesOptions

	Chart                       string
	ChartAppVersion             string
	ChartDirPath                string // TODO(v2): get rid
	ChartProvenanceKeyring      string
	ChartProvenanceStrategy     string
	ChartRepoSkipUpdate         bool
	ChartVersion                string
	DefaultChartAPIVersion      string
	DefaultChartName            string
	DefaultChartVersion         string
	ExtraAPIVersions            []string
	ExtraAnnotations            map[string]string
	ExtraLabels                 map[string]string
	ExtraRuntimeAnnotations     map[string]string // TODO(v2): get rid?? or do custom logic
	ForceAdoption               bool              // TODO(v2): get rid, useless
	LegacyChartType             helmopts.ChartType
	LegacyExtraValues           map[string]interface{}
	LegacyLogRegistryStreamOut  io.Writer
	LocalKubeVersion            string
	NetworkParallelism          int
	OutputFilePath              string
	OutputNoPrint               bool
	RegistryCredentialsPath     string
	ReleaseName                 string
	ReleaseNamespace            string
	ReleaseStorageDriver        string
	ReleaseStorageSQLConnection string
	Remote                      bool
	ShowOnlyFiles               []string
	ShowStandaloneCRDs          bool
	TempDirPath                 string
	TemplatesAllowDNS           bool
}

type ChartRenderResultV2 added in v1.13.0

type ChartRenderResultV2 struct {
	APIVersion string               `json:"apiVersion,omitempty"`
	Resources  []*spec.ResourceSpec `json:"resources,omitempty"`
}

type LegacyReleaseUninstallOptions added in v1.5.0

type LegacyReleaseUninstallOptions struct {
	common.KubeConnectionOptions
	common.TrackingOptions

	NoDeleteHooks          bool
	DeleteReleaseNamespace bool
	NetworkParallelism     int
	ReleaseHistoryLimit    int
	ReleaseStorageDriver   string
	TempDirPath            string
	Timeout                time.Duration
}

type ReleaseGetOptions

type ReleaseGetOptions struct {
	common.KubeConnectionOptions

	NetworkParallelism          int
	OutputFormat                string
	OutputNoPrint               bool
	PrintValues                 bool
	ReleaseStorageDriver        string
	ReleaseStorageSQLConnection string
	Revision                    int
	TempDirPath                 string
}

type ReleaseGetResultChart

type ReleaseGetResultChart struct {
	Name       string `json:"name"`
	Version    string `json:"version"`
	AppVersion string `json:"appVersion"`
}

type ReleaseGetResultDeployedAt

type ReleaseGetResultDeployedAt struct {
	Human string `json:"human"`
	Unix  int    `json:"unix"`
}

TODO(v2): get rid

type ReleaseGetResultRelease

type ReleaseGetResultRelease struct {
	Name          string                      `json:"name"`
	Namespace     string                      `json:"namespace"`
	Revision      int                         `json:"revision"`
	Status        helmrelease.Status          `json:"status"`
	DeployedAt    *ReleaseGetResultDeployedAt `json:"deployedAt"`
	Annotations   map[string]string           `json:"annotations"`
	StorageLabels map[string]string           `json:"storageLabels"`
}

type ReleaseGetResultV1

type ReleaseGetResultV1 struct {
	APIVersion string                   `json:"apiVersion"`
	Release    *ReleaseGetResultRelease `json:"release"`
	Chart      *ReleaseGetResultChart   `json:"chart"`
	Notes      string                   `json:"notes,omitempty"`
	Values     map[string]interface{}   `json:"values,omitempty"`
	// TODO(v2): Join Hooks and Resources together as ResourceSpecs?
	Hooks     []map[string]interface{} `json:"hooks,omitempty"`
	Resources []map[string]interface{} `json:"resources,omitempty"`
}

func ReleaseGet

func ReleaseGet(ctx context.Context, releaseName, releaseNamespace string, opts ReleaseGetOptions) (*ReleaseGetResultV1, error)

type ReleaseInstallOptions

type ReleaseInstallOptions struct {
	common.KubeConnectionOptions
	common.ChartRepoConnectionOptions
	common.ValuesOptions
	common.SecretValuesOptions
	common.TrackingOptions

	AutoRollback                bool
	Chart                       string
	ChartAppVersion             string
	ChartDirPath                string // TODO(v2): get rid
	ChartProvenanceKeyring      string
	ChartProvenanceStrategy     string
	ChartRepoSkipUpdate         bool
	ChartVersion                string
	DefaultChartAPIVersion      string
	DefaultChartName            string
	DefaultChartVersion         string
	ExtraAnnotations            map[string]string
	ExtraLabels                 map[string]string
	ExtraRuntimeAnnotations     map[string]string
	ExtraRuntimeLabels          map[string]string
	ForceAdoption               bool
	InstallGraphPath            string
	InstallReportPath           string
	LegacyChartType             helmopts.ChartType
	LegacyExtraValues           map[string]interface{}
	LegacyLogRegistryStreamOut  io.Writer
	NetworkParallelism          int
	NoInstallStandaloneCRDs     bool
	NoRemoveManualChanges       bool
	NoShowNotes                 bool
	RegistryCredentialsPath     string
	ReleaseHistoryLimit         int
	ReleaseInfoAnnotations      map[string]string
	ReleaseLabels               map[string]string
	ReleaseStorageDriver        string
	ReleaseStorageSQLConnection string
	RollbackGraphPath           string
	ShowSubchartNotes           bool
	TempDirPath                 string
	TemplatesAllowDNS           bool
	Timeout                     time.Duration
}

type ReleaseListOptions added in v1.5.0

type ReleaseListOptions struct {
	common.KubeConnectionOptions

	NetworkParallelism          int
	OutputFormat                string
	OutputNoPrint               bool
	ReleaseNamespace            string
	ReleaseStorageDriver        string
	ReleaseStorageSQLConnection string
	TempDirPath                 string
}

type ReleaseListResultChart added in v1.5.0

type ReleaseListResultChart struct {
	Name       string `json:"name"`
	Version    string `json:"version"`
	AppVersion string `json:"appVersion"`
}

type ReleaseListResultDeployedAt added in v1.5.0

type ReleaseListResultDeployedAt struct {
	Human string `json:"human"`
	Unix  int    `json:"unix"`
}

TODO(v2): get rid

type ReleaseListResultRelease added in v1.5.0

type ReleaseListResultRelease struct {
	Name        string                       `json:"name"`
	Namespace   string                       `json:"namespace"`
	Revision    int                          `json:"revision"`
	Status      helmrelease.Status           `json:"status"`
	DeployedAt  *ReleaseListResultDeployedAt `json:"deployedAt"`
	Annotations map[string]string            `json:"annotations"`
	Chart       *ReleaseListResultChart      `json:"chart"`
}

type ReleaseListResultV1 added in v1.5.0

type ReleaseListResultV1 struct {
	APIVersion string                      `json:"apiVersion"`
	Releases   []*ReleaseListResultRelease `json:"releases"`
}

func ReleaseList added in v1.5.0

func ReleaseList(ctx context.Context, opts ReleaseListOptions) (*ReleaseListResultV1, error)

type ReleaseNotFoundError added in v1.4.0

type ReleaseNotFoundError struct {
	ReleaseName      string
	ReleaseNamespace string
}

func (*ReleaseNotFoundError) Error added in v1.4.0

func (e *ReleaseNotFoundError) Error() string

type ReleasePlanInstallOptions

type ReleasePlanInstallOptions struct {
	common.KubeConnectionOptions
	common.ChartRepoConnectionOptions
	common.ValuesOptions
	common.SecretValuesOptions

	Chart                       string
	ChartAppVersion             string
	ChartDirPath                string // TODO(v2): get rid
	ChartProvenanceKeyring      string
	ChartProvenanceStrategy     string
	ChartRepoSkipUpdate         bool
	ChartVersion                string
	DefaultChartAPIVersion      string
	DefaultChartName            string
	DefaultChartVersion         string
	DiffContextLines            int
	ErrorIfChangesPlanned       bool
	ExtraAnnotations            map[string]string
	ExtraLabels                 map[string]string
	ExtraRuntimeAnnotations     map[string]string
	ExtraRuntimeLabels          map[string]string
	ForceAdoption               bool
	InstallGraphPath            string
	LegacyChartType             helmopts.ChartType
	LegacyExtraValues           map[string]interface{}
	LegacyLogRegistryStreamOut  io.Writer
	NetworkParallelism          int
	NoFinalTracking             bool
	NoInstallStandaloneCRDs     bool
	NoRemoveManualChanges       bool
	RegistryCredentialsPath     string
	ReleaseInfoAnnotations      map[string]string
	ReleaseLabels               map[string]string
	ReleaseStorageDriver        string
	ReleaseStorageSQLConnection string
	ShowInsignificantDiffs      bool
	ShowSensitiveDiffs          bool
	ShowVerboseCRDDiffs         bool
	ShowVerboseDiffs            bool
	TempDirPath                 string
	TemplatesAllowDNS           bool
	Timeout                     time.Duration
}

type ReleaseRevisionNotFoundError added in v1.4.0

type ReleaseRevisionNotFoundError struct {
	ReleaseName      string
	ReleaseNamespace string
	Revision         int
}

func (*ReleaseRevisionNotFoundError) Error added in v1.4.0

type ReleaseRollbackOptions

type ReleaseRollbackOptions struct {
	common.KubeConnectionOptions
	common.TrackingOptions

	ExtraRuntimeAnnotations     map[string]string
	ExtraRuntimeLabels          map[string]string
	ForceAdoption               bool
	NetworkParallelism          int
	NoRemoveManualChanges       bool
	NoShowNotes                 bool
	ReleaseHistoryLimit         int
	ReleaseInfoAnnotations      map[string]string
	ReleaseLabels               map[string]string
	ReleaseStorageDriver        string
	ReleaseStorageSQLConnection string
	Revision                    int
	RollbackGraphPath           string
	RollbackReportPath          string
	TempDirPath                 string
	Timeout                     time.Duration
}

type ReleaseUninstallOptions

type ReleaseUninstallOptions struct {
	common.KubeConnectionOptions
	common.TrackingOptions

	DeleteReleaseNamespace      bool
	NetworkParallelism          int
	NoRemoveManualChanges       bool
	ReleaseHistoryLimit         int
	ReleaseStorageDriver        string
	ReleaseStorageSQLConnection string
	TempDirPath                 string
	Timeout                     time.Duration
	UninstallGraphPath          string
	UninstallReportPath         string
}

type SecretFileDecryptOptions

type SecretFileDecryptOptions struct {
	OutputFilePath string
	SecretKey      string
	SecretWorkDir  string
	TempDirPath    string
}

type SecretFileEditOptions

type SecretFileEditOptions struct {
	SecretKey     string
	SecretWorkDir string
	TempDirPath   string
}

type SecretFileEncryptOptions

type SecretFileEncryptOptions struct {
	OutputFilePath string
	SecretKey      string
	SecretWorkDir  string
	TempDirPath    string
}

type SecretKeyCreateOptions

type SecretKeyCreateOptions struct {
	OutputNoPrint bool
	TempDirPath   string
}

type SecretKeyRotateOptions

type SecretKeyRotateOptions struct {
	ChartDirPath      string
	NewSecretKey      string
	OldSecretKey      string
	SecretValuesFiles []string
	SecretWorkDir     string
	TempDirPath       string
}

type SecretValuesFileDecryptOptions

type SecretValuesFileDecryptOptions struct {
	OutputFilePath string
	SecretKey      string
	SecretWorkDir  string
	TempDirPath    string
}

type SecretValuesFileEditOptions

type SecretValuesFileEditOptions struct {
	SecretKey     string
	SecretWorkDir string
	TempDirPath   string
}

type SecretValuesFileEncryptOptions

type SecretValuesFileEncryptOptions struct {
	OutputFilePath string
	SecretKey      string
	SecretWorkDir  string
	TempDirPath    string
}

type VersionOptions

type VersionOptions struct {
	OutputFormat  string
	OutputNoPrint bool
	TempDirPath   string
}

type VersionResult

type VersionResult struct {
	FullVersion  string `json:"full"`
	MajorVersion int    `json:"major"`
	MinorVersion int    `json:"minor"`
	PatchVersion int    `json:"patch"`
}

func Version

func Version(ctx context.Context, opts VersionOptions) (*VersionResult, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL