feat(tiller): prometheus_adapter_config builder + HPA-friendly replicas #1
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "claude/tiller-prometheus-adapter-f04fbe35"
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?
Adds two pieces needed for HPA-driven autoscaling on custom Prometheus metrics:
prometheus_adapter_config(name, rules=..., external_rules=..., resource_rules=...)renders aConfigMapin the prometheus-adapter rule schema. Rule dicts pass through verbatim; the builder only handles YAML serialization and ConfigMap wrapping.deployment()andstatefulset()acceptreplicas=Noneto omit thespec.replicasfield. An HPA targeting the Deployment can then own the replica count withoutkubectl applyrewriting it on every reconcile.The first consumer is Flowmetal, which uses both to autoscale Starlark workers and HTTP connectors off custom Prometheus metrics.
Changes are visible to end-users: yes
replicasdefault stays at1Test plan
TestPrometheusAdapterConfig,TestReplicasOmission)