Documentation ¶
Index ¶
- Variables
- func AddAnnotation(obj metav1.Object, key string, value string)
- func AddLabel(obj metav1.Object, key string, value string)
- func Contains(slice []string, s string) bool
- func GetResourceRequirements(name string) corev1.ResourceRequirements
- func MapItems(source []string, transform func(string) string) []string
- func Remove(slice []string, s string) (result []string)
- func RemoveLabel(obj metav1.Object, key string)
Constants ¶
This section is empty.
Variables ¶
View Source
var ResourceRequirements = map[string]corev1.ResourceRequirements{ "noobaa-core": { Requests: corev1.ResourceList{ corev1.ResourceCPU: resource.MustParse("1"), corev1.ResourceMemory: resource.MustParse("4Gi"), }, Limits: corev1.ResourceList{ corev1.ResourceCPU: resource.MustParse("1"), corev1.ResourceMemory: resource.MustParse("4Gi"), }, }, "noobaa-db": { Requests: corev1.ResourceList{ corev1.ResourceCPU: resource.MustParse("500m"), corev1.ResourceMemory: resource.MustParse("4Gi"), }, Limits: corev1.ResourceList{ corev1.ResourceCPU: resource.MustParse("500m"), corev1.ResourceMemory: resource.MustParse("4Gi"), }, }, "noobaa-db-vol": { Requests: corev1.ResourceList{ corev1.ResourceStorage: resource.MustParse("50Gi"), }, }, "noobaa-endpoint": { Requests: corev1.ResourceList{ corev1.ResourceCPU: resource.MustParse("1"), corev1.ResourceMemory: resource.MustParse("2Gi"), }, Limits: corev1.ResourceList{ corev1.ResourceCPU: resource.MustParse("1"), corev1.ResourceMemory: resource.MustParse("2Gi"), }, }, "prometheus": { Requests: corev1.ResourceList{ "cpu": resource.MustParse("500m"), "memory": resource.MustParse("250Mi"), }, Limits: corev1.ResourceList{ "cpu": resource.MustParse("500m"), "memory": resource.MustParse("250Mi"), }, }, "alertmanager": { Requests: corev1.ResourceList{ "cpu": resource.MustParse("200m"), "memory": resource.MustParse("200Mi"), }, Limits: corev1.ResourceList{ "cpu": resource.MustParse("200m"), "memory": resource.MustParse("200Mi"), }, }, "kube-rbac-proxy": { Limits: corev1.ResourceList{ "memory": resource.MustParse("30Mi"), "cpu": resource.MustParse("50m"), }, Requests: corev1.ResourceList{ "memory": resource.MustParse("30Mi"), "cpu": resource.MustParse("50m"), }, }, }
ResourceRequirements DaemonResources map contains the default resource requirements for the various MCG daemons.
Functions ¶
func GetResourceRequirements ¶
func GetResourceRequirements(name string) corev1.ResourceRequirements
GetResourceRequirements returns a custom ResourceRequirements for the passed name, if found in the passed resource map. If not, it returns the default value for the given name.
func RemoveLabel ¶
RemoveLabel removes a label from the resource metadata.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.