Home > other >  For help, kafka how to add users using the docker hold?
For help, kafka how to add users using the docker hold?

Time:10-19

Beginners docker and kafka, there are many places do not understand, I hope you can teach a lot,

The operating system for centos 7.3
Use mirror for
Wurstmeister/zookeeper
Wurstmeister/kafka: latest
Mount -v configuration file/data/docker_data/kafka/config/:/opt/kafka_2. 12-2.3.0/config/

In the config/modify server. The properties, producer. The properties file, and add kafka_server_jaas under the directory. The conf and kafka_cilent_jaas. Conf.
In the bin/kafka - server - start. Sh add
Export KAFKA_OPTS="- Djava. Security. The auth. Login. Config=/data/docker_data/kafka/config/kafka_server_jaas conf"
In the bin/kafka - the console - producer. Sh add
Export KAFKA_OPTS="- Djava. Security. The auth. Login. Config=/data/docker_data/kafka/config/kafka_client_jaas conf"

The state of kafka into Restarting after restart the container (1) 11 seconds line

An error not to be found/data/docker_data/kafka/config/kafka_client_jaas conf directory
I don't can change several paths
1) within the container/opt/kafka_2. 12-2.3.0/config/
2) outside the container
The/var/lib/docker overlay2/d738de8db0339bc738e762bfbc431ad57aba72fa9178e28b0b36ca90ccb0afce/merged//opt/kafka_2. 12-2.3.0/config/
3)
/data/docker_data kafka/config/
4) refer to kafka - server - start. The export of sh KAFKA_LOG4J_OPTS="- Dlog4j. Configuration=file: $base_dir/../config/log4j properties
"Wrote the export KAFKA_OPTS="- Djava. Security. The auth. Login. Config=file: $base_dir/../config/kafka_server_jaas. Conf "

Seek a solution mentality, first thank you

CodePudding user response:

Has been solved, use is the path of the container,
  • Related