Documentation ¶
Index ¶
- Variables
- func DetermineCloudProviderInProfile(spec gardenv1beta1.CloudProfileSpec) (gardenv1beta1.CloudProvider, error)
- func DetermineCloudProviderInShoot(cloudObj gardenv1beta1.Cloud) (gardenv1beta1.CloudProvider, error)
- func DetermineLatestKubernetesPatchVersion(cloudProfile gardenv1beta1.CloudProfile, currentVersion string) (bool, string, error)
- func DetermineLatestMachineImageVersion(image gardenv1beta1.MachineImage) (*semver.Version, gardenv1beta1.MachineImageVersion, error)
- func DetermineMachineImageForName(cloudProfile gardenv1beta1.CloudProfile, name string) (bool, gardenv1beta1.MachineImage, error)
- func DetermineNextKubernetesMinorVersion(cloudProfile gardenv1beta1.CloudProfile, currentVersion string) (bool, string, error)
- func GetDefaultMachineImageFromShoot(cloudProvider gardenv1beta1.CloudProvider, shoot *gardenv1beta1.Shoot) *gardenv1beta1.ShootMachineImage
- func GetK8SNetworks(shoot *gardenv1beta1.Shoot) (*gardenv1beta1.K8SNetworks, error)
- func GetKubernetesVersionsFromCloudProfile(cloudProfile gardenv1beta1.CloudProfile) ([]gardenv1beta1.KubernetesVersion, error)
- func GetMachineImagesFromCloudProfile(profile *gardenv1beta1.CloudProfile) ([]gardenv1beta1.MachineImage, error)
- func GetMachineImagesFromShoot(shoot *gardenv1beta1.Shoot) ([]*gardenv1beta1.ShootMachineImage, error)
- func GetMachineImagesFromShootForCloudProvider(cloudProvider gardenv1beta1.CloudProvider, shoot *gardenv1beta1.Shoot) []*gardenv1beta1.ShootMachineImage
- func GetMachineTypesFromCloudProfile(cloudProvider gardenv1beta1.CloudProvider, profile *gardenv1beta1.CloudProfile) []gardenv1beta1.MachineType
- func GetShootCloudProvider(shoot *gardenv1beta1.Shoot) (gardenv1beta1.CloudProvider, error)
- func GetShootCloudProviderWorkers(cloudProvider gardenv1beta1.CloudProvider, shoot *gardenv1beta1.Shoot) []gardenv1beta1.Worker
- func GetShootMachineImageFromLatestMachineImageVersion(image gardenv1beta1.MachineImage) (*semver.Version, gardenv1beta1.ShootMachineImage, error)
- func GetZones(shoot gardenv1beta1.Shoot, cloudProfile *gardenv1beta1.CloudProfile) (gardenv1beta1.CloudProvider, []gardenv1beta1.Zone, error)
- func HibernationIsEnabled(shoot *gardenv1beta1.Shoot) bool
- func KubernetesVersionExistsInCloudProfile(cloudProfile gardenv1beta1.CloudProfile, currentVersion string) (bool, gardenv1beta1.KubernetesVersion, error)
- func SetKubernetesVersions(profile *gardenv1beta1.CloudProfile, ...) error
- func SetMachineImageVersionsToMachineImage(machineImages []gardenv1beta1.MachineImage, imageName string, ...) ([]gardenv1beta1.MachineImage, error)
- func SetMachineImages(profile *gardenv1beta1.CloudProfile, images []gardenv1beta1.MachineImage) error
- func SetZoneForShoot(shoot *gardenv1beta1.Shoot, cloudProvider gardenv1beta1.CloudProvider, ...)
- func ShootIgnoreAlerts(shoot *gardenv1beta1.Shoot) bool
- func ShootMachineImageVersionExists(constraint gardenv1beta1.MachineImage, image gardenv1beta1.ShootMachineImage) (bool, int)
- func ShootWantsAlertmanager(shoot *gardenv1beta1.Shoot, secrets map[string]*corev1.Secret) bool
- func ShootWantsBasicAuthentication(shoot *gardenv1beta1.Shoot) bool
- func ShootWantsClusterAutoscaler(shoot *gardenv1beta1.Shoot) (bool, error)
- func UpdateDefaultMachineImage(cloudProvider gardenv1beta1.CloudProvider, ...) func(*gardenv1beta1.Cloud)
- func UpdateMachineImages(cloudProvider gardenv1beta1.CloudProvider, ...) func(*gardenv1beta1.Cloud)
- type ShootedSeed
- type ShootedSeedAPIServer
- type ShootedSeedAPIServerAutoscaler
Constants ¶
This section is empty.
Variables ¶
var Now = metav1.Now
Now determines the current metav1.Time.
Functions ¶
func DetermineCloudProviderInProfile ¶
func DetermineCloudProviderInProfile(spec gardenv1beta1.CloudProfileSpec) (gardenv1beta1.CloudProvider, error)
DetermineCloudProviderInProfile takes a CloudProfile specification and returns the cloud provider this profile is used for. If it is not able to determine it, an error will be returned.
func DetermineCloudProviderInShoot ¶
func DetermineCloudProviderInShoot(cloudObj gardenv1beta1.Cloud) (gardenv1beta1.CloudProvider, error)
DetermineCloudProviderInShoot takes a Shoot cloud object and returns the cloud provider this profile is used for. If it is not able to determine it, an error will be returned.
func DetermineLatestKubernetesPatchVersion ¶
func DetermineLatestKubernetesPatchVersion(cloudProfile gardenv1beta1.CloudProfile, currentVersion string) (bool, string, error)
DetermineLatestKubernetesPatchVersion finds the latest Kubernetes patch version in the <cloudProfile> compared to the given <currentVersion>. In case it does not find a newer patch version, it returns false. Otherwise, true and the found version will be returned.
func DetermineLatestMachineImageVersion ¶
func DetermineLatestMachineImageVersion(image gardenv1beta1.MachineImage) (*semver.Version, gardenv1beta1.MachineImageVersion, error)
DetermineLatestMachineImageVersion determines the latest MachineImageVersion from a MachineImage
func DetermineMachineImageForName ¶
func DetermineMachineImageForName(cloudProfile gardenv1beta1.CloudProfile, name string) (bool, gardenv1beta1.MachineImage, error)
DetermineMachineImageForName finds the cloud specific machine images in the <cloudProfile> for the given <name> and region. In case it does not find the machine image with the <name>, it returns false. Otherwise, true and the cloud-specific machine image will be returned.
func DetermineNextKubernetesMinorVersion ¶
func DetermineNextKubernetesMinorVersion(cloudProfile gardenv1beta1.CloudProfile, currentVersion string) (bool, string, error)
DetermineNextKubernetesMinorVersion finds the next available Kubernetes minor version in the <cloudProfile> compared to the given <currentVersion>. In case it does not find a newer minor version, it returns false. Otherwise, true and the found version will be returned.
func GetDefaultMachineImageFromShoot ¶
func GetDefaultMachineImageFromShoot(cloudProvider gardenv1beta1.CloudProvider, shoot *gardenv1beta1.Shoot) *gardenv1beta1.ShootMachineImage
GetDefaultMachineImageFromShoot returns the machine image used in a shoot manifest, however, it requires the cloud provider as input.
func GetK8SNetworks ¶
func GetK8SNetworks(shoot *gardenv1beta1.Shoot) (*gardenv1beta1.K8SNetworks, error)
GetK8SNetworks returns the Kubernetes network CIDRs for the Shoot cluster.
func GetKubernetesVersionsFromCloudProfile ¶
func GetKubernetesVersionsFromCloudProfile(cloudProfile gardenv1beta1.CloudProfile) ([]gardenv1beta1.KubernetesVersion, error)
GetKubernetesVersionsFromCloudProfile returns the Kubernetes Versions from a CloudProfile
func GetMachineImagesFromCloudProfile ¶
func GetMachineImagesFromCloudProfile(profile *gardenv1beta1.CloudProfile) ([]gardenv1beta1.MachineImage, error)
GetMachineImagesFromCloudProfile returns a list of machine images from the cloud profile
func GetMachineImagesFromShoot ¶
func GetMachineImagesFromShoot(shoot *gardenv1beta1.Shoot) ([]*gardenv1beta1.ShootMachineImage, error)
GetMachineImagesFromShoot returns the machine image used in a shoot manifest.
func GetMachineImagesFromShootForCloudProvider ¶
func GetMachineImagesFromShootForCloudProvider(cloudProvider gardenv1beta1.CloudProvider, shoot *gardenv1beta1.Shoot) []*gardenv1beta1.ShootMachineImage
GetMachineImagesFromShootForCloudProvider returns the machine images used in a shoot manifest, however, it requires the cloudprovider as input.
func GetMachineTypesFromCloudProfile ¶
func GetMachineTypesFromCloudProfile(cloudProvider gardenv1beta1.CloudProvider, profile *gardenv1beta1.CloudProfile) []gardenv1beta1.MachineType
GetMachineTypesFromCloudProfile retrieves list of machine types from cloud profile
func GetShootCloudProvider ¶
func GetShootCloudProvider(shoot *gardenv1beta1.Shoot) (gardenv1beta1.CloudProvider, error)
GetShootCloudProvider retrieves the cloud provider used for the given Shoot.
func GetShootCloudProviderWorkers ¶
func GetShootCloudProviderWorkers(cloudProvider gardenv1beta1.CloudProvider, shoot *gardenv1beta1.Shoot) []gardenv1beta1.Worker
GetShootCloudProviderWorkers retrieves the cloud-specific workers of the given Shoot.
func GetShootMachineImageFromLatestMachineImageVersion ¶
func GetShootMachineImageFromLatestMachineImageVersion(image gardenv1beta1.MachineImage) (*semver.Version, gardenv1beta1.ShootMachineImage, error)
GetShootMachineImageFromLatestMachineImageVersion determines the latest version in a machine image and returns that as a ShootMachineImage
func GetZones ¶
func GetZones(shoot gardenv1beta1.Shoot, cloudProfile *gardenv1beta1.CloudProfile) (gardenv1beta1.CloudProvider, []gardenv1beta1.Zone, error)
GetZones returns the CloudProvide, the Zones for the CloudProfile and an error Returns an empty Zone slice for Azure
func HibernationIsEnabled ¶
func HibernationIsEnabled(shoot *gardenv1beta1.Shoot) bool
HibernationIsEnabled checks if the given shoot's desired state is hibernated.
func KubernetesVersionExistsInCloudProfile ¶
func KubernetesVersionExistsInCloudProfile(cloudProfile gardenv1beta1.CloudProfile, currentVersion string) (bool, gardenv1beta1.KubernetesVersion, error)
KubernetesVersionExistsInCloudProfile checks if the given Kubernetes version exists in the CloudProfile
func SetKubernetesVersions ¶
func SetKubernetesVersions(profile *gardenv1beta1.CloudProfile, offeredVersions []gardenv1beta1.KubernetesVersion, versions []string) error
SetKubernetesVersions sets the Kubernetes Versions to the CloudProfile
func SetMachineImageVersionsToMachineImage ¶
func SetMachineImageVersionsToMachineImage(machineImages []gardenv1beta1.MachineImage, imageName string, imageVersions []gardenv1beta1.MachineImageVersion) ([]gardenv1beta1.MachineImage, error)
SetMachineImageVersionsToMachineImage sets imageVersions to the matching imageName in the machineImages.
func SetMachineImages ¶
func SetMachineImages(profile *gardenv1beta1.CloudProfile, images []gardenv1beta1.MachineImage) error
SetMachineImages sets imageVersions to the matching imageName in the machineImages.
func SetZoneForShoot ¶
func SetZoneForShoot(shoot *gardenv1beta1.Shoot, cloudProvider gardenv1beta1.CloudProvider, zones []string)
SetZoneForShoot sets the Zone for the shoot for the specific Cloud provider. Azure does not have Zones, so it is being ignored.
func ShootIgnoreAlerts ¶
func ShootIgnoreAlerts(shoot *gardenv1beta1.Shoot) bool
ShootIgnoreAlerts checks if the alerts for the annotated shoot cluster should be ignored.
func ShootMachineImageVersionExists ¶
func ShootMachineImageVersionExists(constraint gardenv1beta1.MachineImage, image gardenv1beta1.ShootMachineImage) (bool, int)
ShootMachineImageVersionExists checks if the shoot machine image (name, version) exists in the machine image constraint and returns true if yes and the index in the versions slice
func ShootWantsAlertmanager ¶
ShootWantsAlertmanager checks if the given Shoot needs an Alertmanger.
func ShootWantsBasicAuthentication ¶
func ShootWantsBasicAuthentication(shoot *gardenv1beta1.Shoot) bool
ShootWantsBasicAuthentication returns true if basic authentication is not configured or if it is set explicitly to 'true'.
func ShootWantsClusterAutoscaler ¶
func ShootWantsClusterAutoscaler(shoot *gardenv1beta1.Shoot) (bool, error)
ShootWantsClusterAutoscaler checks if the given Shoot needs a cluster autoscaler. This is determined by checking whether one of the Shoot workers has a different AutoScalerMax than AutoScalerMin.
func UpdateDefaultMachineImage ¶
func UpdateDefaultMachineImage(cloudProvider gardenv1beta1.CloudProvider, machineImage *gardenv1beta1.ShootMachineImage) func(*gardenv1beta1.Cloud)
UpdateDefaultMachineImage updates the default machine image.
func UpdateMachineImages ¶
func UpdateMachineImages(cloudProvider gardenv1beta1.CloudProvider, machineImages []*gardenv1beta1.ShootMachineImage) func(*gardenv1beta1.Cloud)
UpdateMachineImages updates the machine images for the given cloud provider.
Types ¶
type ShootedSeed ¶
type ShootedSeed struct { Protected *bool Visible *bool MinimumVolumeSize *string APIServer *ShootedSeedAPIServer BlockCIDRs []string ShootDefaults *gardenv1beta1.ShootNetworks Backup *gardenv1beta1.BackupProfile }
func ReadShootedSeed ¶
func ReadShootedSeed(shoot *gardenv1beta1.Shoot) (*ShootedSeed, error)
ReadShootedSeed determines whether the Shoot has been marked to be registered automatically as a Seed cluster.
type ShootedSeedAPIServer ¶
type ShootedSeedAPIServer struct { Replicas *int32 Autoscaler *ShootedSeedAPIServerAutoscaler }