status

package
v1.0.0-rc9 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2020 License: Apache-2.0 Imports: 12 Imported by: 3

Documentation

Overview

This package is for maintaining the link between `HelmRelease` resources and the Helm releases to which they correspond. Specifically,

  1. updating the `HelmRelease` status based on the progress of syncing, and the state of the associated Helm release; and,

  2. attributing each resource in a Helm release (under our control) to the associated `HelmRelease`.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetCondition

func GetCondition(status v1.HelmReleaseStatus, conditionType v1.HelmReleaseConditionType) *v1.HelmReleaseCondition

GetCondition returns the condition with the given type.

func HasRolledBack

func HasRolledBack(hr v1.HelmRelease) bool

HasRolledBack returns if the current generation of the HelmRelease has been rolled back.

func HasSynced

func HasSynced(hr v1.HelmRelease) bool

HasSynced returns if the HelmRelease has been processed by the controller.

func NewCondition

func NewCondition(conditionType v1.HelmReleaseConditionType, status corev1.ConditionStatus,
	reason, message string) v1.HelmReleaseCondition

NewCondition creates a new HelmReleaseCondition.

func SetCondition

func SetCondition(client v1client.HelmReleaseInterface, hr *v1.HelmRelease, condition v1.HelmReleaseCondition) error

SetCondition updates the HelmRelease to include the given condition.

func SetObservedGeneration

func SetObservedGeneration(client v1client.HelmReleaseInterface, hr *v1.HelmRelease, generation int64) error

SetObservedGeneration updates the observed generation status of the HelmRelease to the given generation.

func SetReleaseRevision

func SetReleaseRevision(client v1client.HelmReleaseInterface, hr *v1.HelmRelease, revision string) error

SetReleaseRevision updates the revision in the status of the HelmRelease to the given revision, and sets the current revision as the previous one.

func SetReleaseStatus

func SetReleaseStatus(client v1client.HelmReleaseInterface, hr *v1.HelmRelease,
	releaseName, releaseStatus string) error

SetReleaseStatus updates the status of the HelmRelease to the given release name and/or release status.

func ShouldRetryUpgrade

func ShouldRetryUpgrade(hr v1.HelmRelease) bool

ShouldRetryUpgrade returns if the upgrade of a rolled back release should be retried.

func UnsetCondition

func UnsetCondition(client v1client.HelmReleaseInterface,
	hr *v1.HelmRelease, conditionType v1.HelmReleaseConditionType) error

UnsetCondition updates the HelmRelease to exclude the given condition.

Types

type Updater

type Updater struct {
	// contains filtered or unexported fields
}

func New

func New(hrClient ifclientset.Interface, hrLister iflister.HelmReleaseLister, helmClients *helm.Clients, defaultHelmVersion string) *Updater

func (*Updater) Loop

func (u *Updater) Loop(stop <-chan struct{}, interval time.Duration, logger log.Logger)

Jump to

Keyboard shortcuts

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