容器编排技术 -- Kubernetes kubectl create clusterrolebinding 命令详解

  • 1 kubectl create clusterrolebinding
  • 2 语法
  • 3 示例
  • 4 Flags

kubectl create clusterrolebinding

为特定的ClusterRole创建ClusterRoleBinding。

语法

$ clusterrolebinding NAME --clusterrole=NAME [--user=username] [--group=groupname] [--serviceaccount=namespace:serviceaccountname] [--dry-run]

示例

在集群范围将cluster-admin ClusterRole授予用户user1,user2和group1。

kubectl create clusterrolebinding cluster-admin --clusterrole=cluster-admin --user=user1 --user=user2 --group=group1

Flags

Name Shorthand Default Usage
allow-missing-template-keys   true If true, ignore any errors in templates when a field or map key is missing in the template. Only applies to golang and jsonpath output formats.
clusterrole     ClusterRole this ClusterRoleBinding should reference
dry-run   false If true, only print the object that would be sent, without sending it.
generator   clusterrolebinding.rbac.authorization.k8s.io/v1alpha1 The name of the API generator to use.
group   [] groups to bind to the role
no-headers   false When using the default or custom-column output format, don't print headers (default print headers).
output o   Output format. One of: json|yaml|wide|name|custom-columns=...|custom-columns-file=...|go-template=...|go-template-file=...|jsonpath=...|jsonpath-file=... See custom columns [http://kubernetes.io/docs/user-guide/kubectl-overview/#custom-columns], golang template [http://golang.org/pkg/text/template/#pkg-overview] and jsonpath template [http://kubernetes.io/docs/user-guide/jsonpath].
output-version     DEPRECATED: To use a specific API version, fully-qualify the resource, version, and group (for example: 'jobs.v1.batch/myjob').
save-config   false If true, the configuration of current object will be saved in its annotation. Otherwise, the annotation will be unchanged. This flag is useful when you want to perform kubectl apply on this object in the future.
schema-cache-dir   ~/.kube/schema If non-empty, load/store cached API schemas in this directory, default is '$HOME/.kube/schema'
serviceaccount   [] service accounts to bind to the role, in the format :
show-all a false When printing, show all resources (default hide terminated pods.)
show-labels   false When printing, show all labels as the last column (default hide labels column)
sort-by     If non-empty, sort list types using this field specification. The field specification is expressed as a JSONPath expression (e.g. '{.metadata.name}'). The field in the API resource specified by this JSONPath expression must be an integer or a string.
template     Template string or path to template file to use when -o=go-template, -o=go-template-file. The template format is golang templates [http://golang.org/pkg/text/template/#pkg-overview].
user   [] usernames to bind to the role
validate   true If true, use a schema to validate the input before sending it

测试:http://erp.brc-beei.com:8082/cwbase/web/session/GSIDP/GSYS/WEB/GSYTABMODList.aspx?bizObjectId=GSIDP1001&bizOPId=GSIDP100110#

容器编排技术 -- Kubernetes kubectl create clusterrolebinding 命令详解相关推荐

  1. 容器编排技术 -- Kubernetes kubectl create secret 命令详解

    容器编排技术 -- Kubernetes kubectl create secret 命令详解 1 kubectl create secret 2 语法 3 参考: kubectl create se ...

  2. 容器编排技术 -- Kubernetes kubectl create serviceaccount 命令详解

    容器编排技术 -- Kubernetes kubectl create serviceaccount 命令详解 1 kubectl create serviceaccount 2 语法 3 示例 4  ...

  3. 容器编排技术 -- Kubernetes kubectl create service 命令详解

    容器编排技术 -- Kubernetes kubectl create service 命令详解 1 kubectl create service 2 语法 3 参考 kubectl create s ...

  4. 容器编排技术 -- Kubernetes kubectl create rolebinding 命令详解

    容器编排技术 -- Kubernetes kubectl create rolebinding 命令详解 1 kubectl create rolebinding 2 语法 3 示例 4 Flags ...

  5. 容器编排技术 -- Kubernetes kubectl create role 命令详解

    容器编排技术 -- Kubernetes kubectl create role 命令详解 1 kubectl create role 2 语法 3 示例 4 Flags kubectl create ...

  6. 容器编排技术 -- Kubernetes kubectl create quota 命令详解

    容器编排技术 -- Kubernetes kubectl create quota 命令详解 1 kubectl create quota 2 语法 3 示例 4 Flags kubectl crea ...

  7. 容器编排技术 -- Kubernetes kubectl create poddisruptionbudget 命令详解

    容器编排技术 -- Kubernetes kubectl create poddisruptionbudget 命令详解 1 kubectl create poddisruptionbudget 2  ...

  8. 容器编排技术 -- Kubernetes kubectl create namespace 命令详解

    容器编排技术 -- Kubernetes kubectl create namespace 命令详解 1 kubectl create namespace 2 语法 3 示例 4 Flags kube ...

  9. 容器编排技术 -- Kubernetes kubectl create deployment 命令详解

    容器编排技术 -- Kubernetes kubectl create deployment 命令详解 1 kubectl create deployment 2 语法 3 示例 4 Flags ku ...

最新文章

  1. C#中小数点后保留两位小数,四舍五入的函数及使用方法
  2. VS code配置docker的shell环境
  3. switch..case使用
  4. MySQL高级 - 锁 - InnoDB行锁 - 争用情况查看
  5. 基于注解风格的Spring-MVC的拦截器
  6. boot druid 长时间不连接 异常_Spring Boot学习:如何使用Druid数据源
  7. pyqt界面屏幕分辨率自适应_在Qt5和PyQt5中设置支持高分辨率屏幕自适应的方法
  8. 手机端判断触摸滑动方向
  9. JavaScript学习之初识JS
  10. 普元EOS之性能调优
  11. Axure RP从入门到精通(一)原型设计工具简介
  12. django -- 过滤器
  13. ROS(indigo) 安装和使用更新版本的Gazebo----3,4,5,6,7 附:中国机器人大赛中型组仿真比赛说明
  14. 安卓实现图片缩放平移的基本步骤
  15. The Annotated Transformer(解读Transformer)
  16. 分享一个android手机开不了机的问题
  17. 2020-12-2 IDEA2020.2 提示Typo:In word ‘XXXX’ 解决方法
  18. [STM32]DAC全解分析
  19. Pytorch安装教程 及 解决 torch.cuda.is_available() 返回 False 的问题
  20. springboot毕设项目“果然是你”水果直销平台vkfo8(java+VUE+Mybatis+Maven+Mysql)

热门文章

  1. Jumpline提供的免费3月的VDS空间,空间容量为20GB, 图文介绍
  2. Magento 1.9.X 系列教程
  3. Note: HTML5 识别语音相关的一些资源
  4. html5拖拽图片批量ajax无刷新进度上传
  5. Linux 技巧: 从命令行创建像素标尺
  6. Java面试题一:字符串的字符分类器
  7. 深度学习(参数选择)
  8. python多任务笔记
  9. 【转载】python几种经典排序方法的实现
  10. 【AI视野·今日NLP 自然语言处理论文速览 第十期】Fri, 18 Jun 2021