Lightweight Docker image packaging the execution of Kafka 2.0.0 and Zookeeper
docker run -p 2181:2181 -p 9092:9092 --env ADVERTISED_LISTENERS=PLAINTEXT://docker_host:9092 teivah/kafka:2.0.0
Default ports:
- 2181: Zookeeper
- 9092: Kafka
The following Kafka options are configurable by passing an environment variable to the Docker container (--env key=value
):
LOG_RETENTION_HOURS
: log.retention.hoursLISTENERS
: listenersADVERTISED_LISTENERS
: advertised.listenersNUM_PARTITIONS
: num.partitionsLOG_FLUSH_INTERVAL_MESSAGES
: log.flush.interval.messagesLOG_FLUSH_INTERVAL_MS
: log.flush.interval.messagesNUM_IO_THREADS
: num.io.threadsSOCKET_SEND_BUFFER_BYTES
: socket.send.buffer.bytesSOCKET_RECEIVE_BUFFER_BYTES
: socket.receive.buffer.bytesSOCKET_REQUEST_MAX_BYTES
: socket.request.max.bytes