-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Add dns-autoscaler ConfigMap template (#12789) #12811
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: hadi2f244 The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Hi @hadi2f244. Thanks for your PR. I'm waiting for a github.com member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR makes DNS autoscaler configuration explicit and manageable by introducing a dedicated ConfigMap template. Instead of relying solely on the autoscaler's internal defaults (passed via --default-params), Kubespray now renders and manages a ConfigMap resource that contains the autoscaling parameters, ensuring consistent and reproducible behavior across clusters.
Key Changes:
- Added a new ConfigMap template for DNS autoscaler configuration
- Updated the manifest list to include the new ConfigMap template in the deployment sequence
- The ConfigMap uses the same configuration parameters already defined in Kubespray defaults
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
roles/kubernetes-apps/ansible/vars/main.yml |
Adds dns-autoscaler-configmap.yml.j2 to the list of DNS autoscaler manifests that are deployed |
roles/kubernetes-apps/ansible/templates/dns-autoscaler-configmap.yml.j2 |
New ConfigMap template that explicitly defines DNS autoscaler configuration using existing Kubespray variables (preventSinglePointFailure, coresPerReplica, nodesPerReplica, min replicas) |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
/ok-to-test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| - dns-autoscaler.yml.j2 | ||
| - dns-autoscaler-configmap.yml.j2 |
Copilot
AI
Jan 3, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The ConfigMap should be created before the Deployment that references it. The dns-autoscaler deployment references this ConfigMap via the --configmap flag, but the ConfigMap is listed after the deployment in the manifest list. This could cause the deployment to fail or behave unexpectedly if it starts before the ConfigMap is created. Move dns-autoscaler-configmap.yml.j2 to line 4, before dns-autoscaler.yml.j2.
| - dns-autoscaler.yml.j2 | |
| - dns-autoscaler-configmap.yml.j2 | |
| - dns-autoscaler-configmap.yml.j2 | |
| - dns-autoscaler.yml.j2 |
What type of PR is this?
What this PR does / why we need it:
This PR makes DNS autoscaler configuration explicit by rendering and applying a managed ConfigMap from Kubespray. It removes reliance on the autoscaler’s internal fallback defaults, ensuring consistent, predictable, and reproducible DNS autoscaling behavior across clusters.
Which issue(s) this PR fixes:
Fixes #12789
Special notes for your reviewer:
Does this PR introduce a user-facing change?:
Yes. Kubespray now explicitly renders and manages the DNS autoscaler ConfigMap instead of relying on the autoscaler’s internal default configuration. While the default values remain unchanged, the resulting cluster resources and configuration ownership are now user-visible and fully managed by Kubespray.