You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/specification.md
+52-2
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,9 @@ The desired state file consists of:
9
9
-**Settings**[Optional]: Specific settings for configuring `kafka-gitops`.
10
10
-**Topics**[Optional]: Topics and topic configuration definitions.
11
11
-**Services**[Optional]: Service definitions for generating ACLs.
12
+
-**Users**[Optional]: User definitions for generating ACLs.
12
13
-**Custom Service ACLs**[Optional]: Definitions for custom, non-generated ACLs.
14
+
-**Custom User ACLs**[Optional]: Definitions for custom, non-generated ACLs.
13
15
14
16
## Settings
15
17
@@ -114,6 +116,31 @@ services:
114
116
115
117
Under the cover, `kafka-gitops` generates ACLs based on these definitions.
116
118
119
+
## Users
120
+
121
+
**Synopsis**: Define the users that will utilize your Kafka cluster. These user definitions allow `kafka-gitops` to generate ACLs for you. Yay!
122
+
123
+
?> **NOTE**: If using Confluent Cloud, users are service accounts that are prefixed with `user-`.
124
+
125
+
```yaml
126
+
users:
127
+
my-user:
128
+
principal: User:my-user
129
+
roles:
130
+
- writer
131
+
- reader
132
+
- operator
133
+
```
134
+
135
+
Currently, three predefined roles exist:
136
+
137
+
- **writer**: access to write to all topics
138
+
- **reader**: access to read all topics using any consumer group
139
+
- **operator**: access to view topics, topic configs, and to read topics and move their offsets
140
+
141
+
Outside of these very simple roles, you can define custom ACLs per-user by using the `customUserAcls` block.
142
+
143
+
117
144
## Custom Service ACLs
118
145
119
146
**Synopsis**: Define custom ACLs for a specific service.
@@ -130,15 +157,38 @@ customServiceAcls:
130
157
type: TOPIC
131
158
pattern: PREFIXED
132
159
host: "*"
133
-
principal:
160
+
principal: User:my-test-service
134
161
operation: READ
135
162
permission: ALLOW
136
163
read-all-service:
137
164
name: service.
138
165
type: TOPIC
139
166
pattern: PREFIXED
140
167
host: "*"
141
-
principal:
168
+
principal: User:my-test-service
169
+
operation: READ
170
+
permission: ALLOW
171
+
```
172
+
173
+
## Custom User ACLs
174
+
175
+
**Synopsis**: Define custom ACLs for a specific user.
176
+
177
+
For example, if a specific user needs to produce to all topics prefixed with `kafka.` and `service.`, you may not want to define them all in your desired state file.
178
+
179
+
If you have a user `my-test-user` defined, you can define custom ACLs as so:
180
+
181
+
```yaml
182
+
customUserAcls:
183
+
my-test-user:
184
+
read-all-kafka:
185
+
name: kafka.
186
+
type: TOPIC
187
+
pattern: PREFIXED
188
+
host: "*"
142
189
operation: READ
143
190
permission: ALLOW
144
191
```
192
+
193
+
?> **NOTE**: The `principal` field can be left out here and it will be inherited from the user definition.
0 commit comments