Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions config/200-channelable-manipulator-clusterrole.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Copyright 2019 The Knative Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# Use this aggregated ClusterRole when you need read and update permissions on "Channelables".
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: channelable-manipulator
aggregationRule:
clusterRoleSelectors:
- matchLabels:
duck.knative.dev/channelable: "true"
rules: [] # Rules are automatically filled in by the controller manager.

13 changes: 0 additions & 13 deletions config/200-controller-clusterrole.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,16 +100,3 @@ rules:
- "get"
- "list"
- "watch"

# Messaging resources and statuses we care about.
- apiGroups:
- "messaging.knative.dev"
resources:
- "inmemorychannels"
- "inmemorychannels/status"
verbs:
- "get"
- "list"
- "watch"
- "update"
- "patch"
15 changes: 15 additions & 0 deletions config/201-clusterrolebinding.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,21 @@ roleRef:

---

apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: eventing-controller-manipulator
subjects:
- kind: ServiceAccount
name: eventing-controller
namespace: knative-eventing
roleRef:
kind: ClusterRole
name: channelable-manipulator
apiGroup: rbac.authorization.k8s.io

---

apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Copyright 2019 The Knative Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: imc-channelable-manipulator
labels:
duck.knative.dev/channelable: "true"
# Do not use this role directly. These rules will be added to the "channelable-manipulator" role.
rules:
- apiGroups:
- messaging.knative.dev
resources:
- inmemorychannels
- inmemorychannels/status
verbs:
- get
- list
- watch
- update
- patch
33 changes: 33 additions & 0 deletions contrib/kafka/config/200-channelable-manipulator-clusterrole.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Copyright 2019 The Knative Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: kafka-channelable-manipulator
labels:
duck.knative.dev/channelable: "true"
# Do not use this role directly. These rules will be added to the "channelable-manipulator" role.
rules:
- apiGroups:
- messaging.knative.dev
resources:
- kafkachannels
- kafkachannels/status
verbs:
- get
- list
- watch
- update
- patch
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: natss-channelable
name: natss-channelable-manipulator
labels:
duck.knative.dev/channelable: "true"
# Do not use this role directly. These rules will be added to the "channelable" role.
# Do not use this role directly. These rules will be added to the "channelable-manipulator" role.
rules:
- apiGroups:
- messaging.knative.dev
Expand Down