k8s命令之kubectl config中英对照

wlzx059@node01:~$ kubectl config --help
Modify kubeconfig files using subcommands like "kubectl config set current-context my-context"
(使用 “kubectl config set current-context my-context” 这样的子命令修改 kubeconfig 文件)
 The loading order follows these rules(加载顺序遵循以下规则:):
  1.  If the --kubeconfig flag is set, then only that file is loaded. The flag may only be set once and no merging takes
place.(如果设置了 --kubeconfig 标志,则只加载该文件。该标志只能设置一次,并且不会进行合并。)
  2.  If $KUBECONFIG environment variable is set, then it is used as a list of paths (normal path delimiting rules for
your system). These paths are merged. When a value is modified, it is modified in the file that defines the stanza. When
a value is created, it is created in the first file that exists. If no files in the chain exist, then it creates the
last file in the list.(如果设置了$KUBECONFIG环境变量,则将其用作路径列表(系统的正常路径分隔规则)。这些路径将合并。修改值时,
将在定义节的文件中修改该值。创建值时,将在存在的第一个文件中创建该值。如果链中不存在任何文件,则创建列表中的最后一个文件。)
  3.  Otherwise, ${HOME}/.kube/config is used and no merging takes place.(否则,将使用 ${HOME}/.kube/config,并且不会进行合并。)

Available Commands(可用命令):
  current-context   Display the current-context(显示当前上下文)
  delete-cluster    Delete the specified cluster from the kubeconfig(从kubeconfig中删除指定的集群)
  delete-context    Delete the specified context from the kubeconfig(从kubeconfig中删除指定的上下文)
  delete-user       Delete the specified user from the kubeconfig(从kubeconfig中删除指定的用户)
  get-clusters      Display clusters defined in the kubeconfig(显示kubeconfig中定义的集群)
  get-contexts      Describe one or many contexts(显示 kubeconfig 文件中的一个或多个上下文。)
  get-users         Display users defined in the kubeconfig(显示kubeconfig中定义的用户)
  rename-context    Rename a context from the kubeconfig file(从kubeconfig文件中重命名上下文)
  set               Set an individual value in a kubeconfig file(在kubeconfig文件中设置一个单个值)
  set-cluster       Set a cluster entry in kubeconfig(在kubeconfig中设置一个集群条目)
  set-context       Set a context entry in kubeconfig(在kubeconfig中设置一个上下文条目)
  set-credentials   Set a user entry in kubeconfig(设置凭据,在kubeconfig中设置一个用户条目)
  unset             Unset an individual value in a kubeconfig file(取消在kubeconfig文件中设置单个值)
  use-context       Set the current-context in a kubeconfig file(在kubeconfig文件中设置当前上下文)
  view              Display merged kubeconfig settings or a specified kubeconfig file(显示合并的kubeconfig设置或指定的kubeconfig文件)
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值