Description
What happened?
kubespray tries to upgrade/deploy coredns whereas I have it completely disabled.
What did you expect to happen?
Do not try to upgrade coredns if we disable it
How can we reproduce it (as minimally and precisely as possible)?
Deploy a cluster with coredns disabled (dns_mode: manual) and try to upgrade it later.
OS
Flatcar Container Linux
Version of Ansible
ansible [core 2.18.6]
config file = None
configured module search path = ['/home/ldelannoy/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /usr/lib/python3.13/site-packages/ansible
ansible collection location = /home/ldelannoy/.ansible/collections:/usr/share/ansible/collections
executable location = /usr/lib/python-exec/python3.13/ansible
python version = 3.13.3 (main, Jun 6 2025, 19:58:36) [GCC 14.3.0] (/usr/bin/python3.13)
jinja version = 3.1.6
libyaml = True
Version of Python
Python 3.13.3
Version of Kubespray (commit)
v2.28.0
Network plugin used
calico
Full inventory with variables
Command used to invoke ansible
ansible-playbook -i contrib/terraform/terraform.py -i inventory/common/hosts.yml -i inventory/cluster-sandbox/hosts.yml -e cluster_unique_identifier=cluster-sandbox -e ansible_ssh_private_key_file=/builds/infrastructure.tmp/SSH_PRIVATE_KEY -e '{"ansible_interpreter_python_fallback":["/opt/bin/pypy3/bin/python"]}' -e vlan_id=42 --limit= upgrade-cluster.yml --become --timeout=1200 --forks=5 -v --skip-tags=multus
Output of ansible run
TASK [kubernetes/control-plane : Kubeadm | Upgrade first control plane node] ***
fatal: [cluster-sandbox-master-001]: FAILED! => {"changed": true, "cmd": ["timeout", "-k", "600s", "600s", "/opt/bin/kubeadm", "upgrade", "apply", "-y", "v1.32.5", "--skip-phases=addon/coredns", "--config=/etc/kubernetes/kubeadm-config.yaml"], "delta": "0:00:00.190375", "end": "2025-06-24 06:33:17.901523", "failed_when_result": true, "msg": "non-zero return code", "rc": 1, "start": "2025-06-24 06:33:17.711148", "stderr": "W0624 06:33:17.764057 462349 upgradeconfiguration.go:44] [config] WARNING: YAML document with GroupVersionKind kubeproxy.config.k8s.io/v1alpha1, Kind=KubeProxyConfiguration is deprecated for upgrade, please use config file with kind of UpgradeConfiguration instead \nW0624 06:33:17.764102 462349 upgradeconfiguration.go:44] [config] WARNING: YAML document with GroupVersionKind kubelet.config.k8s.io/v1beta1, Kind=KubeletConfiguration is deprecated for upgrade, please use config file with kind of UpgradeConfiguration instead \nW0624 06:33:17.764106 462349 upgradeconfiguration.go:44] [config] WARNING: YAML document with GroupVersionKind kubeadm.k8s.io/v1beta4, Kind=InitConfiguration is deprecated for upgrade, please use config file with kind of UpgradeConfiguration instead \nW0624 06:33:17.764109 462349 upgradeconfiguration.go:44] [config] WARNING: YAML document with GroupVersionKind kubeadm.k8s.io/v1beta4, Kind=ClusterConfiguration is deprecated for upgrade, please use config file with kind of UpgradeConfiguration instead \nW0624 06:33:17.877127 462349 utils.go:69] The recommended value for "clusterDNS" in "KubeletConfiguration" is: [10.240.0.10]; the provided value is: [169.254.25.10]\nerror execution phase preflight: [preflight] Some fatal errors occurred:\n\t[ERROR CoreDNSUnsupportedPlugins]: start version '' not supported\n\t[ERROR CoreDNSMigration]: CoreDNS will not be upgraded: start version '' not supported\n[preflight] If you know what you are doing, you can make a check non-fatal with --ignore-preflight-errors=...
\nTo see the stack trace of this error execute with --v=5 or higher", "stderr_lines": ["W0624 06:33:17.764057 462349 upgradeconfiguration.go:44] [config] WARNING: YAML document with GroupVersionKind kubeproxy.config.k8s.io/v1alpha1, Kind=KubeProxyConfiguration is deprecated for upgrade, please use config file with kind of UpgradeConfiguration instead ", "W0624 06:33:17.764102 462349 upgradeconfiguration.go:44] [config] WARNING: YAML document with GroupVersionKind kubelet.config.k8s.io/v1beta1, Kind=KubeletConfiguration is deprecated for upgrade, please use config file with kind of UpgradeConfiguration instead ", "W0624 06:33:17.764106 462349 upgradeconfiguration.go:44] [config] WARNING: YAML document with GroupVersionKind kubeadm.k8s.io/v1beta4, Kind=InitConfiguration is deprecated for upgrade, please use config file with kind of UpgradeConfiguration instead ", "W0624 06:33:17.764109 462349 upgradeconfiguration.go:44] [config] WARNING: YAML document with GroupVersionKind kubeadm.k8s.io/v1beta4, Kind=ClusterConfiguration is deprecated for upgrade, please use config file with kind of UpgradeConfiguration instead ", "W0624 06:33:17.877127 462349 utils.go:69] The recommended value for "clusterDNS" in "KubeletConfiguration" is: [10.240.0.10]; the provided value is: [169.254.25.10]", "error execution phase preflight: [preflight] Some fatal errors occurred:", "\t[ERROR CoreDNSUnsupportedPlugins]: start version '' not supported", "\t[ERROR CoreDNSMigration]: CoreDNS will not be upgraded: start version '' not supported", "[preflight] If you know what you are doing, you can make a check non-fatal with --ignore-preflight-errors=...
", "To see the stack trace of this error execute with --v=5 or higher"], "stdout": "[upgrade] Reading configuration from the "kubeadm-config" ConfigMap in namespace "kube-system"...\n[upgrade] Use 'kubeadm init phase upload-config --config your-config.yaml' to re-upload it.\n[upgrade/preflight] Running preflight checks", "stdout_lines": ["[upgrade] Reading configuration from the "kubeadm-config" ConfigMap in namespace "kube-system"...", "[upgrade] Use 'kubeadm init phase upload-config --config your-config.yaml' to re-upload it.", "[upgrade/preflight] Running preflight checks"]}
Anything else we need to know
No response