stset

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2022 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AppSourceType = "APP"

	AnnotationAppName              = "korifi.cloudfoundry.org/application-name"
	AnnotationVersion              = "korifi.cloudfoundry.org/version"
	AnnotationAppID                = "korifi.cloudfoundry.org/application-id"
	AnnotationSpaceName            = "korifi.cloudfoundry.org/space-name"
	AnnotationOrgName              = "korifi.cloudfoundry.org/org-name"
	AnnotationOrgGUID              = "korifi.cloudfoundry.org/org-guid"
	AnnotationSpaceGUID            = "korifi.cloudfoundry.org/space-guid"
	AnnotationProcessGUID          = "korifi.cloudfoundry.org/process-guid"
	AnnotationLastReportedAppCrash = "korifi.cloudfoundry.org/last-reported-app-crash"
	AnnotationLastReportedLRPCrash = "korifi.cloudfoundry.org/last-reported-lrp-crash"

	LabelGUID        = "korifi.cloudfoundry.org/guid"
	LabelOrgGUID     = AnnotationOrgGUID
	LabelOrgName     = AnnotationOrgName
	LabelSpaceGUID   = AnnotationSpaceGUID
	LabelSpaceName   = AnnotationSpaceName
	LabelVersion     = "korifi.cloudfoundry.org/version"
	LabelAppGUID     = "korifi.cloudfoundry.org/app-guid"
	LabelProcessType = "korifi.cloudfoundry.org/process-type"
	LabelSourceType  = "korifi.cloudfoundry.org/source-type"

	ApplicationContainerName = "opi"

	PdbMinAvailableInstances          = 1
	PrivateRegistrySecretGenerateName = "private-registry-"
)
View Source
const PodAffinityTermWeight = 100

Variables

This section is empty.

Functions

func MebibyteQuantity added in v0.3.0

func MebibyteQuantity(miB int64) resource.Quantity

func StatefulSetLabelSelector

func StatefulSetLabelSelector(lrp *eiriniv1.LRP) *metav1.LabelSelector

Types

type Desirer

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

func NewDesirer

func NewDesirer(
	logger lager.Logger,
	lrpToStatefulSetConverter LRPToStatefulSetConverter,
	podDisruptionBudgetCreator PodDisruptionBudgetUpdater,
	client client.Client,
	scheme *runtime.Scheme,
) *Desirer

func (*Desirer) Desire

func (d *Desirer) Desire(ctx context.Context, lrp *eiriniv1.LRP) error

type LRPToStatefulSet

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

func NewLRPToStatefulSetConverter

func NewLRPToStatefulSetConverter(
	applicationServiceAccount string,
	registrySecretName string,
	allowAutomountServiceAccountToken bool,
	livenessProbeCreator ProbeCreator,
	readinessProbeCreator ProbeCreator,
) *LRPToStatefulSet

func (*LRPToStatefulSet) Convert

func (c *LRPToStatefulSet) Convert(statefulSetName string, lrp *eiriniv1.LRP, privateRegistrySecret *corev1.Secret) (*appsv1.StatefulSet, error)

type LRPToStatefulSetConverter

type LRPToStatefulSetConverter interface {
	Convert(statefulSetName string, lrp *eiriniv1.LRP, privateRegistrySecret *corev1.Secret) (*appsv1.StatefulSet, error)
}

type PodDisruptionBudgetUpdater

type PodDisruptionBudgetUpdater interface {
	Update(ctx context.Context, stset *appsv1.StatefulSet, lrp *eiriniv1.LRP) error
}

type ProbeCreator

type ProbeCreator func(lrp *eiriniv1.LRP) *corev1.Probe

type Updater

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

func NewUpdater

func NewUpdater(logger lager.Logger, client client.Client, pdbUpdater PodDisruptionBudgetUpdater) *Updater

func (*Updater) Update

func (u *Updater) Update(ctx context.Context, lrp *eiriniv1.LRP, stSet *appsv1.StatefulSet) error

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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