autovpa

by containeroo

Helm chartv0.4.2App v0.0.34Verified publisher

AutoVPA ensures workloads annotated with a profile get a matching VerticalPodAutoscaler.

About this chart

Helm Chart Values for autovpa

This document provides an overview of the configurable values for the autovpa Helm chart. Adjust them in values.yaml when deploying the chart.

Installation

helm repo add containeroo https://charts.containeroo.ch
helm repo update containeroo
helm upgrade --install autovpa containeroo/autovpa

General Configuration

KeyDescriptionDefault Value
image.repositoryThe container image repository.ghcr.io/containeroo/autovpa
image.tagOverrides the default image tag.Chart appVersion
image.pullPolicyThe image pull policy.IfNotPresent
imagePullSecretsSecrets for pulling private images.[]

Pod Configuration

KeyDescriptionDefault Value
replicasNumber of replicas for the deployment.1
sidecarsAdditional containers for the pod.[]
podAnnotationsAnnotations for the pod.{}
podLabelsLabels for the pod.{}
nodeSelectorNode selector for pod placement.{}
tolerationsTolerations for pod scheduling.[]
affinityAffinity rules for pod placement.{}
terminationGracePeriodSecondsPod termination grace period.10

Watch Scope

KeyDescriptionDefault Value
watch.currentNamespaceWatch only the Helm release namespace.false
watch.namespacesNamespaces to watch; one Role and RoleBinding is created in each.[]

When either namespace-scoped option is configured, the chart omits the controller ClusterRole and ClusterRoleBinding and creates namespace-scoped controller RBAC. The metrics authentication RBAC remains independently controlled by metrics.rbac.create because Kubernetes authentication reviews are cluster-scoped.


Profile & annotations

KeyDescriptionDefault Value
profile.pathPath to the profiles file in the container./etc/autovpa/config.yaml
profile.annotationWorkload annotation used to select a profile.autovpa.containeroo.ch/profile
profile.managedLabelLabel applied to managed VPAs.autovpa.containeroo.ch/managed
profile.nameTemplateTemplate for VPA names.{{ .WorkloadName }}-{{ .Profile }}-vpa
profile.configMap.createCreate and mount a profile ConfigMap.true
profile.configMap.nameExisting/custom profile ConfigMap name.""
profile.configMap.keyKey containing the profile configuration.config.yaml
profile.defaultProfileName of the default profile.default
profile.profilesProfile definitions written to the ConfigMap.Default profile with Off mode

Probes

KeyDescriptionDefault Value
probes.addressOverride the health and readiness bind address.""
probes.portContainer port used by the named probe port.8081
server.enableHTTP2Enable HTTP/2 for metrics and probe servers.false
startupProbe.enabledEnable startup probe.true
startupProbe.specConfiguration for the startup probe.See default values.
livenessProbe.enabledEnable liveness probe.true
livenessProbe.specConfiguration for the liveness probe.See default values.
readinessProbe.enabledEnable readiness probe.true
readinessProbe.specConfiguration for the readiness probe.See default values.

Security

KeyDescriptionDefault Value
podSecurityContextSecurity context for the pod.{}
securityContextSecurity context for the containers.{}

Resource Configuration

KeyDescriptionDefault Value
resources.limits.cpuCPU limit for the container.100m
resources.limits.memoryMemory limit for the container.200Mi
resources.requests.cpuCPU request for the container.100m
resources.requests.memoryMemory request for the container.200Mi

Metrics Configuration

KeyDescriptionDefault Value
metrics.enabledEnable the metrics endpoint.true
metrics.addressOverride the metrics bind address.""
metrics.portContainer port exposed under the metrics name.8443
metrics.secureServe metrics over HTTPS instead of HTTP.true
metrics.rbac.createCreate HTTPS metrics authentication cluster RBAC.true
metrics.rbac.nameCustom metrics authentication RBAC name.""
metrics.service.enabledCreate the metrics Service.true
metrics.service.typeMetrics Service type.ClusterIP
metrics.service.portsPorts for the metrics Service.See default values.
metrics.serviceMonitor.enabledCreate the ServiceMonitor.true
metrics.serviceMonitor.jobLabelService label used as the Prometheus job.app.kubernetes.io/name
metrics.prometheusRule.enabledEnable Prometheus rules for alerts.true
metrics.prometheusRule.namespaceNamespace for Prometheus rules.monitoring
metrics.prometheusRule.severitySeverity of alerts.critical
metrics.prometheusRule.additionalLabelsAdditional labels for Prometheus rules.{}

The ServiceMonitor scheme follows metrics.secure: https includes the TLS configuration and bearer token used by the controller-runtime authenticated endpoint, while http omits both. When changing the port in metrics.address, set metrics.port to the same port. The default Service targets this named port. Likewise, keep probes.port aligned with a custom probes.address. Metrics authentication RBAC is rendered only when metrics and HTTPS are enabled.


RBAC and Service Account

KeyDescriptionDefault Value
clusterRole.createCreate controller cluster RBAC in cluster-wide mode.true
clusterRole.nameCustom name for the controller ClusterRole.""
clusterRole.extraRulesAdditional RBAC rules for the ClusterRole.[]
role.createExplicitly create namespace-scoped controller RBAC.false
role.nameCustom name for the controller Role.""
role.extraRulesAdditional RBAC rules for the Role.[]
serviceAccount.createCreate a ServiceAccount.true
serviceAccount.annotationsAnnotations for the ServiceAccount.{}
serviceAccount.nameCustom name for the ServiceAccount.""

Leader Election

KeyDescriptionDefault Value
leaderElection.enabledEnable leader election.true

Logging Configuration

KeyDescriptionDefault Value
logging.formatLog encoder (json or console).json
logging.develEnable development logging.false
logging.stacktraceLevelStacktrace level.panic

Environment Variables

KeyDescriptionDefault Value
envEnvironment variables for the pod.[{name: TZ, value: Europe/Zurich}]

Arguments

KeyDescriptionDefault Value
extraArgsExtra arguments for the pod.[]

Extra Configuration

KeyDescriptionDefault Value
extraObjectsExtra Kubernetes objects to deploy.[]

Deploy autovpa with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has autovpa 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 chartautovpa is pinned at v0.4.2 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