kafka-docker icon indicating copy to clipboard operation
kafka-docker copied to clipboard

Update tutorial

Open sscaling opened this issue 6 years ago • 4 comments

Here is a master ticket to track all the required tutorial updates, rather than having multiple tickets open tracking separate bits of information

To update

  • [ ] Identify that KAFKA_ADVERTISED_HOST must be routable from host / bridge network. (https://github.com/wurstmeister/kafka-docker/issues/110)
  • [ ] Link to connectivity guide
  • [ ] Document --from-beginning console parameter (https://github.com/wurstmeister/kafka-docker/issues/219)
  • [ ] Document --bootstrap-server option for new consumers (https://github.com/wurstmeister/kafka-docker/issues/243)
  • [ ] Enumerate difference between docker-machine + docker-for-mac
  • [ ] Highlight cloning the repository first
  • [ ] document any differences in versions for the scale / --scale commands

sscaling avatar Sep 29 '18 08:09 sscaling

Tipp: This command throws 2 errors. --zookeeper is not recognized and --bootstrap-server is missing. $ $KAFKA_HOME/bin/kafka-console-consumer.sh --topic=topic --zookeeper=$ZK

This line works for me:

    $KAFKA_HOME/bin/kafka-console-consumer.sh --bootstrap-server `broker-list.sh` --topic topic --from-beginning

LazerJesus avatar Nov 29 '18 12:11 LazerJesus

For security, do not mount the /var/run/docker.sock configuration file into the container.

https://github.com/wurstmeister/kafka-docker/issues/403#issuecomment-448555550

https://www.lvh.io/posts/dont-expose-the-docker-socket-not-even-to-a-container.html

barrer avatar Dec 19 '18 11:12 barrer

Now that markdown -> site generation has been fixed by https://github.com/wurstmeister/kafka-docker/pull/454, these updates should be possible.

sscaling avatar Jan 26 '19 20:01 sscaling

Follow up on https://github.com/wurstmeister/kafka-docker/issues/110 for MacOS.

Until you explicitly add --net kafka-docker_default to the start-kafka-shell.sh script, the internal docker DNS resolution for host zookeeper won't work, so further examples about producer/consumer cannot be run.

The correct script should look like this:

#!/bin/bash
docker run --rm -v /var/run/docker.sock:/var/run/docker.sock --net kafka-docker_default -e HOST_IP=$1 -e ZK=$2 -i -t wurstmeister/kafka /bin/bash

dzmitry-kankalovich avatar Feb 09 '19 18:02 dzmitry-kankalovich