goldilocks

by Fairwinds

Helm chartv11.3.1App v4.16.3Verified publisher

A Helm chart for running Fairwinds Goldilocks. See https://github.com/FairwindsOps/goldilocks

About this chart

Intro

This is a Helm chart for the Fairwinds Goldilocks project. It provides an easy way to install the controller and the dashboard for viewing resource recommendations in your Kubernetes cluster. Please see the Goldilocks README for more information.

Installation

helm repo add fairwinds-stable https://charts.fairwinds.com/stable
helm install goldilocks fairwinds-stable/goldilocks --namespace goldilocks

Requirements

This has a hard requirement on VPA being installed. Please see the Goldilocks README

vpa subchart

Fairwinds has published a chart for installing VPA in our stable repo. It can be enabled as a sub-chart by setting vpa.enabled==true. We recommend just installing the chart and managing it separately.

Major Version Upgrade Notes

Upgrading from v9.x.x to v10.x.x

The only breaking change is to move the metrics-server sub-chart from bitnami to kubernetes-sigs. Generally we provide the sub-chart only as a convenience for testing. In production environments, metrics-server is a critical cluster component that should be managed separately. However in an abundance of caution, we are doing a major release to indicate this change.

Upgrading from v6.x.x to v7.x.x

In this change, the VPA helm chart was upgraded to the latest version, including a major bump. We recommend you to check the VPA Helm chart changelog to ensure a smooth upgrade.

BREAKING Upgrading from v4.x.x to v5.x.x

The new chart version includes Ingress configuration for the networking.k8s.io/v1 Kubernetes API.

Because of the new API version, you need to specify dashboard.ingress.hosts[X].paths[Y].type when installing this chart with enabled Ingress on a Kubernetes cluster version 1.19+.

Upgrading from v3.x.x to v4.x.x

There are no breaking changes, but the goldilocks controller and dashboard have had some major tweaks so they can work with more workload controllers. To allow v4.0.0+ to work with more than Deployments, the main change here is in RBAC permissions so that the goldilocks service accounts can access all resources in the apps/v1.

BREAKING Upgrading from v2.x.x to v3.x.x

In this change, the installVPA value and corresponding hooks have been removed in favor of the sub-chart. The recommended path forward is to remove the hook-installed resources and manage the VPA installation with the Fairwinds VPA Chart

We have kept the uninstallVPA flag in place, which will remove a vpa installation that was previously managed by this chart. This flag will be deprecated in a later release.

BREAKING Upgrading to chart v2.x.x from v1.x.x

If using installVPA=true when updating from v1.x.x to v2.x.x of this chart, there are some considerations. v2.x.x of the chart started only installing the recommender and the necessary CRDs and RBAC from the VPA installation. This is due to the volatile and risky nature of running a beta mutatingadmissionwebhook in your cluster. If you have previously used the installVPA=true flag to install the VPA, we recommend that you completely uninstall and re-install the VPA as part of the upgrade. We have provided a new hook to do this that will run before the install hook.

If upgrading from v1.x.x to v2.x.x we recommend upgrading like so:

helm upgrade goldilocks fairwinds-stable/goldilocks --set reinstallVPA=true

This will completely remove the VPA and then re-install it using the new method.

Values

KeyTypeDefaultDescription
uninstallVPAboolfalseEnabling this flag will remove a vpa installation that was previously managed with this chart. It is considered deprecated and will be removed in a later release.
vpa.enabledboolfalseIf true, the vpa will be installed as a sub-chart
vpa.updater.enabledboolfalse
metrics-server.enabledboolfalseIf true, the metrics-server will be installed as a sub-chart
metrics-server.apiService.createbooltrue
image.repositorystring"us-docker.pkg.dev/fairwinds-ops/oss/goldilocks"Repository for the goldilocks image
image.tagstring"v4.16.4"The goldilocks image tag to use
image.pullPolicystring"Always"imagePullPolicy - Highly recommended to leave this as Always
imagePullSecretslist[]A list of image pull secret names to use
nameOverridestring""
fullnameOverridestring""
controller.enabledbooltrueWhether or not to install the controller deployment
controller.revisionHistoryLimitint10Number of old replicasets to retain, default is 10, 0 will garbage-collect old replicasets
controller.rbac.createbooltrueIf set to true, rbac resources will be created for the controller
controller.rbac.enableArgoprojbooltrueIf set to true, the clusterrole will give access to argoproj.io resources
controller.rbac.extraRuleslist[]Extra rbac rules for the controller clusterrole
controller.rbac.extraClusterRoleBindingslist[]A list of ClusterRoles for which ClusterRoleBindings will be created for the ServiceAccount, if enabled
controller.serviceAccount.createbooltrueIf true, a service account will be created for the controller. If set to false, you must set controller.serviceAccount.name
controller.serviceAccount.namestringnilThe name of an existing service account to use for the controller. Combined with controller.serviceAccount.create
controller.flagsobject{}A map of additional flags to pass to the controller. For monitoring all namespaces out of the box, add the following flag "on-by-default: true"
controller.logVerbositystring"2"Controller log verbosity. Can be set from 1-10 with 10 being extremely verbose
controller.nodeSelectorobject{}Node selector for the controller pod
controller.tolerationslist[]Tolerations for the controller pod
controller.affinityobject{}Affinity for the controller pods
controller.topologySpreadConstraintslist[]Topology spread constraints for the controller pods
controller.resourcesobject{"limits":{},"requests":{"cpu":"25m","memory":"256Mi"}}The resources block for the controller pods
controller.podSecurityContextobject{"seccompProfile":{"type":"RuntimeDefault"}}Defines the podSecurityContext for the controller pod
controller.securityContextobject{"allowPrivilegeEscalation":false,"capabilities":{"drop":["ALL"]},"readOnlyRootFilesystem":true,"runAsNonRoot":true,"runAsUser":10324}The container securityContext for the controller container
controller.deployment.extraVolumeMountslist[]Extra volume mounts for the controller container
controller.deployment.extraVolumeslist[]Extra volumes for the controller pod
controller.deployment.annotationsobject{}Extra annotations for the controller deployment
controller.deployment.additionalLabelsobject{}Extra labels for the controller deployment
controller.deployment.podAnnotationsobject{}Extra annotations for the controller pod
dashboard.basePathstringnilPath on which the dashboard is served. Defaults to /
dashboard.enabledbooltrueIf true, the dashboard component will be installed
dashboard.revisionHistoryLimitint10Number of old replicasets to retain, default is 10, 0 will garbage-collect old replicasets
dashboard.replicaCountint2Number of dashboard pods to run
dashboard.service.typestring"ClusterIP"The type of the dashboard service
dashboard.service.portint80The port to run the dashboard service on
dashboard.service.annotationsobject{}Extra annotations for the dashboard service
dashboard.flagsobject{}A map of additional flags to pass to the dashboard. For monitoring all namespaces out of the box, add the following flag "on-by-default: true".
dashboard.logVerbositystring"2"Dashboard log verbosity. Can be set from 1-10 with 10 being extremely verbose
dashboard.excludeContainersstring"linkerd-proxy,istio-proxy"Container names to exclude from displaying in the Goldilocks dashboard
dashboard.rbac.createbooltrueIf set to true, rbac resources will be created for the dashboard
dashboard.rbac.enableArgoprojbooltrueIf set to true, the clusterrole will give access to argoproj.io resources
dashboard.rbac.extraRuleslist[]
dashboard.rbac.extraClusterRoleBindingslist[]
dashboard.serviceAccount.createbooltrueIf true, a service account will be created for the dashboard. If set to false, you must set dashboard.serviceAccount.name
dashboard.serviceAccount.namestringnilThe name of an existing service account to use for the controller. Combined with dashboard.serviceAccount.create
dashboard.deployment.annotationsobject{}Extra annotations for the dashboard deployment
dashboard.deployment.additionalLabelsobject{}Extra labels for the dashboard deployment
dashboard.deployment.extraVolumeMountslist[]Extra volume mounts for the dashboard container
dashboard.deployment.extraVolumeslist[]Extra volumes for the dashboard pod
dashboard.deployment.podAnnotationsobject{}Extra annotations for the dashboard pod
dashboard.ingress.enabledboolfalseEnables an ingress object for the dashboard.
dashboard.ingress.ingressClassNamestringnilFrom Kubernetes 1.18+ this field is supported in case your ingress controller supports it. When set, you do not need to add the ingress class as annotation.
dashboard.ingress.annotationsobject{}
dashboard.ingress.hosts[0].hoststring"chart-example.local"
dashboard.ingress.hosts[0].paths[0].pathstring"/"
dashboard.ingress.hosts[0].paths[0].typestring"ImplementationSpecific"
dashboard.ingress.tlslist[]
dashboard.healthCheckPolicy.enabledboolfalseEnables a GKE HealthCheckPolicy for the dashboard service. Only applicable when using GKE Gateway API (httpRoute.enabled: true). Required because the dashboard returns 301 on /, which GKE LB treats as unhealthy.
dashboard.healthCheckPolicy.requestPathstring"/health"The path the GKE load balancer health check will use
dashboard.httpRoute.enabledboolfalseEnables an HTTPRoute object for the dashboard (Gateway API).
dashboard.httpRoute.annotationsobject{}Extra annotations for the HTTPRoute
dashboard.httpRoute.labelsobject{}Extra labels for the HTTPRoute
dashboard.httpRoute.parentRefslist[]Parent references for the HTTPRoute (required when enabled)
dashboard.httpRoute.hostnameslist[]Hostnames for the HTTPRoute
dashboard.httpRoute.matcheslist[{"path":{"type":"PathPrefix","value":"/"}}]Matching rules for the HTTPRoute
dashboard.resourcesobject{"limits":{},"requests":{"cpu":"25m","memory":"256Mi"}}A resources block for the dashboard.
dashboard.podSecurityContextobject{"seccompProfile":{"type":"RuntimeDefault"}}Defines the podSecurityContext for the dashboard pod
dashboard.securityContextobject{"allowPrivilegeEscalation":false,"capabilities":{"drop":["ALL"]},"readOnlyRootFilesystem":true,"runAsNonRoot":true,"runAsUser":10324}The container securityContext for the dashboard container
dashboard.nodeSelectorobject{}
dashboard.tolerationslist[]
dashboard.affinityobject{}
dashboard.topologySpreadConstraintslist[]Topology spread constraints for the dashboard pods

Deploy goldilocks with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has goldilocks on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartgoldilocks is pinned at v11.3.1 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply