Skip to content

Commit

Permalink
NodeTopologyResource ClusterRole and ClusterRoleBinding
Browse files Browse the repository at this point in the history
 - Required to access NodeResourceTopology CRD instances
 - Update minor formatting issues

Signed-off-by: Swati Sehgal <swsehgal@redhat.com>
Signed-off-by: Alexey Perevalov <alexey.perevalov@huawei.com>
  • Loading branch information
swatisehgal authored and AlexeyPerevalov committed Nov 7, 2020
1 parent cc9c3a1 commit eb19c1f
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,41 @@ One CRD instance contains information of available resources of the appropriate

### Integration into Node Feature Discovery

In order to allow the NFD-master Daemon to create, get, update, delete NodeResourceTopology CRD instances, ClusterRole and ClusterRoleBinding would have to be configured as below:

``` yaml
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: noderesourcetopology-handler
rules:
- apiGroups: ["topology.node.k8s.io"]
resources: ["noderesourcetopologies"]
verbs: ["*"]
- apiGroups: ["rbac.authorization.k8s.io"]
resources: ["*"]
verbs: ["*"]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: handle-noderesourcetopology
subjects:
- kind: ServiceAccount
name: noderesourcetopology-account
namespace: default
roleRef:
kind: ClusterRole
name: noderesourcetopology-handler
apiGroup: rbac.authorization.k8s.io
---
apiVersion: v1
kind: ServiceAccount
metadata:
name: noderesourcetopology-account
```
`serviceAccountName: noderesourcetopology-account` would have to be added to the manifest file of the Daemon.

### Graduation Criteria

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,12 @@ participating-sigs:
reviewers:
- "@dchen1107"
- "@derekwaynecarr"
- "@klueska"
approvers:
- "@dchen1107"
- "@derekwaynecarr"
creation-date: 2020-06-19
last-updated: 2020-06-19
last-updated: 2020-08-12
status: implementable
see-also:
- "/keps/sig-scheduling/2044-simplified-topology-manager/README.md"
Expand Down

0 comments on commit eb19c1f

Please sign in to comment.