Add vpa-system: VPA CRDs + recommender (advise mode) #281
Reference in New Issue
Block a user
Delete Branch "benvin/vpa"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Why
Rolls out the Vertical Pod Autoscaler control plane so the estate can gather right-sizing recommendations for every workload (advise mode, follow-up PR adds the per-workload VPA objects). Deploys the recommender only: advise mode never mutates pods, so the updater and admission-controller (and its mutating webhook) are intentionally omitted — fewer moving parts, no webhook in the admission path.
Changes
apps/base/vpa-system/: namespace, VPA CRDs (verticalpodautoscalers + verticalpodautoscalercheckpoints) pulled from the kubernetes/autoscaler repo at the pinned tag (same upstream-raw pattern node-feature-discovery uses), recommender-scoped RBAC (SA + metrics-reader/actor/status-actor/checkpoint-actor/target-reader), and the recommender Deployment.apps/overlays/au-syd1/vpa-system/referencing the base.apps/overlays/*/vpa-systemin the platform ApplicationSet.Notes
registry.k8s.io/autoscaling/vpa-recommender:1.7.0image.*-systemnamespace destination plus CustomResourceDefinition/ClusterRole/ClusterRoleBinding are already whitelisted.Merge gate
autoscaling/vpa-pattern to the k8s-registry docker remote) to land first so the recommender image is served through the cache.@@ -0,0 +8,4 @@# directly from the kubernetes/autoscaler repo at the pinned release tag, the# same upstream-raw pattern node-feature-discovery uses for its CRDs. Keeps the# CRDs from drifting away from the recommender image version below.- https://raw.githubusercontent.com/kubernetes/autoscaler/vertical-pod-autoscaler-1.7.0/vertical-pod-autoscaler/deploy/vpa-v1-crd-gen.yamlthis should come from artifactapi
@@ -0,0 +25,4 @@runAsUser: 65534containers:- name: recommenderimage: registry.k8s.io/autoscaling/vpa-recommender:1.7.0confirm we are redirecting this to artifactapi in the rancher config in puppet
Both review comments addressed:
CRDs now come from artifactapi: the
githubgeneric remote already proxies/raw/paths, so terraform-artifactapi#14 allowlists the pinned autoscaler CRD file and this branch now fetches it at/api/v1/remote/github/kubernetes/autoscaler/raw/vertical-pod-autoscaler-1.7.0/.... Merge #14 (auto-applies) before this PR so the kustomize fetch resolves.Image redirect confirmed:
puppet-prod hieradata/roles/infra/k8s.yamlrke2::registriesmirrorsregistry.k8s.io->artifactapi.k8s.syd1.au.unkin.netwith rewritek8s-registry/$1anddisable-default-registry-endpoint: true, and terraform-artifactapi#13 (merged) allowlistedautoscaling/vpa-in the k8s-registry remote — so the recommender image pull is cache-served by artifactapi on every node.CRDs split out per review: #284 now carries the VPA CRDs plus generated kubeconform schemas (schemas/autoscaling.k8s.io/, both kinds, v1 + v1beta2, produced with the same transform as ci/generate-schemas.sh). This PR is now recommender-only.
New merge order: #284 (CRDs+schemas) -> this PR (#281, recommender) -> #283 (per-workload VPAs). A sample updateMode Off VPA validates against the new schemas with kubeconform.
368ecf1e33to5d30d42735