Kubernetes Pods 的 csshX 替代品是什么?

What is the alternative of csshX for Kubernetes Pods?

我使用 kubectl exec -it 登录到单个 Kubernetes pod。

有什么方法可以通过一个命令同时登录到集群中的多个 pods(就像 csshX)?

有一个插件可以帮助您解决这个问题。它被称为 kubectl-tmux-exec:

A kubectl plugin that controls multiple pods simultaneously using Tmux.

It is to kubectl exec as csshX or pssh is to ssh.

Instead of exec bash into multiple pod's containers one-at-a-time, like kubectl exec pod{N} /bin/bash.

You can now use

kubectl tmux-exec -l app=nginx /bin/bash

有关 Installation and Usage 的所有必要详细信息都可以在链接文档中找到。