/cfkafka

CloudFlare SSL with Confluent Kafka in Docker Compose

Primary LanguageShellApache License 2.0Apache-2.0

Kafka SSL With CloudFlare SSL

This repo provides scripts to generate PKI infrastructure for Kafka with CFSSL, and then run Kafka in Docker Compose with these certificates. There are three brokers, and one user certificate.

Generate the certificates:

./generate.sh

Bring the cluster up:

docker-compose up

Produce and consume:

docker-compose exec kafka-1 kafka-console-producer  --broker-list localhost:19092 --topic ssl-topic --producer.config /etc/kafka/secrets/ssl.config
docker-compose exec kafka-1 kafka-console-consumer  --bootstrap-server localhost:19092 --topic ssl-topic --consumer.config /etc/kafka/secrets/ssl.config

Take the cluster down:

docker-compose down -v

Remove all the certificates:

./clean.sh