Reputation:
I ran this command to run Kafka and Zookeeper in a docker machine:
Create the docker machine:
docker-machine create --driver virtualbox default
Make the machine active:
eval $(docker-machine env default)
Does this command below run Kafka and Zookeeper in the docker machine I created above?
docker run -d --name kafka -p 2181:2181 -p 9092:9092 --env ADVERTISED_HOST=docker-machine ip \
docker-machine active`` --env ADVERTISED_PORT=9092 rahulagrawal/kafka
I want to know how I can connect to the Kafka broker running in docker-machine ip
which is 192.168.99.100
.
Upvotes: 0
Views: 1062
Reputation: 51738
Does this command below run Kafka and Zookeeper in the docker machine I created above?
Yes the container is running inside the docker-machine you created.
I want to know how I can connect to the Kafka broker running in docker-machine ip which is 192.168.99.100
The kafka broker can be reached using 192.168.99.100:9092
Upvotes: 2