In order to have Apache Kafka running locally for development purposes.
Ensure Vagrant is installed on the development machine as described here.
Then, execute the go.sh script from this directory.
- The script downloads and launches a Vagrant box.
- Then copies the setup.sh script to it and executes it.
- In turn, setup.sh downloads and launches Apache Kafka and then creates a topic for Sentinel to send messages to.
- The Virtual Machine exposes zookeeper and kafka ports (2181 and 9092 respectively) on the host running the Virtual Machine.
# install, configure and run kafka
sh go.sh
# ssh into the kafka box
vagrant ssh
# start the message consumer for the k8s topic
sh kafka-console-consumer.sh --bootstrap-server localhost:9092 --topic k8s --from-beginning
[*] The Sentinel icon was made by Freepik from Flaticon and is licensed by Creative Commons BY 3.0