k8s: add script to do something on all nodes of the cluster
This commit is contained in:
parent
920833fa9b
commit
9fec5ad1ed
1 changed files with 9 additions and 0 deletions
9
k8s/pssh-all-nodes.sh
Executable file
9
k8s/pssh-all-nodes.sh
Executable file
|
@ -0,0 +1,9 @@
|
|||
#!/bin/sh
|
||||
|
||||
#set -x
|
||||
|
||||
tmp=$(mktemp)
|
||||
kubectl get node -o name | sed 's,node/,,' > "$tmp"
|
||||
#cat "$tmp"
|
||||
pssh -h "$tmp" -l root -i "$@"
|
||||
rm -f "$tmp"
|
Loading…
Add table
Reference in a new issue