k8sutil

package
v0.0.0-...-d3ccc4f Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2018 License: Apache-2.0 Imports: 32 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Arango constants
	ArangoPort           = 8529
	ArangoSyncMasterPort = 8629
	ArangoSyncWorkerPort = 8729

	// K8s constants
	ClusterIPNone                      = "None"
	TolerateUnreadyEndpointsAnnotation = "service.alpha.kubernetes.io/tolerate-unready-endpoints"
	TopologyKeyHostname                = "kubernetes.io/hostname"

	// Internal constants
	ImageIDAndVersionRole = "id" // Role use by identification pods
)
View Source
const (
	InitDataContainerName      = "init-data"
	InitLifecycleContainerName = "init-lifecycle"
	ServerContainerName        = "server"

	ArangodVolumeMountDir           = "/data"
	RocksDBEncryptionVolumeMountDir = "/secrets/rocksdb/encryption"
	TLSKeyfileVolumeMountDir        = "/secrets/tls"
	LifecycleVolumeMountDir         = "/lifecycle/tools"
	ClientAuthCAVolumeMountDir      = "/secrets/client-auth/ca"
	ClusterJWTSecretVolumeMountDir  = "/secrets/cluster/jwt"
	MasterJWTSecretVolumeMountDir   = "/secrets/master/jwt"
)
View Source
const (
	TolerationKeyNodeNotReady         = "node.kubernetes.io/not-ready"
	TolerationKeyNodeAlphaUnreachable = "node.alpha.kubernetes.io/unreachable"
	TolerationKeyNodeUnreachable      = "node.kubernetes.io/unreachable"
)
View Source
const (
	// LabelKeyArangoDeployment is the key of the label used to store the ArangoDeployment name in
	LabelKeyArangoDeployment = "arango_deployment"
	// LabelKeyArangoLocalStorage is the key of the label used to store the ArangoLocalStorage name in
	LabelKeyArangoLocalStorage = "arango_local_storage"
	// LabelKeyApp is the key of the label used to store the application name in (fixed to AppName)
	LabelKeyApp = "app"
	// LabelKeyRole is the key of the label used to store the role of the resource in
	LabelKeyRole = "role"

	// AppName is the fixed value for the "app" label
	AppName = "arangodb"
)

Variables

This section is empty.

Functions

func AddTolerationIfNotFound

func AddTolerationIfNotFound(source []v1.Toleration, toAdd v1.Toleration) []v1.Toleration

AddTolerationIfNotFound adds the given tolerations, if no such toleration has been set in the given source.

func ConvertImageID2Image

func ConvertImageID2Image(imageID string) string

ConvertImageID2Image converts a ImageID from a ContainerStatus to an Image that can be used in a Container specification.

func CreateArangoSyncPod

func CreateArangoSyncPod(kubecli kubernetes.Interface, developmentMode bool, deployment APIObject, role, id, podName, image, lifecycleImage string, imagePullPolicy v1.PullPolicy,
	terminationGracePeriod time.Duration, args []string, env map[string]EnvValue, livenessProbe *HTTPProbeConfig, tolerations []v1.Toleration, serviceAccountName string,
	tlsKeyfileSecretName, clientAuthCASecretName, masterJWTSecretName, clusterJWTSecretName, affinityWithRole string) error

CreateArangoSyncPod creates a Pod that runs `arangosync`. If the pod already exists, nil is returned. If another error occurs, that error is returned.

func CreateArangodPod

func CreateArangodPod(kubecli kubernetes.Interface, developmentMode bool, deployment APIObject,
	role, id, podName, pvcName, image, lifecycleImage, alpineImage string, imagePullPolicy v1.PullPolicy,
	engine string, requireUUID bool, terminationGracePeriod time.Duration,
	args []string, env map[string]EnvValue, finalizers []string,
	livenessProbe *HTTPProbeConfig, readinessProbe *HTTPProbeConfig, tolerations []v1.Toleration, serviceAccountName string,
	tlsKeyfileSecretName, rocksdbEncryptionSecretName string) error

CreateArangodPod creates a Pod that runs `arangod`. If the pod already exists, nil is returned. If another error occurs, that error is returned.

func CreateCASecret

func CreateCASecret(secrets SecretInterface, secretName string, certificate, key string, ownerRef *metav1.OwnerReference) error

CreateCASecret creates a secret used to store a PEM encoded CA certificate & private key.

func CreateDatabaseClientService

func CreateDatabaseClientService(svcs ServiceInterface, deployment metav1.Object, single bool, owner metav1.OwnerReference) (string, bool, error)

CreateDatabaseClientService prepares and creates a service in k8s, used by database clients within the k8s cluster. If the service already exists, nil is returned. If another error occurs, that error is returned. The returned bool is true if the service is created, or false when the service already existed.

func CreateDatabaseClientServiceDNSName

func CreateDatabaseClientServiceDNSName(deployment metav1.Object) string

CreateDatabaseClientServiceDNSName returns the DNS of the database client service.

func CreateDatabaseClientServiceName

func CreateDatabaseClientServiceName(deploymentName string) string

CreateDatabaseClientServiceName returns the name of the service used by database clients for the given deployment name.

func CreateDatabaseExternalAccessServiceName

func CreateDatabaseExternalAccessServiceName(deploymentName string) string

CreateDatabaseExternalAccessServiceName returns the name of the service used to access the database from output the kubernetes cluster.

func CreateEncryptionKeySecret

func CreateEncryptionKeySecret(secrets SecretInterface, secretName string, key []byte) error

CreateEncryptionKeySecret creates a secret used to store a RocksDB encryption key.

func CreateExternalAccessService

func CreateExternalAccessService(svcs ServiceInterface, svcName, role string, deployment metav1.Object, serviceType v1.ServiceType, port, nodePort int, loadBalancerIP string, owner metav1.OwnerReference) (string, bool, error)

CreateExternalAccessService prepares and creates a service in k8s, used to access the database/sync from outside k8s cluster. If the service already exists, nil is returned. If another error occurs, that error is returned. The returned bool is true if the service is created, or false when the service already existed.

func CreateHeadlessService

func CreateHeadlessService(svcs ServiceInterface, deployment metav1.Object, owner metav1.OwnerReference) (string, bool, error)

CreateHeadlessService prepares and creates a headless service in k8s, used to provide a stable DNS name for all pods. If the service already exists, nil is returned. If another error occurs, that error is returned. The returned bool is true if the service is created, or false when the service already existed.

func CreateHeadlessServiceName

func CreateHeadlessServiceName(deploymentName string) string

CreateHeadlessServiceName returns the name of the headless service for the given deployment name.

func CreatePersistentVolumeClaim

func CreatePersistentVolumeClaim(pvcs PersistentVolumeClaimInterface, pvcName, deploymentName, ns, storageClassName, role string, enforceAntiAffinity bool, resources v1.ResourceRequirements, finalizers []string, owner metav1.OwnerReference) error

CreatePersistentVolumeClaim creates a persistent volume claim with given name and configuration. If the pvc already exists, nil is returned. If another error occurs, that error is returned.

func CreatePersistentVolumeClaimName

func CreatePersistentVolumeClaimName(deploymentName, role, id string) string

CreatePersistentVolumeClaimName returns the name of the persistent volume claim for a member with a given id in a deployment with a given name.

func CreatePodDNSName

func CreatePodDNSName(deployment metav1.Object, role, id string) string

CreatePodDNSName returns the DNS of a pod with a given role & id in a given deployment.

func CreatePodHostName

func CreatePodHostName(deploymentName, role, id string) string

CreatePodHostName returns the hostname of the pod for a member with a given id in a deployment with a given name.

func CreatePodName

func CreatePodName(deploymentName, role, id, suffix string) string

CreatePodName returns the name of the pod for a member with a given id in a deployment with a given name.

func CreateServiceURL

func CreateServiceURL(svc v1.Service, scheme string, portPredicate func(v1.ServicePort) bool, nodeFetcher func() (v1.NodeList, error)) (string, error)

CreateServiceURL creates a URL used to reach the given service.

func CreateSyncMasterClientServiceDNSName

func CreateSyncMasterClientServiceDNSName(deployment metav1.Object) string

CreateSyncMasterClientServiceDNSName returns the DNS of the syncmaster client service.

func CreateSyncMasterClientServiceName

func CreateSyncMasterClientServiceName(deploymentName string) string

CreateSyncMasterClientServiceName returns the name of the service used by syncmaster clients for the given deployment name.

func CreateTLSKeyfileSecret

func CreateTLSKeyfileSecret(secrets SecretInterface, secretName string, keyfile string, ownerRef *metav1.OwnerReference) error

CreateTLSKeyfileSecret creates a secret used to store a PEM encoded keyfile in the format ArangoDB accepts it for its `--ssl.keyfile` option.

func CreateTLSKeyfileSecretName

func CreateTLSKeyfileSecretName(deploymentName, role, id string) string

CreateTLSKeyfileSecretName returns the name of the Secret that holds the TLS keyfile for a member with a given id in a deployment with a given name.

func CreateTokenSecret

func CreateTokenSecret(secrets SecretInterface, secretName, token string, ownerRef *metav1.OwnerReference) error

CreateTokenSecret creates a secret with given name in given namespace with a given token as value.

func DeploymentListOpt

func DeploymentListOpt(deploymentName string) metav1.ListOptions

DeploymentListOpt creates a ListOptions matching all labels for the given deployment name.

func GetBasicAuthSecret

func GetBasicAuthSecret(secrets SecretInterface, secretName string) (string, string, error)

GetBasicAuthSecret loads a secret with given name in the given namespace and extracts the `username` & `password` field. If the secret does not exists or one of the fields is missing, an error is returned. Returns: username, password, error

func GetCACertficateSecret

func GetCACertficateSecret(secrets SecretInterface, secretName string) (string, error)

GetCACertficateSecret loads a secret with given name in the given namespace and extracts the `ca.crt` field. If the secret does not exists the field is missing, an error is returned. Returns: certificate, error

func GetCASecret

func GetCASecret(secrets SecretInterface, secretName string, ownerRef *metav1.OwnerReference) (string, string, bool, error)

GetCASecret loads a secret with given name in the given namespace and extracts the `ca.crt` & `ca.key` field. If the secret does not exists or one of the fields is missing, an error is returned. Returns: certificate, private-key, isOwnedByDeployment, error

func GetContainerByName

func GetContainerByName(p *v1.Pod, name string) (v1.Container, bool)

GetContainerByName returns the container in the given pod with the given name. Returns false if not found.

func GetPodOwner

func GetPodOwner(kubecli kubernetes.Interface, pod *v1.Pod, ns string) (*v1beta2.ReplicaSet, error)

GetPodOwner returns the ReplicaSet that owns the given Pod. If the Pod has no owner of the owner is not a ReplicaSet, nil is returned.

func GetReplicaSetOwner

func GetReplicaSetOwner(kubecli kubernetes.Interface, rSet *v1beta2.ReplicaSet, ns string) (*v1beta2.Deployment, error)

GetReplicaSetOwner returns the Deployment that owns the given ReplicaSet. If the ReplicaSet has no owner of the owner is not a Deployment, nil is returned.

func GetTLSKeyfileSecret

func GetTLSKeyfileSecret(secrets SecretInterface, secretName string) (string, error)

GetTLSKeyfileSecret loads a secret used to store a PEM encoded keyfile in the format ArangoDB accepts it for its `--ssl.keyfile` option. Returns: keyfile (pem encoded), error

func GetTokenSecret

func GetTokenSecret(secrets SecretInterface, secretName string) (string, error)

GetTokenSecret loads the token secret from a Secret with given name.

func InClusterConfig

func InClusterConfig() (*rest.Config, error)

InClusterConfig loads the environment into a rest config.

func IsAlreadyExists

func IsAlreadyExists(err error) bool

IsAlreadyExists returns true if the given error is or is caused by a kubernetes AlreadyExistsError,

func IsArangoDBImageIDAndVersionPod

func IsArangoDBImageIDAndVersionPod(p v1.Pod) bool

IsArangoDBImageIDAndVersionPod returns true if the given pod is used for fetching image ID and ArangoDB version of an image

func IsConflict

func IsConflict(err error) bool

IsConflict returns true if the given error is or is caused by a kubernetes ConflictError,

func IsNotFound

func IsNotFound(err error) bool

IsNotFound returns true if the given error is or is caused by a kubernetes NotFoundError,

func IsPersistentVolumeClaimMarkedForDeletion

func IsPersistentVolumeClaimMarkedForDeletion(pvc *v1.PersistentVolumeClaim) bool

IsPersistentVolumeClaimMarkedForDeletion returns true if the pod has been marked for deletion.

func IsPodFailed

func IsPodFailed(pod *v1.Pod) bool

IsPodFailed returns true if all containers of the pod have terminated and at least one of them wih a non-zero exit code.

func IsPodMarkedForDeletion

func IsPodMarkedForDeletion(pod *v1.Pod) bool

IsPodMarkedForDeletion returns true if the pod has been marked for deletion.

func IsPodNotScheduledFor

func IsPodNotScheduledFor(pod *v1.Pod, timeout time.Duration) bool

IsPodNotScheduledFor returns true if the pod has not been scheduled for longer than the given duration.

func IsPodReady

func IsPodReady(pod *v1.Pod) bool

IsPodReady returns true if the PodReady condition on the given pod is set to true.

func IsPodScheduled

func IsPodScheduled(pod *v1.Pod) bool

IsPodScheduled returns true if the pod has been scheduled.

func IsPodSucceeded

func IsPodSucceeded(pod *v1.Pod) bool

IsPodSucceeded returns true if all containers of the pod have terminated with exit code 0.

func IsPodTerminating

func IsPodTerminating(pod *v1.Pod) bool

IsPodTerminating returns true if the pod has been marked for deletion but is still running.

func LabelsForDeployment

func LabelsForDeployment(deploymentName, role string) map[string]string

LabelsForDeployment returns a map of labels, given to all resources for given deployment name

func LabelsForLocalStorage

func LabelsForLocalStorage(localStorageName, role string) map[string]string

LabelsForLocalStorage returns a map of labels, given to all resources for given local storage name

func LocalStorageListOpt

func LocalStorageListOpt(localStorageName, role string) metav1.ListOptions

LocalStorageListOpt creates a ListOptions matching all labels for the given local storage name.

func NewKubeClient

func NewKubeClient() (kubernetes.Interface, error)

NewKubeClient creates a new k8s client

func NewKubeExtClient

func NewKubeExtClient() (apiextensionsclient.Interface, error)

NewKubeExtClient creates a new k8s api extensions client

func NewNoExecuteToleration

func NewNoExecuteToleration(key string, duration TolerationDuration) v1.Toleration

NewNoExecuteToleration is a helper to create a Toleration with Key=key, Operator='Exists' Effect='NoExecute', TolerationSeconds=tolerationDuration.Seconds().

func PatchStorageClassIsDefault

func PatchStorageClassIsDefault(cli storagev1.StorageV1Interface, name string, isDefault bool) error

PatchStorageClassIsDefault changes the default flag of the given storage class.

func RemoveFinalizers

func RemoveFinalizers(log zerolog.Logger, finalizers []string, getFunc func() (metav1.Object, error), updateFunc func(metav1.Object) error, ignoreNotFound bool) error

RemoveFinalizers is a helper used to remove finalizers from an object. The functions tries to get the object using the provided get function, then remove the given finalizers and update the update using the given update function. In case of an update conflict, the functions tries again.

func RemovePVCFinalizers

func RemovePVCFinalizers(log zerolog.Logger, kubecli kubernetes.Interface, p *v1.PersistentVolumeClaim, finalizers []string, ignoreNotFound bool) error

RemovePVCFinalizers removes the given finalizers from the given PVC.

func RemovePodFinalizers

func RemovePodFinalizers(log zerolog.Logger, kubecli kubernetes.Interface, p *v1.Pod, finalizers []string, ignoreNotFound bool) error

RemovePodFinalizers removes the given finalizers from the given pod.

func StorageClassIsDefault

func StorageClassIsDefault(sc *v1.StorageClass) bool

StorageClassIsDefault returns true if the given storage class is marked default, false otherwise.

func ValidateCACertificateSecret

func ValidateCACertificateSecret(secrets SecretInterface, secretName string) error

ValidateCACertificateSecret checks that a secret with given name in given namespace exists and it contains a 'ca.crt' data field.

func ValidateEncryptionKeySecret

func ValidateEncryptionKeySecret(secrets SecretInterface, secretName string) error

ValidateEncryptionKeySecret checks that a secret with given name in given namespace exists and it contains a 'key' data field of exactly 32 bytes.

func ValidateOptionalResourceName

func ValidateOptionalResourceName(name string) error

ValidateOptionalResourceName validates a kubernetes resource name. If not empty and not valid, an error is returned.

func ValidateResourceName

func ValidateResourceName(name string) error

ValidateResourceName validates a kubernetes resource name. If not valid, an error is returned. See https://kubernetes.io/docs/concepts/overview/working-with-objects/names/

func ValidateTokenSecret

func ValidateTokenSecret(secrets SecretInterface, secretName string) error

ValidateTokenSecret checks that a secret with given name in given namespace exists and it contains a 'token' data field.

Types

type APIObject

type APIObject interface {
	runtime.Object
	metav1.Object
	// AsOwner creates an OwnerReference for the given deployment
	AsOwner() metav1.OwnerReference
}

APIObject helps to abstract an object from our custom API.

type EnvValue

type EnvValue struct {
	Value      string // If set, the environment value gets this value
	SecretName string // If set, the environment value gets its value from a secret with this name
	SecretKey  string // Key inside secret to fill into the envvar. Only relevant is SecretName is set.
}

EnvValue is a helper structure for environment variable sources.

func (EnvValue) CreateEnvVar

func (v EnvValue) CreateEnvVar(key string) v1.EnvVar

CreateEnvVar creates an EnvVar structure for given key from given EnvValue.

type Event

type Event struct {
	InvolvedObject runtime.Object
	Type           string
	Reason         string
	Message        string
}

Event is used to create events using an EventRecorder.

func NewAccessPackageCreatedEvent

func NewAccessPackageCreatedEvent(apiObject APIObject, apSecretName string) *Event

NewAccessPackageCreatedEvent creates an event indicating that a secret containing an access package has been created.

func NewAccessPackageDeletedEvent

func NewAccessPackageDeletedEvent(apiObject APIObject, apSecretName string) *Event

NewAccessPackageDeletedEvent creates an event indicating that a secret containing an access package has been deleted.

func NewCannotChangeStorageClassEvent

func NewCannotChangeStorageClassEvent(apiObject APIObject, memberID, role, subReason string) *Event

NewCannotChangeStorageClassEvent creates an event indicating that an item would need to use a different StorageClass, but this is not possible for the given reason.

func NewDowntimeNotAllowedEvent

func NewDowntimeNotAllowedEvent(apiObject APIObject, operation string) *Event

NewDowntimeNotAllowedEvent creates an event indicating that an operation cannot be executed because downtime is currently not allowed.

func NewErrorEvent

func NewErrorEvent(reason string, err error, apiObject APIObject) *Event

NewErrorEvent creates an even of type error.

func NewImmutableFieldEvent

func NewImmutableFieldEvent(fieldName string, apiObject APIObject) *Event

NewImmutableFieldEvent creates an event indicating that an attempt was made to change a field that is immutable.

func NewMemberAddEvent

func NewMemberAddEvent(memberName, role string, apiObject APIObject) *Event

NewMemberAddEvent creates an event indicating that a member was added.

func NewMemberRemoveEvent

func NewMemberRemoveEvent(memberName, role string, apiObject APIObject) *Event

NewMemberRemoveEvent creates an event indicating that an existing member was removed.

func NewPlanAbortedEvent

func NewPlanAbortedEvent(apiObject APIObject, itemType, memberID, role string) *Event

NewPlanAbortedEvent creates an event indicating that an item on a reconciliation plan wants to abort the entire plan.

func NewPlanTimeoutEvent

func NewPlanTimeoutEvent(apiObject APIObject, itemType, memberID, role string) *Event

NewPlanTimeoutEvent creates an event indicating that an item on a reconciliation plan did not finish before its deadline.

func NewPodCreatedEvent

func NewPodCreatedEvent(podName, role string, apiObject APIObject) *Event

NewPodCreatedEvent creates an event indicating that a pod has been created

func NewPodGoneEvent

func NewPodGoneEvent(podName, role string, apiObject APIObject) *Event

NewPodGoneEvent creates an event indicating that a pod is missing

func NewPodsSchedulingFailureEvent

func NewPodsSchedulingFailureEvent(unscheduledPodNames []string, apiObject APIObject) *Event

NewPodsSchedulingFailureEvent creates an event indicating that one of more cannot be scheduled.

func NewPodsSchedulingResolvedEvent

func NewPodsSchedulingResolvedEvent(apiObject APIObject) *Event

NewPodsSchedulingResolvedEvent creates an event indicating that an earlier problem with pod scheduling has been resolved.

func NewSecretsChangedEvent

func NewSecretsChangedEvent(changedSecretNames []string, apiObject APIObject) *Event

NewSecretsChangedEvent creates an event indicating that one of more secrets have changed.

func NewSecretsRestoredEvent

func NewSecretsRestoredEvent(apiObject APIObject) *Event

NewSecretsRestoredEvent creates an event indicating that all secrets have been restored to their original values.

func NewUpgradeNotAllowedEvent

func NewUpgradeNotAllowedEvent(apiObject APIObject,
	fromVersion, toVersion driver.Version,
	fromLicense, toLicense upgraderules.License) *Event

NewUpgradeNotAllowedEvent creates an event indicating that an upgrade (or downgrade) is not allowed.

type HTTPProbeConfig

type HTTPProbeConfig struct {
	// Local path to GET
	LocalPath string // `e.g. /_api/version`
	// Secure connection?
	Secure bool
	// Value for an Authorization header (can be empty)
	Authorization string
	// Port to inspect (defaults to ArangoPort)
	Port int
	// Number of seconds after the container has started before liveness probes are initiated (defaults to 30)
	InitialDelaySeconds int32
	// Number of seconds after which the probe times out (defaults to 2).
	TimeoutSeconds int32
	// How often (in seconds) to perform the probe (defaults to 10).
	PeriodSeconds int32
	// Minimum consecutive successes for the probe to be considered successful after having failed (defaults to 1).
	SuccessThreshold int32
	// Minimum consecutive failures for the probe to be considered failed after having succeeded (defaults to 3).
	FailureThreshold int32
}

HTTPProbeConfig contains settings for creating a liveness/readiness probe.

func (HTTPProbeConfig) Create

func (config HTTPProbeConfig) Create() *v1.Probe

Create creates a probe from given config

type PersistentVolumeClaimInterface

type PersistentVolumeClaimInterface interface {
	Create(*v1.PersistentVolumeClaim) (*v1.PersistentVolumeClaim, error)
	Get(name string, options metav1.GetOptions) (*v1.PersistentVolumeClaim, error)
}

PersistentVolumeClaimInterface has methods to work with PersistentVolumeClaim resources.

func NewPersistentVolumeClaimCache

func NewPersistentVolumeClaimCache(cli corev1.PersistentVolumeClaimInterface) PersistentVolumeClaimInterface

NewPersistentVolumeClaimCache creates a cached version of the given PersistentVolumeClaimInterface.

type ResourceWatcher

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

ResourceWatcher is a helper to watch for events in a specific type of resource. The handler functions are protected from panics.

func NewResourceWatcher

func NewResourceWatcher(log zerolog.Logger, getter cache.Getter, resource, namespace string,
	objType runtime.Object, h cache.ResourceEventHandlerFuncs) *ResourceWatcher

NewResourceWatcher creates a helper that watches for changes in a resource of a specific type. If wraps the given handler functions, such that panics are caught and logged.

func (*ResourceWatcher) Run

func (rw *ResourceWatcher) Run(stopCh <-chan struct{})

Run continues to watch for events on the selected type of resource until the given channel is closed.

type SecretInterface

type SecretInterface interface {
	Create(*v1.Secret) (*v1.Secret, error)
	Get(name string, options metav1.GetOptions) (*v1.Secret, error)
}

SecretInterface has methods to work with Secret resources.

func NewSecretCache

func NewSecretCache(cli corev1.SecretInterface) SecretInterface

NewSecretCache creates a cached version of the given SecretInterface.

type ServiceInterface

type ServiceInterface interface {
	Create(*v1.Service) (*v1.Service, error)
	Delete(name string, options *metav1.DeleteOptions) error
	Get(name string, options metav1.GetOptions) (*v1.Service, error)
}

ServiceInterface has methods to work with Service resources.

func NewServiceCache

func NewServiceCache(cli corev1.ServiceInterface) ServiceInterface

NewServiceCache creates a cached version of the given ServiceInterface.

type TolerationDuration

type TolerationDuration struct {
	Forever  bool
	TimeSpan time.Duration
}

TolerationDuration is a duration spec for tolerations.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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