https://github.com/dark0dave/kraft-docker
OCI compliant images for kafka running KRAFT
https://github.com/dark0dave/kraft-docker
Last synced: about 1 year ago
JSON representation
OCI compliant images for kafka running KRAFT
- Host: GitHub
- URL: https://github.com/dark0dave/kraft-docker
- Owner: dark0dave
- License: apache-2.0
- Created: 2023-05-14T15:51:05.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2024-12-04T17:25:37.000Z (over 1 year ago)
- Last Synced: 2025-02-28T15:13:31.293Z (over 1 year ago)
- Language: Shell
- Size: 240 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://hub.docker.com/r/dark0dave/kafka/)
[](https://hub.docker.com/r/dark0dave/kafka/)

kafka-docker
============
Dockerfile for [Apache Kafka](http://kafka.apache.org/) running kraft. Because I hate zookeeper.
The image is available directly from [Docker Hub](https://hub.docker.com/r/dark0dave/kafka/)
## Usage
```sh
docker build -t kafka .
docker run -it -p 9092:9092 kafka
```
This runs kafka without zookeeper in a single instance mode, topics are created automatically there is no need to create them beforehand.
### Auto create topics
Can create topics at start time with the following:
```sh
docker run -it -e KAFKA_CREATE_TOPICS=topic1:1:1,topic2:1:1 -p 9092:9092 kafka
```
### Logging
Logging can be controlled with, the runtime environment varriable LOG4J_LOGGER_KAFKA.
Log levels available:
Level|Description
----|----
OFF|Turns off logging.
FATAL|Severe errors that cause premature termination.
ERROR|Other runtime errors or unexpected conditions.
WARN|Runtime situations that are undesirable or unexpected, but not necessarily wrong.
INFO|Runtime events of interest at startup and shutdown.
DEBUG|Detailed diagnostic information about events.
TRACE|Detailed diagnostic information about everything.
Example below:
```sh
docker run -it --rm -e LOG4J_LOGGER_KAFKA=DEBUG -p 9092:9092 kafka
```