Official Helm Chart version
1.19.0 (latest released)
Apache Airflow version
3.1
Kubernetes Version
1.35
Helm Chart configuration
apiServer:
replicas: 1
hpa:
enabled: true
minReplicaCount: 1
maxReplicaCount: 5
metrics:
- type: Resource
resource:
name: cpu
target:
type: Utilization
averageUtilization: 80
Docker Image customizations
None — using the official image.
What happened
When apiServer.hpa.enabled: true, the Deployment manifest still contains spec.replicas: 1.
HPA modifies this field at runtime to scale the api-server. GitOps tooling continuously detects
a diff between the desired state in Git (replicas: 1) and the live cluster state (replicas
managed by HPA), causing a permanent out-of-sync condition that cannot be resolved without
disabling HPA or ignoring the field via a custom diff strategy.
What you think should happen instead
When HPA is enabled, spec.replicas should be omitted from the Deployment entirely.
This allows HPA to be the sole owner of the replica count and eliminates the spurious diff.
How to reproduce
- Deploy the chart with
apiServer.hpa.enabled: true and apiServer.replicas: 1 (defaults).
- Observe the live Deployment — HPA immediately takes ownership and mutates
spec.replicas.
- Any GitOps reconciliation loop will report a permanent diff on
spec.replicas.
Set apiServer.replicas: ~ in values.yaml as a workaround — the field is then omitted
from the rendered Deployment and HPA can manage replicas without conflict.
Anything else
The same pattern (kindIs "invalid" guard on spec.replicas) is the standard fix used by
other Helm charts to support HPA without GitOps drift.
Are you willing to submit PR?
Code of Conduct
Official Helm Chart version
1.19.0 (latest released)
Apache Airflow version
3.1
Kubernetes Version
1.35
Helm Chart configuration
Docker Image customizations
None — using the official image.
What happened
When
apiServer.hpa.enabled: true, the Deployment manifest still containsspec.replicas: 1.HPA modifies this field at runtime to scale the api-server. GitOps tooling continuously detects
a diff between the desired state in Git (
replicas: 1) and the live cluster state (replicasmanaged by HPA), causing a permanent out-of-sync condition that cannot be resolved without
disabling HPA or ignoring the field via a custom diff strategy.
What you think should happen instead
When HPA is enabled,
spec.replicasshould be omitted from the Deployment entirely.This allows HPA to be the sole owner of the replica count and eliminates the spurious diff.
How to reproduce
apiServer.hpa.enabled: trueandapiServer.replicas: 1(defaults).spec.replicas.spec.replicas.Set
apiServer.replicas: ~invalues.yamlas a workaround — the field is then omittedfrom the rendered Deployment and HPA can manage replicas without conflict.
Anything else
The same pattern (
kindIs "invalid"guard onspec.replicas) is the standard fix used byother Helm charts to support HPA without GitOps drift.
Are you willing to submit PR?
Code of Conduct