kubernetes-sigs/kubespray

kubectl_localhost get wrong binary when ansible host arch is different from deployed cluster

オープン

#11,608 opened on 2024/10/07

 (8 件のコメント) (0 件のリアクション) (1 人の担当者)HTML (4,419 件のフォーク)batch import
help wantedkind/bug

Repository metrics

Stars
 (10,380 個のスター)
PR merge metrics
 (平均マージ 25d) (30d で 26 merged PRs)

説明

What happened?

when enable kubectl_localhost and ansible host arch is x86_64 and deploy a kubernetes cluster on aarch64 systems it copy the binary from the host.

binary from aarch64 host is not got for x86_64 ansible host error: kubectl: cannot execute binary file: Exec format error1

https://github.com/kubernetes-sigs/kubespray/blob/master/roles/kubernetes/client/tasks/main.yml#L90

What did you expect to happen?

when kubectl_localhost enable download correct arch binary to the ansible host

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

1x ansible host x86_64 arch 1x controller node aarch64 arch

deploy kubespray with kubectl_localhost

OS

Ubuntu2204

Version of Ansible

2.17.0

Version of Python

3.11

Version of Kubespray (commit)

master

Network plugin used

calico

Full inventory with variables

Command used to invoke ansible

ansible-playbook -i inventory/arm/hosts.yaml cluster.yml

Output of ansible run

Anything else we need to know

No response

コントリビューターガイド