|
1 |
| -# dockerfiles |
| 1 | +# Kafka docker builds |
| 2 | + |
| 3 | +Automated [Kafka](http://kafka.apache.org/) builds for [solsson/kafka](https://hub.docker.com/r/solsson/kafka/) |
| 4 | +and related `kafka-` images under https://hub.docker.com/u/solsson/. |
2 | 5 |
|
3 |
| -Nowadays we're using separate repositories for dockerization projects. |
| 6 | +--- |
| 7 | + |
| 8 | +This repo used to contain misc dockerfiles, but they've moved to separate repositories for dockerization projects. |
| 9 | +We've kept the repository name to avoid breaking the automated build of solsson/kafka in Docker Hub. |
4 | 10 |
|
5 | 11 | For legacy Dockerfiles from this repo (if you navigated to here from a Docker Hub [solsson](https://hub.docker.com/u/solsson/) image),
|
6 | 12 | see https://github.com/solsson/dockerfiles/tree/misc-dockerfiles.
|
7 | 13 |
|
8 |
| -# Kafka docker builds |
| 14 | +--- |
9 | 15 |
|
10 |
| -This repository maintains automated [Kafka](http://kafka.apache.org/) builds for https://hub.docker.com/r/solsson/kafka/ |
11 |
| -and related `kafka-` images under https://hub.docker.com/u/solsson/. |
| 16 | +Our kafka images are tested in production with https://github.com/Yolean/kubernetes-kafka/. |
12 | 17 |
|
13 |
| -These images are tested in production with https://github.com/Yolean/kubernetes-kafka/. |
| 18 | +You most likely need to mount your own config files, or for `./bin/kafka-server-start.sh` use overrides like: |
| 19 | +``` |
| 20 | + --override zookeeper.connect=zookeeper:2181 |
| 21 | + --override log.dirs=/var/lib/kafka/data/topics |
| 22 | + --override log.retention.hours=-1 |
| 23 | + --override broker.id=0 |
| 24 | + --override advertised.listener=PLAINTEXT://kafka-0:9092 |
| 25 | +``` |
14 | 26 |
|
15 | 27 | ## One image to rule them all
|
16 | 28 |
|
17 | 29 | Official [Kafka distributions](http://kafka.apache.org/downloads) contain startup scripts and config for various services and clients. Thus `./kafka` produces a multi-purpose image for direct use and specialized docker builds.
|
18 | 30 |
|
| 31 | +We could build specialized images like `kafka-server` but we have two reasons not to: |
| 32 | + * Won't be as transparent in Docker Hub because you can't use Automated Build without scripting. |
| 33 | + * In reality you'll need to control your own config anyway. |
| 34 | + |
19 | 35 | ### Example of downstream image: Kafka Connect
|
20 | 36 |
|
21 | 37 | See ./connect-jmx
|
|
28 | 44 |
|
29 | 45 | Rudimentary compliance with kubernetes-kafka is tested using a [build-contract](https://github.com/Yolean/build-contract/).
|
30 | 46 |
|
31 |
| -Build and test using: `docker run -v /var/run/docker.sock:/var/run/docker.sock -v $(pwd)/:/source solsson/build-contract test` |
32 |
| - |
33 |
| -To keep kafka running for local use, uncomment `ports` 9092 and run: `docker-compose -f build-contracts/docker-compose.yml up --force-recreate`. |
34 |
| - |
35 |
| -While timing issues remain, start services individually... |
| 47 | +Build and test using: `docker run -v /var/run/docker.sock:/var/run/docker.sock -v $(pwd)/:/source solsson/build-contract test`. However... while timing issues remain you need some manual intervention: |
36 | 48 |
|
37 | 49 | ```bash
|
38 | 50 | compose='docker-compose -f build-contracts/docker-compose.yml'
|
|
0 commit comments