k8s命令自动补全

centos7上:

yum install -y epel-release bash-completion
source /usr/share/bash-completion/bash_completion
source <(kubectl completion bash)
echo "source <(kubectl completion bash)" >> ~/.bashrc

MAC上:

brew install bash-completion
source $(brew --prefix)/etc/bash_completion
source <(kubectl completion bash)

 

版权声明:
作者:allenjol
链接:https://www.ayunw.cn/archives/480
来源:爱生活,爱运维
文章版权归作者所有,未经允许请勿转载。

THE END
分享
二维码
< <上一篇
下一篇>>