9 lines
193 B
Bash
Executable file
9 lines
193 B
Bash
Executable file
#!/bin/bash
|
|
cfg=.kubeconfig
|
|
|
|
path=$(pwd)
|
|
while [[ "$path" != "" && ! -e "$path/$cfg" ]]; do
|
|
path=${path%/*}
|
|
done
|
|
|
|
exec env KUBECONFIG="$path/$cfg:$KUBECONFIG:$HOME/.kube/config" kubectl "$@"
|