Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
mwn-san authored Nov 3, 2024
1 parent f58c11d commit 7c23614
Showing 1 changed file with 49 additions and 13 deletions.
62 changes: 49 additions & 13 deletions environment/ACLs/README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,46 @@
### HOW TO CHECK SASL/SCRAM USERS KAFKA ON ZOOKEEPER SHELL
# Getting Started
```
docker-compose up -d ZK731
```
```
sh add_sasl-scram_user_kafka_zookeeper.sh
```
```
docker-compose up -d BK731
```
```
docker-compose up -d SR731 C3731
```

docker exec -ti <ontainer-name> /bin/bash
### Ensure the service port for each module is active using the command below:

zookeeper-shell localhost:2181
| Service | Ports |
|:-----------------|:---------------------------|
| zookeeper | 2181, 2182, 2888, 3888 |
| broker | 9092, 9093, 9094 |
| schema registry | 8081, 8082 |
| control center | 9021, 9022 |

ls /config/users
```
netstat -plnt | grep <port>
```

### HOW TO DELETE SASL/SCRAM USERS
### How to check SASL/SCRAM users Kafka on Zookeeper shell.
```
docker exec -ti <ontainer-name> /bin/bash
```
```
zookeeper-shell localhost:2181
```
```
ls /config/users
```
### How to delete SASL/SCRAM users.
```
deleteall /config/users/name_of_user

### HOW TO ADD ACLS OPERATION (RESOURCES : TOPIC - GROUP)
```
### How to add ACLs operation (resources: topic - group).
```
kafka-acls --bootstrap-server <host>:<port> \
--command-config /etc/kafka/helper/adminclient-configs.conf \
--add \
Expand All @@ -19,18 +50,20 @@ kafka-acls --bootstrap-server <host>:<port> \
--operation Describe \
--operation Write \
--topic finance-syariah

```
```
kafka-acls --bootstrap-server <host>:<port> \
--command-config /etc/kafka/helper/adminclient-configs.conf \
--add \
--allow-principal User:streaming \
--operation Read \
--operation Describe \
--topic finance-syariah \
--group finance-syariah-group

### HOW TO DELETE ACLS OPERATION
--group finance-syariah-group
```

### How to delete ACLs operation.
```
kafka-acls --bootstrap-server <host>:<port> \
--command-config /etc/kafka/helper/adminclient-configs.conf \
--remove \
Expand All @@ -41,7 +74,8 @@ kafka-acls --bootstrap-server <host>:<port> \
--operation WRITE \
--topic finance-syariah \
--force

```
```
kafka-acls --bootstrap-server <host>:<port> \
--command-config /etc/kafka/helper/adminclient-configs.conf \
--remove
Expand All @@ -52,11 +86,13 @@ kafka-acls --bootstrap-server <host>:<port> \
--operation WRITE \
--topic finance-syariah
--allow-host 10.10.10.6

```
```
kafka-acls --bootstrap-server <host>:<port> \
--command-config /etc/kafka/helper/adminclient-configs.conf \
--remove
--allow-principal User:digital \
--group finance-syariah-group \
--operation READ \
--operation DESCRIBE
```

0 comments on commit 7c23614

Please sign in to comment.