I am running single node zookeeper docker image using below command
docker run -it -p 2181:2181 --name zookeeper zookeeper
.
Inorder to run kafka docker image, I need to share the IP address of the zookeper docker image as ENV variable and update kafka server.properties file.
Using docker inspect, I am able to fetch the IP address of zookeeper image and pass it during docker run
of kafka.
But is there any way to automatically detect and share the IP address between docker containers.
I could see some example using --link, but in the latest docker documentation it seems deprecated.
Appreciate any suggestion/help
Thanks