Skip to content

Kubespray' s Cilium upgrade fails #12252

Open
@prennig86

Description

@prennig86

What happened?

Cilium upgrade fails during kubespray cluster upgrade

Root cause
1: kubespray in cluster upgrade will always put on kube-proxy, that causes failure on Cilium upgrade
2: A pre installed Cilium (done by a previous version of kubespray) is not upgradable by helm due to missing helm annotations and labels

What did you expect to happen?

upgrade-cluster.yml will not fail if cilium is the default network

How can we reproduce it (as minimally and precisely as possible)?

Install by the previous version of kubespray (v2.27.0) a cluster with cilium instead of calico. Upgrade it with kubespray v2.28.0

OS

Ubuntu 22

Version of Ansible

9.13.0

Version of Python

3.10.12

Version of Kubespray (commit)

2.28.0

Network plugin used

cilium

Full inventory with variables

Command used to invoke ansible

Output of ansible run

Error: Unable to install Cilium: Unable to continue with install: ServiceAccount "cilium" in namespace "kube-system" exists and cannot be imported into the current release: invalid ownership metadata; label validation error: missing key "app.kubernetes.io/managed-by": must be set to "Helm"; annotation validation error: missing key "meta.helm.sh/release-name": must be set to "cilium"; annotation validation error: missing key "meta.helm.sh/release-namespace": must be set to "kube-system"
ℹ️ Using Cilium version 1.17.3
🔮 Auto-detected kube-proxy has been installed

Anything else we need to know

I see that kubeadm is always adding kube-proxy in upgrade-cluster.yml phase even if "addon/kube-proxy" is correctly added into "kubeadm_init_phases_skip_default" variable.

Metadata

Metadata

Assignees

Labels

Ubuntu 22kind/bugCategorizes issue or PR as related to a bug.triage/acceptedIndicates an issue or PR is ready to be actively worked on.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions