美文网首页
Kubernetes:16.kubectl explain

Kubernetes:16.kubectl explain

作者: 小六的昵称已被使用 | 来源:发表于2019-08-13 10:15 被阅读0次

    语法

    [14:58:26 root@ceshi-01 ~ $]kubectl explain --help
    List the fields for supported resources
    列出支持的资源的字段
    
     This command describes the fields associated with each supported API resource. Fields are identified via a simple JSONPath identifier:
     此命令描述与每个受支持的API资源关联的字段。 字段通过简单的JSONPath标识符标识:
    
      <type>.<fieldName>[.<fieldName>]
    
     Add the --recursive flag to display all of the fields at once without descriptions. Information about each field is retrieved from the server in OpenAPI format.
     添加--recursive标志一次显示所有字段而不进行描述。 以OpenAPI格式从服务器检索有关每个字段的信息。
    
    Use "kubectl api-resources" for a complete list of supported resources.
    使用“kubectl api-resources”获取支持资源的完整列表。
    
    示例:
      # Get the documentation of the resource and its fields
      # 获取资源及其字段的文档
      kubectl explain pods
    
      # Get the documentation of a specific field of a resource
      # 获取资源特定字段的文档
      kubectl explain pods.spec.containers
    
    选项:
          --api-version='': Get different explanations for particular API version
                            获取特定API版本的不同解释
          --recursive=false: Print the fields of fields (Currently only 1 level deep)
                             打印字段(目前只有1级深)
    
    用法:
      kubectl explain RESOURCE [options]
    
    Use "kubectl options" for a list of global command-line options (applies to all commands).

    相关文章

      网友评论

          本文标题:Kubernetes:16.kubectl explain

          本文链接:https://www.haomeiwen.com/subject/gxsujctx.html