Kubernetes/部署文档/Kubectl工具安装/Kubectl安装命令自动补全工具.md
offends 7a2f41e7d6
All checks were successful
continuous-integration/drone Build is passing
synchronization
2024-08-07 18:54:39 +08:00

447 B

本文作者:丁辉

Kubectl安装命令自动补全工具

官方文档

安装 bash-completion

  • Ubuntu

    apt-get install bash-completion
    
  • Centos

    yum install bash-completion
    

启动 kubectl 自动补全功能

echo 'source <(kubectl completion bash)' >>~/.bashrc
source ~/.bashrc