Documentation ¶
Index ¶
- Constants
- Variables
- func DeleteVolumeAttachments(ctx context.Context, c client.Client) error
- func DetermineBackupSchedule(shoot *gardencorev1beta1.Shoot, etcd *druidv1alpha1.Etcd) (string, error)
- func DetermineDefragmentSchedule(shoot *gardencorev1beta1.Shoot, etcd *druidv1alpha1.Etcd, ...) (string, error)
- func GenerateDNSProviderName(secretName, providerType string) string
- func IsProblematicWebhook(failurePolicy *admissionregistrationv1beta1.FailurePolicyType, ...) bool
- func IsValidAuditPolicyVersion(shootVersion string, schemaVersion *schema.GroupVersionKind) (bool, error)
- func PardonCondition(condition gardencorev1beta1.Condition, lastOp *gardencorev1beta1.LastOperation, ...) gardencorev1beta1.Condition
- func WaitUntilDeploymentScaledToDesiredReplicas(ctx context.Context, client client.Client, namespace, name string, ...) error
- func WaitUntilVolumeAttachmentsDeleted(ctx context.Context, c client.Client, log *logrus.Entry) error
- type Botanist
- func (b *Botanist) APIServerSNIEnabled() bool
- func (b *Botanist) AdditionalDNSProviders(ctx context.Context, gardenClient, seedClient client.Client) (map[string]component.DeployWaiter, error)
- func (b *Botanist) AnnotateBackupEntryInSeedForMigration(ctx context.Context) error
- func (b *Botanist) AnnotateExtensionCRsForMigration(ctx context.Context) (err error)
- func (b *Botanist) ApplyEncryptionConfiguration(ctx context.Context) error
- func (b *Botanist) CheckHibernationPossible(ctx context.Context, constraint gardencorev1beta1.Condition) (*gardencorev1beta1.Condition, error)
- func (b *Botanist) CheckTunnelConnection(ctx context.Context, logger *logrus.Entry, tunnelName string) (bool, error)
- func (b *Botanist) CleanExtendedAPIs(ctx context.Context) error
- func (b *Botanist) CleanKubernetesResources(ctx context.Context) error
- func (b *Botanist) CleanShootNamespaces(ctx context.Context) error
- func (b *Botanist) CleanWebhooks(ctx context.Context) error
- func (b *Botanist) ComputeShootOperatingSystemConfig(ctx context.Context) error
- func (b *Botanist) ConstraintsChecks(ctx context.Context, initializeShootClients func() (bool, error), ...) gardencorev1beta1.Condition
- func (b *Botanist) CreateETCDSnapshot(ctx context.Context) error
- func (b *Botanist) DefaultClusterAutoscaler() (clusterautoscaler.ClusterAutoscaler, error)
- func (b *Botanist) DefaultContainerRuntime(seedClient client.Client) shoot.ContainerRuntime
- func (b *Botanist) DefaultExternalDNSEntry(seedClient client.Client) component.DeployWaiter
- func (b *Botanist) DefaultExternalDNSOwner(seedClient client.Client) component.DeployWaiter
- func (b *Botanist) DefaultExternalDNSProvider(seedClient client.Client) component.DeployWaiter
- func (b *Botanist) DefaultInfrastructure(seedClient client.Client) shoot.Infrastructure
- func (b *Botanist) DefaultInternalDNSEntry(seedClient client.Client) component.DeployWaiter
- func (b *Botanist) DefaultInternalDNSOwner(seedClient client.Client) component.DeployWaiter
- func (b *Botanist) DefaultInternalDNSProvider(seedClient client.Client) component.DeployWaiter
- func (b *Botanist) DefaultKubeAPIServerSNI() component.DeployWaiter
- func (b *Botanist) DefaultKubeAPIServerService(sniPhase component.Phase) component.DeployWaiter
- func (b *Botanist) DefaultKubeControllerManager() (kubecontrollermanager.KubeControllerManager, error)
- func (b *Botanist) DefaultKubeScheduler() (kubescheduler.KubeScheduler, error)
- func (b *Botanist) DefaultNetwork(seedClient client.Client) component.DeployMigrateWaiter
- func (b *Botanist) DefaultNginxIngressDNSEntry(seedClient client.Client) component.DeployWaiter
- func (b *Botanist) DefaultNginxIngressDNSOwner(seedClient client.Client) component.DeployWaiter
- func (b *Botanist) DeleteAllExtensionCRs(ctx context.Context) error
- func (b *Botanist) DeleteAllExtensionResources(ctx context.Context) error
- func (b *Botanist) DeleteAllManagedResourcesObjects(ctx context.Context) error
- func (b *Botanist) DeleteAllOperatingSystemConfigs(ctx context.Context) error
- func (b *Botanist) DeleteBackupEntryFromSeed(ctx context.Context) error
- func (b *Botanist) DeleteClusterAutoscaler(ctx context.Context) error
- func (b *Botanist) DeleteDNSProviders(ctx context.Context) error
- func (b *Botanist) DeleteKubeAPIServer(ctx context.Context) error
- func (b *Botanist) DeleteManagedResources(ctx context.Context) error
- func (b *Botanist) DeleteNamespace(ctx context.Context) error
- func (b *Botanist) DeleteSeedMonitoring(ctx context.Context) error
- func (b *Botanist) DeleteStaleExtensionResources(ctx context.Context) error
- func (b *Botanist) DeleteStaleOperatingSystemConfigs(ctx context.Context, wantedOSCNames sets.String) error
- func (b *Botanist) DeployBackupEntryInGarden(ctx context.Context) error
- func (b *Botanist) DeployCloudProviderSecret(ctx context.Context) error
- func (b *Botanist) DeployClusterAutoscaler(ctx context.Context) error
- func (b *Botanist) DeployContainerRuntime(ctx context.Context) error
- func (b *Botanist) DeployControlPlane(ctx context.Context) error
- func (b *Botanist) DeployControlPlaneExposure(ctx context.Context) error
- func (b *Botanist) DeployETCD(ctx context.Context) error
- func (b *Botanist) DeployExtensionResources(ctx context.Context) error
- func (b *Botanist) DeployExternalDNS(ctx context.Context) error
- func (b *Botanist) DeployGardenerResourceManager(ctx context.Context) error
- func (b *Botanist) DeployInfrastructure(ctx context.Context) error
- func (b *Botanist) DeployInternalDNS(ctx context.Context) error
- func (b *Botanist) DeployKubeAPIServer(ctx context.Context) error
- func (b *Botanist) DeployKubeAPIServerSNI(ctx context.Context) error
- func (b *Botanist) DeployKubeAPIService(ctx context.Context, sniPhase component.Phase) error
- func (b *Botanist) DeployKubeControllerManager(ctx context.Context) error
- func (b *Botanist) DeployKubeScheduler(ctx context.Context) error
- func (b *Botanist) DeployManagedResources(ctx context.Context) error
- func (b *Botanist) DeployNamespace(ctx context.Context) error
- func (b *Botanist) DeployNetwork(ctx context.Context) error
- func (b *Botanist) DeployNetworkPolicies(ctx context.Context) error
- func (b *Botanist) DeployReferencedResources(ctx context.Context) error
- func (b *Botanist) DeploySecrets(ctx context.Context) error
- func (b *Botanist) DeploySeedLogging(ctx context.Context) error
- func (b *Botanist) DeploySeedMonitoring(ctx context.Context) error
- func (b *Botanist) DeployVerticalPodAutoscaler(ctx context.Context) error
- func (b *Botanist) DeployWorker(ctx context.Context) error
- func (b *Botanist) DestroyControlPlane(ctx context.Context) error
- func (b *Botanist) DestroyControlPlaneExposure(ctx context.Context) error
- func (b *Botanist) DestroyExternalDNS(ctx context.Context) error
- func (b *Botanist) DestroyIngressDNSRecord(ctx context.Context) error
- func (b *Botanist) DestroyInternalDNS(ctx context.Context) error
- func (b *Botanist) DestroyReferencedResources(ctx context.Context) error
- func (b *Botanist) DestroyWorker(ctx context.Context) error
- func (b *Botanist) EnsureClusterIdentity(ctx context.Context) error
- func (b *Botanist) EnsureIngressDNSRecord(ctx context.Context) error
- func (b *Botanist) GenerateAndSaveSecrets(ctx context.Context) error
- func (b *Botanist) GenerateEncryptionConfiguration(ctx context.Context) error
- func (b *Botanist) GenerateKubernetesDashboardConfig() (map[string]interface{}, error)
- func (b *Botanist) GenerateNginxIngressConfig() (map[string]interface{}, error)
- func (b *Botanist) HealthChecks(ctx context.Context, initializeShootClients func() (bool, error), ...) (gardencorev1beta1.Condition, gardencorev1beta1.Condition, ...)
- func (b *Botanist) HibernateControlPlane(ctx context.Context) error
- func (b *Botanist) KeepManagedResourcesObjects(ctx context.Context) error
- func (b *Botanist) MaintainShootAnnotations(ctx context.Context) error
- func (b *Botanist) MigrateExternalDNS(ctx context.Context) error
- func (b *Botanist) MigrateIngressDNSRecord(ctx context.Context) error
- func (b *Botanist) MigrateInternalDNS(ctx context.Context) error
- func (b *Botanist) NeedsAdditionalDNSProviders() bool
- func (b *Botanist) NeedsExternalDNS() bool
- func (b *Botanist) NeedsInternalDNS() bool
- func (b *Botanist) PerformGarbageCollectionSeed(ctx context.Context) error
- func (b *Botanist) PerformGarbageCollectionShoot(ctx context.Context) error
- func (b *Botanist) PersistEncryptionConfiguration(ctx context.Context) error
- func (b *Botanist) PrepareKubeAPIServerForMigration(ctx context.Context) error
- func (b *Botanist) RemoveOldETCDEncryptionSecretFromGardener(ctx context.Context) error
- func (b *Botanist) RequiredExtensionsReady(ctx context.Context) error
- func (b *Botanist) RestartControlPlanePods(ctx context.Context) error
- func (b *Botanist) RewriteShootSecretsIfEncryptionConfigurationChanged(ctx context.Context) error
- func (b *Botanist) SNIPhase(ctx context.Context) (component.Phase, error)
- func (b *Botanist) ScaleETCDToOne(ctx context.Context) error
- func (b *Botanist) ScaleETCDToZero(ctx context.Context) error
- func (b *Botanist) ScaleGardenerResourceManagerToOne(ctx context.Context) error
- func (b *Botanist) ScaleKubeAPIServerToOne(ctx context.Context) error
- func (b *Botanist) ScaleKubeControllerManagerToOne(ctx context.Context) error
- func (b *Botanist) SetNginxIngressAddress(address string, seedClient client.Client)
- func (b *Botanist) SyncShootCredentialsToGarden(ctx context.Context) error
- func (b *Botanist) UpdateShootAndCluster(ctx context.Context, shoot *gardencorev1beta1.Shoot, transform func() error) error
- func (b *Botanist) WaitForBackupEntryOperationMigrateToSucceed(ctx context.Context) error
- func (b *Botanist) WaitForExtensionsOperationMigrateToSucceed(ctx context.Context) error
- func (b *Botanist) WaitForInfrastructure(ctx context.Context) error
- func (b *Botanist) WaitForKubeControllerManagerToBeActive(ctx context.Context) error
- func (b *Botanist) WaitUntilAllManagedResourcesDeleted(ctx context.Context) error
- func (b *Botanist) WaitUntilBackupEntryInGardenReconciled(ctx context.Context) error
- func (b *Botanist) WaitUntilControlPlaneDeleted(ctx context.Context) error
- func (b *Botanist) WaitUntilControlPlaneExposureDeleted(ctx context.Context) error
- func (b *Botanist) WaitUntilControlPlaneExposureReady(ctx context.Context) error
- func (b *Botanist) WaitUntilControlPlaneReady(ctx context.Context) error
- func (b *Botanist) WaitUntilEndpointsDoNotContainPodIPs(ctx context.Context) error
- func (b *Botanist) WaitUntilEtcdReady(ctx context.Context) error
- func (b *Botanist) WaitUntilExtensionResourcesDeleted(ctx context.Context) error
- func (b *Botanist) WaitUntilExtensionResourcesReady(ctx context.Context) error
- func (b *Botanist) WaitUntilKubeAPIServerIsDeleted(ctx context.Context) error
- func (b *Botanist) WaitUntilKubeAPIServerReady(ctx context.Context) error
- func (b *Botanist) WaitUntilManagedResourcesDeleted(ctx context.Context) error
- func (b *Botanist) WaitUntilNginxIngressServiceIsReady(ctx context.Context) error
- func (b *Botanist) WaitUntilNoPodRunning(ctx context.Context) error
- func (b *Botanist) WaitUntilNodesDeleted(ctx context.Context) error
- func (b *Botanist) WaitUntilRequiredExtensionsReady(ctx context.Context) error
- func (b *Botanist) WaitUntilSeedNamespaceDeleted(ctx context.Context) error
- func (b *Botanist) WaitUntilShootLoadBalancerIsReady(ctx context.Context, namespace, name string, timeout time.Duration) (string, error)
- func (b *Botanist) WaitUntilTunnelConnectionExists(ctx context.Context) error
- func (b *Botanist) WaitUntilVpnShootServiceIsReady(ctx context.Context) error
- func (b *Botanist) WaitUntilWorkerDeleted(ctx context.Context) error
- func (b *Botanist) WaitUntilWorkerReady(ctx context.Context) error
- func (b *Botanist) WakeUpKubeAPIServer(ctx context.Context) error
- type ExtensionCondition
- type HealthChecker
- func (b *HealthChecker) CheckClusterNodes(workers []gardencorev1beta1.Worker, condition gardencorev1beta1.Condition, ...) (*gardencorev1beta1.Condition, error)
- func (b *HealthChecker) CheckControlPlane(shoot *gardencorev1beta1.Shoot, namespace string, ...) (*gardencorev1beta1.Condition, error)
- func (b *HealthChecker) CheckExtensionCondition(condition gardencorev1beta1.Condition, ...) *gardencorev1beta1.Condition
- func (b *HealthChecker) CheckLoggingControlPlane(namespace string, checkObsolete bool, condition gardencorev1beta1.Condition, ...) (*gardencorev1beta1.Condition, error)
- func (b *HealthChecker) CheckManagedResource(condition gardencorev1beta1.Condition, mr *resourcesv1alpha1.ManagedResource) *gardencorev1beta1.Condition
- func (b *HealthChecker) CheckMonitoringControlPlane(namespace string, isTestingShoot bool, wantsAlertmanager bool, ...) (*gardencorev1beta1.Condition, error)
- func (b *HealthChecker) FailedCondition(condition gardencorev1beta1.Condition, reason, message string, ...) gardencorev1beta1.Condition
- type SortableEvents
Constants ¶
const ( // DNSIngressName is a constant for a DNS resources used for the ingress domain name. DNSIngressName = "ingress" // SecretLabelKeyManagedResource is a key for a label on a secret with the value 'managed-resource'. SecretLabelKeyManagedResource = "managed-resource" )
const ( // DefaultInterval is the default interval for retry operations. DefaultInterval = 5 * time.Second // DefaultSevereThreshold is the default threshold until an error reported by another component is treated as 'severe'. DefaultSevereThreshold = 30 * time.Second )
const ( // Provider is the kubernetes provider label. Provider = "provider" // KubernetesProvider is the 'kubernetes' value of the Provider label. KubernetesProvider = "kubernetes" // KubeAggregatorAutoManaged is the label whether an APIService is automanaged by kube-aggregator. KubeAggregatorAutoManaged = autoregister.AutoRegisterManagedLabel // MetadataNameField ist the `metadata.name` field for a field selector. MetadataNameField = "metadata.name" )
const ( // DNSInternalName is a constant for a DNS resources used for the internal domain name. DNSInternalName = "internal" // DNSExternalName is a constant for a DNS resources used for the external domain name. DNSExternalName = "external" // DNSProviderRoleAdditional is a constant for additionally managed DNS providers. DNSProviderRoleAdditional = "managed-dns-provider" )
const ControlPlaneDefaultTimeout = 3 * time.Minute
ControlPlaneDefaultTimeout is the default timeout and defines how long Gardener should wait for a successful reconciliation of a control plane resource.
const (
// ManagedResourceName is the name of the managed resource used to deploy referenced resources to the Seed cluster.
ManagedResourceName = "referenced-resources"
)
const NodeLocalIPVSAddress = "169.254.20.10"
NodeLocalIPVSAddress is the IPv4 address used by node local dns when IPVS is used.
const WorkerDefaultTimeout = 10 * time.Minute
WorkerDefaultTimeout is the default timeout and defines how long Gardener should wait for a successful reconciliation of a worker resource.
Variables ¶
var ( // FinalizeAfterFiveMinutes is an option to finalize resources after five minutes. FinalizeAfterFiveMinutes = utilclient.FinalizeGracePeriodSeconds(5 * 60) // FinalizeAfterOneHour is an option to finalize resources after one hour. FinalizeAfterOneHour = utilclient.FinalizeGracePeriodSeconds(60 * 60) // ZeroGracePeriod is an option to delete resources with no grace period. ZeroGracePeriod = utilclient.DeleteWith{client.GracePeriodSeconds(0)} // GracePeriodFiveMinutes is an option to delete resources with a grace period of five minutes. GracePeriodFiveMinutes = utilclient.DeleteWith{client.GracePeriodSeconds(5 * 60)} // NotSystemComponent is a requirement that something doesn't have the GardenRole GardenRoleSystemComponent. NotSystemComponent = utils.MustNewRequirement(v1beta1constants.DeprecatedGardenRole, selection.NotEquals, v1beta1constants.GardenRoleSystemComponent) // NoCleanupPrevention is a requirement that the ShootNoCleanup label of something is not true. NoCleanupPrevention = utils.MustNewRequirement(common.ShootNoCleanup, selection.NotEquals, "true") // NotKubernetesProvider is a requirement that the Provider label of something is not KubernetesProvider. NotKubernetesProvider = utils.MustNewRequirement(Provider, selection.NotEquals, KubernetesProvider) // NotKubeAggregatorAutoManaged is a requirement that something is not auto-managed by Kube-Aggregator. NotKubeAggregatorAutoManaged = utils.MustNewRequirement(KubeAggregatorAutoManaged, selection.DoesNotExist) // CleanupSelector is a selector that excludes system components and all resources not considered for auto cleanup. CleanupSelector = labels.NewSelector().Add(NotSystemComponent).Add(NoCleanupPrevention) // NoCleanupPreventionListOption are CollectionMatching that exclude system components or non-auto cleaned up resource. NoCleanupPreventionListOption = client.MatchingLabelsSelector{Selector: CleanupSelector} // MutatingWebhookConfigurationCleanOption is the delete selector for MutatingWebhookConfigurations. MutatingWebhookConfigurationCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // ValidatingWebhookConfigurationCleanOption is the delete selector for ValidatingWebhookConfigurations. ValidatingWebhookConfigurationCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // CustomResourceDefinitionCleanOption is the delete selector for CustomResources. CustomResourceDefinitionCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // DaemonSetCleanOption is the delete selector for DaemonSets. DaemonSetCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // DeploymentCleanOption is the delete selector for Deployments. DeploymentCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // StatefulSetCleanOption is the delete selector for StatefulSets. StatefulSetCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // ServiceCleanOption is the delete selector for Services. ServiceCleanOption = utilclient.ListWith{ client.MatchingLabelsSelector{ Selector: labels.NewSelector().Add(NotKubernetesProvider, NotSystemComponent, NoCleanupPrevention), }, } // NamespaceMatchingLabelsSelector is the delete label selector for Namespaces. NamespaceMatchingLabelsSelector = utilclient.ListWith{&NoCleanupPreventionListOption} // NamespaceMatchingFieldsSelector is the delete field selector for Namespaces. NamespaceMatchingFieldsSelector = utilclient.ListWith{ client.MatchingFieldsSelector{ Selector: fields.AndSelectors( fields.OneTermNotEqualSelector(MetadataNameField, metav1.NamespacePublic), fields.OneTermNotEqualSelector(MetadataNameField, metav1.NamespaceSystem), fields.OneTermNotEqualSelector(MetadataNameField, metav1.NamespaceDefault), fields.OneTermNotEqualSelector(MetadataNameField, corev1.NamespaceNodeLease), ), }, } // APIServiceCleanOption is the delete selector for APIServices. APIServiceCleanOption = utilclient.ListWith{ client.MatchingLabelsSelector{ Selector: labels.NewSelector().Add(NotSystemComponent, NotKubeAggregatorAutoManaged), }, } // CronJobCleanOption is the delete selector for CronJobs. CronJobCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // IngressCleanOption is the delete selector for Ingresses. IngressCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // JobCleanOption is the delete selector for Jobs. JobCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // PodCleanOption is the delete selector for Pods. PodCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // ReplicaSetCleanOption is the delete selector for ReplicaSets. ReplicaSetCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // ReplicationControllerCleanOption is the delete selector for ReplicationControllers. ReplicationControllerCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // PersistentVolumeClaimCleanOption is the delete selector for PersistentVolumeClaims. PersistentVolumeClaimCleanOption = utilclient.ListWith{&NoCleanupPreventionListOption} // NamespaceErrorToleration are the errors to be tolerated during deletion. NamespaceErrorToleration = utilclient.TolerateErrors{apierrors.IsConflict} )
var Now = time.Now
Now determines the current time.
Functions ¶
func DeleteVolumeAttachments ¶ added in v1.11.2
DeleteVolumeAttachments deletes all VolumeAttachments.
func DetermineBackupSchedule ¶ added in v1.2.0
func DetermineBackupSchedule(shoot *gardencorev1beta1.Shoot, etcd *druidv1alpha1.Etcd) (string, error)
DetermineBackupSchedule determines the backup schedule based on the shoot creation and maintenance time window.
func DetermineDefragmentSchedule ¶ added in v1.2.0
func DetermineDefragmentSchedule(shoot *gardencorev1beta1.Shoot, etcd *druidv1alpha1.Etcd, shootedSeed *gardencorev1beta1helper.ShootedSeed, role string) (string, error)
DetermineDefragmentSchedule determines the defragment schedule based on the shoot creation and maintenance time window.
func GenerateDNSProviderName ¶ added in v1.1.0
GenerateDNSProviderName creates a name for the dns provider out of the passed `secretName` and `providerType`.
func IsProblematicWebhook ¶
func IsProblematicWebhook( failurePolicy *admissionregistrationv1beta1.FailurePolicyType, objSelector *metav1.LabelSelector, nsSelector *metav1.LabelSelector, rules []admissionregistrationv1beta1.RuleWithOperations, ) bool
IsProblematicWebhook checks if a single webhook of the Shoot Cluster is problematic and the Shoot should therefore not be hibernated. Problematic webhooks are webhooks with rules for CREATE/UPDATE/* pods or nodes and failurePolicy=Fail/nil. If the Shoot contains such a webhook, we can never wake up this shoot cluster again as new nodes cannot get created/ready, or our system component pods cannot get created/ready (because the webhook's backing pod is not yet running).
func IsValidAuditPolicyVersion ¶
func IsValidAuditPolicyVersion(shootVersion string, schemaVersion *schema.GroupVersionKind) (bool, error)
IsValidAuditPolicyVersion checks whether the api server support the provided audit policy apiVersion
func PardonCondition ¶ added in v1.4.0
func PardonCondition(condition gardencorev1beta1.Condition, lastOp *gardencorev1beta1.LastOperation, lastErrors []gardencorev1beta1.LastError) gardencorev1beta1.Condition
PardonCondition pardons the given condition if the Shoot is either in create (except successful create) or delete state.
func WaitUntilDeploymentScaledToDesiredReplicas ¶ added in v1.5.0
func WaitUntilDeploymentScaledToDesiredReplicas(ctx context.Context, client client.Client, namespace, name string, desiredReplicas int32) error
WaitUntilDeploymentScaledToDesiredReplicas waits for the number of available replicas to be equal to the deployment's desired replicas count.
Types ¶
type Botanist ¶
type Botanist struct { *operation.Operation DefaultDomainSecret *corev1.Secret // contains filtered or unexported fields }
Botanist is a struct which has methods that perform cloud-independent operations for a Shoot cluster.
func New ¶
New takes an operation object <o> and creates a new Botanist object. It checks whether the given Shoot DNS domain is covered by a default domain, and if so, it sets the <DefaultDomainSecret> attribute on the Botanist object.
func (*Botanist) APIServerSNIEnabled ¶ added in v1.7.0
APIServerSNIEnabled returns true if APIServerSNI feature gate is enabled and the shoot uses internal and external DNS.
func (*Botanist) AdditionalDNSProviders ¶ added in v1.5.0
func (b *Botanist) AdditionalDNSProviders(ctx context.Context, gardenClient, seedClient client.Client) (map[string]component.DeployWaiter, error)
AdditionalDNSProviders returns a map containing DNSProviders where the key is the provider name. Providers and DNSEntries which are no longer needed / or in use, contain a DeployWaiter which removes said DNSEntry / DNSProvider.
func (*Botanist) AnnotateBackupEntryInSeedForMigration ¶ added in v1.6.0
AnnotateBackupEntryInSeedForMigration annotates the BackupEntry with gardener.cloud/operation=migrate
func (*Botanist) AnnotateExtensionCRsForMigration ¶ added in v1.5.0
AnnotateExtensionCRsForMigration annotates extension CRs with migrate operation annotation
func (*Botanist) ApplyEncryptionConfiguration ¶
ApplyEncryptionConfiguration creates or updates a secret on the Seed which contains the encryption configuration that is necessary to encrypt the Kubernetes secrets in etcd.
func (*Botanist) CheckHibernationPossible ¶
func (b *Botanist) CheckHibernationPossible(ctx context.Context, constraint gardencorev1beta1.Condition) (*gardencorev1beta1.Condition, error)
CheckHibernationPossible checks the Shoot for problematic webhooks which could prevent wakeup after hibernation
func (*Botanist) CheckTunnelConnection ¶ added in v1.6.0
func (b *Botanist) CheckTunnelConnection(ctx context.Context, logger *logrus.Entry, tunnelName string) (bool, error)
CheckTunnelConnection checks if the tunnel connection between the control plane and the shoot networks is established.
func (*Botanist) CleanExtendedAPIs ¶
CleanExtendedAPIs removes API extensions like CRDs and API services from the Shoot cluster.
func (*Botanist) CleanKubernetesResources ¶
CleanKubernetesResources deletes all the Kubernetes resources in the Shoot cluster other than those stored in the exceptions map. It will check whether all the Kubernetes resources in the Shoot cluster other than those stored in the exceptions map have been deleted. It will return an error in case it has not finished yet, and nil if all resources are gone.
func (*Botanist) CleanShootNamespaces ¶
CleanShootNamespaces deletes all non-system namespaces in the Shoot cluster. It assumes that all workload resources are cleaned up in previous step(s).
func (*Botanist) CleanWebhooks ¶
CleanWebhooks deletes all Webhooks in the Shoot cluster that are not being managed by the addon manager.
func (*Botanist) ComputeShootOperatingSystemConfig ¶
ComputeShootOperatingSystemConfig generates the shoot operating system configuration. Both, the downloader and original configuration will be generated and stored in the shoot specific cloud config map for later usage.
func (*Botanist) ConstraintsChecks ¶
func (b *Botanist) ConstraintsChecks(ctx context.Context, initializeShootClients func() (bool, error), hibernation gardencorev1beta1.Condition) gardencorev1beta1.Condition
ConstraintsChecks conducts the constraints checks on all the given constraints.
func (*Botanist) CreateETCDSnapshot ¶ added in v1.5.0
CreateETCDSnapshot executes to the ETCD main Pod and triggers snapshot.
func (*Botanist) DefaultClusterAutoscaler ¶ added in v1.11.0
func (b *Botanist) DefaultClusterAutoscaler() (clusterautoscaler.ClusterAutoscaler, error)
DefaultClusterAutoscaler returns a deployer for the cluster-autoscaler.
func (*Botanist) DefaultContainerRuntime ¶ added in v1.10.0
func (b *Botanist) DefaultContainerRuntime(seedClient client.Client) shoot.ContainerRuntime
DefaultContainerRuntime creates the default deployer for the ContainerRuntime custom resource.
func (*Botanist) DefaultExternalDNSEntry ¶ added in v1.5.0
func (b *Botanist) DefaultExternalDNSEntry(seedClient client.Client) component.DeployWaiter
DefaultExternalDNSEntry returns DeployWaiter which removes the external DNSEntry.
func (*Botanist) DefaultExternalDNSOwner ¶ added in v1.8.0
func (b *Botanist) DefaultExternalDNSOwner(seedClient client.Client) component.DeployWaiter
DefaultExternalDNSOwner returns DeployWaiter which removes the external DNSOwner.
func (*Botanist) DefaultExternalDNSProvider ¶ added in v1.5.0
func (b *Botanist) DefaultExternalDNSProvider(seedClient client.Client) component.DeployWaiter
DefaultExternalDNSProvider returns the external DNSProvider if external DNS is enabled and if not DeployWaiter which removes the external DNSProvider.
func (*Botanist) DefaultInfrastructure ¶ added in v1.8.0
func (b *Botanist) DefaultInfrastructure(seedClient client.Client) shoot.Infrastructure
DefaultInfrastructure creates the default deployer for the Infrastructure custom resource.
func (*Botanist) DefaultInternalDNSEntry ¶ added in v1.5.0
func (b *Botanist) DefaultInternalDNSEntry(seedClient client.Client) component.DeployWaiter
DefaultInternalDNSEntry returns DeployWaiter which removes the internal DNSEntry.
func (*Botanist) DefaultInternalDNSOwner ¶ added in v1.8.0
func (b *Botanist) DefaultInternalDNSOwner(seedClient client.Client) component.DeployWaiter
DefaultInternalDNSOwner returns a DeployWaiter which removes the internal DNSOwner.
func (*Botanist) DefaultInternalDNSProvider ¶ added in v1.5.0
func (b *Botanist) DefaultInternalDNSProvider(seedClient client.Client) component.DeployWaiter
DefaultInternalDNSProvider returns the internal DNSProvider if internal DNS is enabled and if not, DeployWaiter which removes the internal DNSProvider.
func (*Botanist) DefaultKubeAPIServerSNI ¶ added in v1.7.0
func (b *Botanist) DefaultKubeAPIServerSNI() component.DeployWaiter
DefaultKubeAPIServerSNI returns a deployer for kube-apiserver SNI.
func (*Botanist) DefaultKubeAPIServerService ¶ added in v1.7.0
func (b *Botanist) DefaultKubeAPIServerService(sniPhase component.Phase) component.DeployWaiter
DefaultKubeAPIServerService returns a deployer for kube-apiserver service.
func (*Botanist) DefaultKubeControllerManager ¶ added in v1.12.0
func (b *Botanist) DefaultKubeControllerManager() (kubecontrollermanager.KubeControllerManager, error)
DefaultKubeControllerManager returns a deployer for the kube-controller-manager.
func (*Botanist) DefaultKubeScheduler ¶ added in v1.10.0
func (b *Botanist) DefaultKubeScheduler() (kubescheduler.KubeScheduler, error)
DefaultKubeScheduler returns a deployer for the kube-scheduler.
func (*Botanist) DefaultNetwork ¶ added in v1.7.0
func (b *Botanist) DefaultNetwork(seedClient client.Client) component.DeployMigrateWaiter
DefaultNetwork creates the default deployer for the Network custom resource.
func (*Botanist) DefaultNginxIngressDNSEntry ¶ added in v1.5.0
func (b *Botanist) DefaultNginxIngressDNSEntry(seedClient client.Client) component.DeployWaiter
DefaultNginxIngressDNSEntry returns a Deployer which removes existing nginx ingress DNSEntry.
func (*Botanist) DefaultNginxIngressDNSOwner ¶ added in v1.8.0
func (b *Botanist) DefaultNginxIngressDNSOwner(seedClient client.Client) component.DeployWaiter
DefaultNginxIngressDNSOwner returns DeployWaiter which removes the nginx ingress DNSOwner.
func (*Botanist) DeleteAllExtensionCRs ¶ added in v1.5.0
DeleteAllExtensionCRs deletes all extension CRs from the Shoot namespace
func (*Botanist) DeleteAllExtensionResources ¶ added in v1.3.0
DeleteAllExtensionResources deletes all extension resources from the Shoot namespace in the Seed.
func (*Botanist) DeleteAllManagedResourcesObjects ¶ added in v1.5.0
DeleteAllManagedResourcesObjects deletes all managed resources from the Shoot namespace in the Seed.
func (*Botanist) DeleteAllOperatingSystemConfigs ¶ added in v1.3.0
DeleteAllOperatingSystemConfigs deletes all operating system config resources in the shoot namespace in the seed.
func (*Botanist) DeleteBackupEntryFromSeed ¶ added in v1.6.0
DeleteBackupEntryFromSeed deletes the migrated BackupEntry from the Seed
func (*Botanist) DeleteClusterAutoscaler ¶
DeleteClusterAutoscaler deletes the cluster-autoscaler deployment in the Seed cluster which holds the Shoot's control plane.
func (*Botanist) DeleteDNSProviders ¶ added in v1.1.0
DeleteDNSProviders deletes all DNS providers in the shoot namespace of the seed.
func (*Botanist) DeleteKubeAPIServer ¶
DeleteKubeAPIServer deletes the kube-apiserver deployment in the Seed cluster which holds the Shoot's control plane.
func (*Botanist) DeleteManagedResources ¶
DeleteManagedResources deletes all managed resources labeled with `origin=gardener` from the Shoot namespace in the Seed.
func (*Botanist) DeleteNamespace ¶
DeleteNamespace deletes the namespace in the Seed cluster which holds the control plane components. The built-in garbage collection in Kubernetes will automatically delete all resources which belong to this namespace. This comprises volumes and load balancers as well.
func (*Botanist) DeleteSeedMonitoring ¶
DeleteSeedMonitoring will delete the monitoring stack from the Seed cluster to avoid phantom alerts during the deletion process. More precisely, the Alertmanager and Prometheus StatefulSets will be deleted.
func (*Botanist) DeleteStaleExtensionResources ¶
DeleteStaleExtensionResources deletes unused extensions from the shoot namespace in the seed.
func (*Botanist) DeleteStaleOperatingSystemConfigs ¶ added in v1.3.0
func (b *Botanist) DeleteStaleOperatingSystemConfigs(ctx context.Context, wantedOSCNames sets.String) error
DeleteStaleOperatingSystemConfigs deletes all unused operating system configs in the shoot seed namespace (i.e., those which are not part of the provided map <usedOscNames>.
func (*Botanist) DeployBackupEntryInGarden ¶
DeployBackupEntryInGarden deploys the BackupEntry resource in garden.
func (*Botanist) DeployCloudProviderSecret ¶
DeployCloudProviderSecret creates or updates the cloud provider secret in the Shoot namespace in the Seed cluster.
func (*Botanist) DeployClusterAutoscaler ¶
DeployClusterAutoscaler deploys the Kubernetes cluster-autoscaler.
func (*Botanist) DeployContainerRuntime ¶ added in v1.10.0
DeployContainerRuntime deploys the ContainerRuntime custom resources and triggers the restore operation in case the Shoot is in the restore phase of the control plane migration
func (*Botanist) DeployControlPlane ¶
DeployControlPlane creates the `ControlPlane` extension resource in the shoot namespace in the seed cluster. Gardener waits until an external controller did reconcile the cluster successfully.
func (*Botanist) DeployControlPlaneExposure ¶
DeployControlPlaneExposure creates the `ControlPlane` extension resource with purpose `exposure` in the shoot namespace in the seed cluster. Gardener waits until an external controller did reconcile the cluster successfully.
func (*Botanist) DeployETCD ¶
DeployETCD deploys two etcd clusters via StatefulSets. The first etcd cluster (called 'main') is used for all the data the Shoot Kubernetes cluster needs to store, whereas the second etcd luster (called 'events') is only used to store the events data. The objectstore is also set up to store the backups.
func (*Botanist) DeployExtensionResources ¶
DeployExtensionResources creates the `Extension` extension resource in the shoot namespace in the seed cluster. Gardener waits until an external controller did reconcile the cluster successfully.
func (*Botanist) DeployExternalDNS ¶ added in v1.5.0
DeployExternalDNS deploys the external DNSOwner, DNSProvider, and DNSEntry resources.
func (*Botanist) DeployGardenerResourceManager ¶
DeployGardenerResourceManager deploys the gardener-resource-manager which will use CRD resources in order to ensure that they exist in a cluster/reconcile them in case somebody changed something.
func (*Botanist) DeployInfrastructure ¶
DeployInfrastructure deploys the Infrastructure custom resource and triggers the restore operation in case the Shoot is in the restore phase of the control plane migration.
func (*Botanist) DeployInternalDNS ¶ added in v1.5.0
DeployInternalDNS deploys the internal DNSOwner, DNSProvider, and DNSEntry resources.
func (*Botanist) DeployKubeAPIServer ¶
DeployKubeAPIServer deploys kube-apiserver deployment.
func (*Botanist) DeployKubeAPIServerSNI ¶ added in v1.7.0
DeployKubeAPIServerSNI deploys the kube-apiserver-sni chart.
func (*Botanist) DeployKubeAPIService ¶ added in v1.11.0
DeployKubeAPIService deploys for kube-apiserver service.
func (*Botanist) DeployKubeControllerManager ¶
DeployKubeControllerManager deploys the Kubernetes Controller Manager.
func (*Botanist) DeployKubeScheduler ¶
DeployKubeScheduler deploys the Kubernetes scheduler.
func (*Botanist) DeployManagedResources ¶
DeployManagedResources deploys all the ManagedResource CRDs for the gardener-resource-manager.
func (*Botanist) DeployNamespace ¶
DeployNamespace creates a namespace in the Seed cluster which is used to deploy all the control plane components for the Shoot cluster. Moreover, the cloud provider configuration and all the secrets will be stored as ConfigMaps/Secrets.
func (*Botanist) DeployNetwork ¶
DeployNetwork deploys the Network custom resource and triggers the restore operation in case the Shoot is in the restore phase of the control plane migration
func (*Botanist) DeployNetworkPolicies ¶
DeployNetworkPolicies creates a network policies in a Shoot cluster's namespace that deny all traffic and allow certain components to use annotations to declare their desire to transmit/receive traffic to/from other Pods/IP addresses.
func (*Botanist) DeployReferencedResources ¶ added in v1.6.0
DeployReferencedResources reads all referenced resources from the Garden cluster and writes a managed resource to the Seed cluster.
func (*Botanist) DeploySecrets ¶
DeploySecrets takes all existing secrets from the ShootState resource and deploys them in the shoot's control plane.
func (*Botanist) DeploySeedLogging ¶
DeploySeedLogging will install the Helm release "seed-bootstrap/charts/loki" in the Seed clusters.
func (*Botanist) DeploySeedMonitoring ¶
DeploySeedMonitoring will install the Helm release "seed-monitoring" in the Seed clusters. It comprises components to monitor the Shoot cluster whose control plane runs in the Seed cluster.
func (*Botanist) DeployVerticalPodAutoscaler ¶ added in v1.7.0
DeployVerticalPodAutoscaler deploys the VPA into the shoot namespace in the seed.
func (*Botanist) DeployWorker ¶
DeployWorker creates the `Worker` extension resource in the shoot namespace in the seed cluster. Gardener waits until an external controller did reconcile the resource successfully.
func (*Botanist) DestroyControlPlane ¶
DestroyControlPlane deletes the `ControlPlane` extension resource in the shoot namespace in the seed cluster, and it waits for a maximum of 10m until it is deleted.
func (*Botanist) DestroyControlPlaneExposure ¶
DestroyControlPlaneExposure deletes the `ControlPlane` extension resource with purpose `exposure` in the shoot namespace in the seed cluster, and it waits for a maximum of 10m until it is deleted.
func (*Botanist) DestroyExternalDNS ¶ added in v1.8.0
DestroyExternalDNS destroys the external DNSEntry, DNSOwner, and DNSProvider resources.
func (*Botanist) DestroyIngressDNSRecord ¶
DestroyIngressDNSRecord destroys the nginx ingress DNSEntry and DNSOwner resources.
func (*Botanist) DestroyInternalDNS ¶ added in v1.8.0
DestroyInternalDNS destroys the internal DNSEntry, DNSOwner, and DNSProvider resources.
func (*Botanist) DestroyReferencedResources ¶ added in v1.6.0
DestroyReferencedResources deletes the managed resource containing referenced resources from the Seed cluster.
func (*Botanist) DestroyWorker ¶
DestroyWorker deletes the `Worker` extension resource in the shoot namespace in the seed cluster, and it waits for a maximum of 5m until it is deleted.
func (*Botanist) EnsureClusterIdentity ¶ added in v1.8.0
EnsureClusterIdentity ensures that Shoot cluster-identity ConfigMap exists and stores its data in the operation. Updates shoot.status.clusterIdentity if it doesn't exist already.
func (*Botanist) EnsureIngressDNSRecord ¶
EnsureIngressDNSRecord deploys the nginx ingress DNSEntry and DNSOwner resources.
func (*Botanist) GenerateAndSaveSecrets ¶ added in v1.7.0
GenerateAndSaveSecrets creates a CA certificate for the Shoot cluster and uses it to sign the server certificate used by the kube-apiserver, and all client certificates used for communication. It also creates RSA key pairs for SSH connections to the nodes/VMs and for the VPN tunnel. Moreover, basic authentication credentials are computed which will be used to secure the Ingress resources and the kube-apiserver itself. Server certificates for the exposed monitoring endpoints (via Ingress) are generated as well.
func (*Botanist) GenerateEncryptionConfiguration ¶ added in v1.4.0
GenerateEncryptionConfiguration generates new encryption configuration data or syncs it from the etcd encryption configuration secret if it already exists.
func (*Botanist) GenerateKubernetesDashboardConfig ¶
GenerateKubernetesDashboardConfig generates the values which are required to render the chart of the kubernetes-dashboard properly.
func (*Botanist) GenerateNginxIngressConfig ¶
GenerateNginxIngressConfig generates the values which are required to render the chart of the nginx-ingress properly.
func (*Botanist) HealthChecks ¶
func (b *Botanist) HealthChecks( ctx context.Context, initializeShootClients func() (bool, error), thresholdMappings map[gardencorev1beta1.ConditionType]time.Duration, healthCheckOutdatedThreshold *metav1.Duration, apiserverAvailability, controlPlane, nodes, systemComponents gardencorev1beta1.Condition, ) ( gardencorev1beta1.Condition, gardencorev1beta1.Condition, gardencorev1beta1.Condition, gardencorev1beta1.Condition, )
HealthChecks conducts the health checks on all the given conditions.
func (*Botanist) HibernateControlPlane ¶
HibernateControlPlane hibernates the entire control plane if the shoot shall be hibernated.
func (*Botanist) KeepManagedResourcesObjects ¶ added in v1.5.0
KeepManagedResourcesObjects sets ManagedResource.Spec.KeepObjects to true.
func (*Botanist) MaintainShootAnnotations ¶ added in v1.0.0
MaintainShootAnnotations ensures that given deprecated Shoot annotations are maintained also with their new equivalent in the Shoot metadata.
func (*Botanist) MigrateExternalDNS ¶ added in v1.8.0
MigrateExternalDNS destroys the external DNSEntry, DNSOwner, and DNSProvider resources, without removing the entry from the DNS provider.
func (*Botanist) MigrateIngressDNSRecord ¶ added in v1.8.0
MigrateIngressDNSRecord destroys the nginx ingress DNSEntry and DNSOwner resources, without removing the entry from the DNS provider.
func (*Botanist) MigrateInternalDNS ¶ added in v1.8.0
MigrateInternalDNS destroys the internal DNSEntry, DNSOwner, and DNSProvider resources, without removing the entry from the DNS provider.
func (*Botanist) NeedsAdditionalDNSProviders ¶ added in v1.5.0
NeedsAdditionalDNSProviders returns true if additional DNS providers are needed.
func (*Botanist) NeedsExternalDNS ¶ added in v1.5.0
NeedsExternalDNS returns true if the Shoot cluster needs external DNS.
func (*Botanist) NeedsInternalDNS ¶ added in v1.5.0
NeedsInternalDNS returns true if the Shoot cluster needs internal DNS.
func (*Botanist) PerformGarbageCollectionSeed ¶
PerformGarbageCollectionSeed performs garbage collection in the Shoot namespace in the Seed cluster
func (*Botanist) PerformGarbageCollectionShoot ¶
PerformGarbageCollectionShoot performs garbage collection in the kube-system namespace in the Shoot cluster, i.e., it deletes evicted pods (mitigation for https://github.com/kubernetes/kubernetes/issues/55051).
func (*Botanist) PersistEncryptionConfiguration ¶ added in v1.4.0
PersistEncryptionConfiguration adds the encryption configuration to the ShootState.
func (*Botanist) PrepareKubeAPIServerForMigration ¶ added in v1.6.0
PrepareKubeAPIServerForMigration deletes the kube-apiserver and deletes its hvpa
func (*Botanist) RemoveOldETCDEncryptionSecretFromGardener ¶ added in v1.4.0
RemoveOldETCDEncryptionSecretFromGardener removes the etcd encryption configuration secret from the Shoot's namespace in the garden cluster as it is no longer necessary. This step can be removed in the future after all secrets have been cleaned up.
func (*Botanist) RequiredExtensionsReady ¶ added in v1.3.0
RequiredExtensionsReady checks whether all required extensions needed for a shoot operation exist and are ready.
func (*Botanist) RestartControlPlanePods ¶ added in v1.2.0
RestartControlPlanePods restarts (deletes) pods of the shoot control plane.
func (*Botanist) RewriteShootSecretsIfEncryptionConfigurationChanged ¶
RewriteShootSecretsIfEncryptionConfigurationChanged rewrites the secrets in the Shoot if the etcd encryption configuration changed. Rewriting here means that a patch request is sent that forces the etcd to encrypt them with the new configuration.
func (*Botanist) SNIPhase ¶ added in v1.11.0
SNIPhase returns the current phase of the SNI enablement of kube-apiserver's service.
func (*Botanist) ScaleETCDToOne ¶ added in v1.5.0
ScaleETCDToOne scales ETCD main and events replicas to one
func (*Botanist) ScaleETCDToZero ¶ added in v1.5.0
ScaleETCDToZero scales ETCD main and events to zero
func (*Botanist) ScaleGardenerResourceManagerToOne ¶ added in v1.5.0
ScaleGardenerResourceManagerToOne scales the gardener-resource-manager deployment
func (*Botanist) ScaleKubeAPIServerToOne ¶ added in v1.12.0
ScaleKubeAPIServerToOne scales kube-apiserver replicas to one
func (*Botanist) ScaleKubeControllerManagerToOne ¶ added in v1.12.0
ScaleKubeControllerManagerToOne scales kube-controller-manager replicas to one
func (*Botanist) SetNginxIngressAddress ¶ added in v1.5.0
SetNginxIngressAddress sets the IP address of the API server's LoadBalancer.
func (*Botanist) SyncShootCredentialsToGarden ¶
SyncShootCredentialsToGarden copies the kubeconfig generated for the user, the SSH keypair to the project namespace in the Garden cluster and the monitoring credentials for the user-facing monitoring stack are also copied.
func (*Botanist) UpdateShootAndCluster ¶ added in v1.7.0
func (b *Botanist) UpdateShootAndCluster(ctx context.Context, shoot *gardencorev1beta1.Shoot, transform func() error) error
UpdateShootAndCluster updates the given `core.gardener.cloud/v1beta1.Shoot` resource in the garden cluster after applying the given transform function to it. It will also update the `shoot` field in the extensions.gardener.cloud/v1alpha1.Cluster` resource in the seed cluster with the updated shoot information.
func (*Botanist) WaitForBackupEntryOperationMigrateToSucceed ¶ added in v1.6.0
WaitForBackupEntryOperationMigrateToSucceed waits until BackupEntry has lastOperation equal to Migrate=Succeeded
func (*Botanist) WaitForExtensionsOperationMigrateToSucceed ¶ added in v1.5.0
WaitForExtensionsOperationMigrateToSucceed waits until extension CRs has lastOperation Migrate Succeeded
func (*Botanist) WaitForInfrastructure ¶ added in v1.8.0
WaitForInfrastructure waits until the infrastructure reconciliation has finished and extracts the provider status out of it.
func (*Botanist) WaitForKubeControllerManagerToBeActive ¶ added in v1.12.0
WaitForKubeControllerManagerToBeActive waits for the kube controller manager of a Shoot cluster has acquired leader election, thus is active.
func (*Botanist) WaitUntilAllManagedResourcesDeleted ¶ added in v1.5.0
WaitUntilAllManagedResourcesDeleted waits until all managed resources are gone or the context is cancelled.
func (*Botanist) WaitUntilBackupEntryInGardenReconciled ¶
WaitUntilBackupEntryInGardenReconciled waits until the backup entry within the garden cluster has been reconciled.
func (*Botanist) WaitUntilControlPlaneDeleted ¶
WaitUntilControlPlaneDeleted waits until the control plane resource has been deleted.
func (*Botanist) WaitUntilControlPlaneExposureDeleted ¶
WaitUntilControlPlaneExposureDeleted waits until the control plane resource with purpose `exposure` has been deleted.
func (*Botanist) WaitUntilControlPlaneExposureReady ¶
WaitUntilControlPlaneExposureReady waits until the control plane resource with purpose `exposure` has been reconciled successfully.
func (*Botanist) WaitUntilControlPlaneReady ¶
WaitUntilControlPlaneReady waits until the control plane resource has been reconciled successfully.
func (*Botanist) WaitUntilEndpointsDoNotContainPodIPs ¶
WaitUntilEndpointsDoNotContainPodIPs waits until all endpoints in the shoot cluster to not contain any IPs from the Shoot's PodCIDR.
func (*Botanist) WaitUntilEtcdReady ¶
WaitUntilEtcdReady waits until the etcd statefulsets indicate readiness in their statuses.
func (*Botanist) WaitUntilExtensionResourcesDeleted ¶
WaitUntilExtensionResourcesDeleted waits until all extension resources are gone or the context is cancelled.
func (*Botanist) WaitUntilExtensionResourcesReady ¶
WaitUntilExtensionResourcesReady waits until all extension resources report `Succeeded` in their last operation state. The state must be reported before the passed context is cancelled or an extension's timeout has been reached. As soon as one timeout has been overstepped the function returns an error, further waits on extensions will be aborted.
func (*Botanist) WaitUntilKubeAPIServerIsDeleted ¶ added in v1.6.0
WaitUntilKubeAPIServerIsDeleted waits until the kube-apiserver is deleted
func (*Botanist) WaitUntilKubeAPIServerReady ¶
WaitUntilKubeAPIServerReady waits until the kube-apiserver pod(s) indicate readiness in their statuses.
func (*Botanist) WaitUntilManagedResourcesDeleted ¶
WaitUntilManagedResourcesDeleted waits until all managed resources labeled with `origin=gardener` are gone or the context is cancelled.
func (*Botanist) WaitUntilNginxIngressServiceIsReady ¶ added in v1.5.0
WaitUntilNginxIngressServiceIsReady waits until the external load balancer of the nginx ingress controller has been created.
func (*Botanist) WaitUntilNoPodRunning ¶
WaitUntilNoPodRunning waits until there is no running Pod in the shoot cluster.
func (*Botanist) WaitUntilNodesDeleted ¶
WaitUntilNodesDeleted waits until no nodes exist in the shoot cluster anymore.
func (*Botanist) WaitUntilRequiredExtensionsReady ¶ added in v1.3.0
WaitUntilRequiredExtensionsReady waits until all the extensions required for a shoot reconciliation are ready
func (*Botanist) WaitUntilSeedNamespaceDeleted ¶
WaitUntilSeedNamespaceDeleted waits until the namespace of the Shoot cluster within the Seed cluster is deleted.
func (*Botanist) WaitUntilShootLoadBalancerIsReady ¶ added in v1.12.0
func (b *Botanist) WaitUntilShootLoadBalancerIsReady(ctx context.Context, namespace, name string, timeout time.Duration) (string, error)
WaitUntilShootLoadBalancerIsReady waits until the given external load balancer has been created (i.e., its ingress information has been updated in the service status).
func (*Botanist) WaitUntilTunnelConnectionExists ¶ added in v1.6.0
WaitUntilTunnelConnectionExists waits until a port forward connection to the tunnel pod (vpn-shoot or konnectivity-agent) in the kube-system namespace of the Shoot cluster can be established.
func (*Botanist) WaitUntilVpnShootServiceIsReady ¶ added in v1.12.0
WaitUntilVpnShootServiceIsReady waits until the external load balancer of the VPN has been created.
func (*Botanist) WaitUntilWorkerDeleted ¶
WaitUntilWorkerDeleted waits until the worker extension resource has been deleted.
func (*Botanist) WaitUntilWorkerReady ¶
WaitUntilWorkerReady waits until the worker extension resource has been successfully reconciled.
type ExtensionCondition ¶ added in v1.4.0
type ExtensionCondition struct { Condition gardencorev1beta1.Condition ExtensionType string ExtensionName string ExtensionNamespace string }
ExtensionCondition contains information about the extension type, name, namespace and the respective condition object.
type HealthChecker ¶
type HealthChecker struct {
// contains filtered or unexported fields
}
HealthChecker contains the condition thresholds.
func NewHealthChecker ¶
func NewHealthChecker(conditionThresholds map[gardencorev1beta1.ConditionType]time.Duration, healthCheckOutdatedThreshold *metav1.Duration, lastOperation *gardencorev1beta1.LastOperation, kubernetesVersion *semver.Version) *HealthChecker
NewHealthChecker creates a new health checker.
func (*HealthChecker) CheckClusterNodes ¶
func (b *HealthChecker) CheckClusterNodes( workers []gardencorev1beta1.Worker, condition gardencorev1beta1.Condition, nodeLister kutil.NodeLister, ) (*gardencorev1beta1.Condition, error)
CheckClusterNodes checks whether cluster nodes in the given listers are healthy and within the desired range. Additional checks are executed in the provider extension
func (*HealthChecker) CheckControlPlane ¶
func (b *HealthChecker) CheckControlPlane( shoot *gardencorev1beta1.Shoot, namespace string, condition gardencorev1beta1.Condition, deploymentLister kutil.DeploymentLister, etcdLister kutil.EtcdLister, workerLister kutil.WorkerLister, ) (*gardencorev1beta1.Condition, error)
CheckControlPlane checks whether the control plane components in the given listers are complete and healthy.
func (*HealthChecker) CheckExtensionCondition ¶
func (b *HealthChecker) CheckExtensionCondition(condition gardencorev1beta1.Condition, extensionsConditions []ExtensionCondition) *gardencorev1beta1.Condition
CheckExtensionCondition checks whether the conditions provided by extensions are healthy.
func (*HealthChecker) CheckLoggingControlPlane ¶
func (b *HealthChecker) CheckLoggingControlPlane( namespace string, checkObsolete bool, condition gardencorev1beta1.Condition, statefulSetLister kutil.StatefulSetLister, ) (*gardencorev1beta1.Condition, error)
CheckLoggingControlPlane checks whether the logging components in the given listers are complete and healthy.
func (*HealthChecker) CheckManagedResource ¶ added in v1.6.0
func (b *HealthChecker) CheckManagedResource(condition gardencorev1beta1.Condition, mr *resourcesv1alpha1.ManagedResource) *gardencorev1beta1.Condition
CheckManagedResource checks the conditions of the given managed resource and reflects the state in the returned condition.
func (*HealthChecker) CheckMonitoringControlPlane ¶
func (b *HealthChecker) CheckMonitoringControlPlane( namespace string, isTestingShoot bool, wantsAlertmanager bool, condition gardencorev1beta1.Condition, deploymentLister kutil.DeploymentLister, statefulSetLister kutil.StatefulSetLister, ) (*gardencorev1beta1.Condition, error)
CheckMonitoringControlPlane checks whether the monitoring in the given listers are complete and healthy.
func (*HealthChecker) FailedCondition ¶
func (b *HealthChecker) FailedCondition(condition gardencorev1beta1.Condition, reason, message string, codes ...gardencorev1beta1.ErrorCode) gardencorev1beta1.Condition
FailedCondition returns a progressing or false condition depending on the progressing threshold.
type SortableEvents ¶ added in v1.12.0
SortableEvents implements sort.Interface for []api.Event based on the Timestamp field.
func (SortableEvents) Len ¶ added in v1.12.0
func (list SortableEvents) Len() int
Len implements sort.Interface.
func (SortableEvents) Less ¶ added in v1.12.0
func (list SortableEvents) Less(i, j int) bool
Less implements sort.Interface.
func (SortableEvents) Swap ¶ added in v1.12.0
func (list SortableEvents) Swap(i, j int)
Swap implements sort.Interface.
Source Files ¶
- addons.go
- botanist.go
- cleanup.go
- constraints_check.go
- containerruntime.go
- controlplane.go
- dns.go
- etcdencryption.go
- event.go
- extension.go
- garbage_collection.go
- health_check.go
- infrastructure.go
- logging.go
- managedresources.go
- metadata.go
- migration.go
- monitoring.go
- network.go
- operatingsystemconfig.go
- resources.go
- secrets.go
- types.go
- volumeattachments.go
- waiter.go
- wanted_secrets.go
- worker.go
Directories ¶
Path | Synopsis |
---|---|
addons
|
|
extensions
|
|
this file is copy of https://github.com/kubernetes/kubernetes/blob/f247e75980061d7cf83c63c0fb1f12c7060c599f/staging/src/k8s.io/apiserver/pkg/admission/plugin/webhook/rules/rules.go with some modifications for the webhook matching use-case.
|
this file is copy of https://github.com/kubernetes/kubernetes/blob/f247e75980061d7cf83c63c0fb1f12c7060c599f/staging/src/k8s.io/apiserver/pkg/admission/plugin/webhook/rules/rules.go with some modifications for the webhook matching use-case. |