Last active
May 16, 2018 10:45
-
-
Save hongkongkiwi/f6d897d314535f5ac5ddca295719207a to your computer and use it in GitHub Desktop.
Zookeeper+Kafka+Kafka-Rest-Proxy+Kafka-Topic-UI
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.5' | |
services: | |
zookeeper: | |
image: zookeeper:3.4.9 | |
hostname: zookeeper | |
ports: | |
- "2181:2181" | |
environment: | |
ZOO_MY_ID: 1 | |
ZOO_PORT: 2181 | |
ZOO_SERVERS: server.1=zookeeper:2888:3888 | |
volumes: | |
- ./zk-single-kafka-single/zookeeper/data:/data | |
- ./zk-single-kafka-single/zookeeper/datalog:/datalog | |
kafka: | |
image: confluentinc/cp-kafka:4.1.0 | |
hostname: kafka | |
ports: | |
- "9092:9092" | |
environment: | |
# add the entry "127.0.0.1 kafka" to your /etc/hosts file | |
KAFKA_ADVERTISED_LISTENERS: "PLAINTEXT://kafka:9092" | |
KAFKA_ZOOKEEPER_CONNECT: "zookeeper:2181" | |
KAFKA_BROKER_ID: 1 | |
KAFKA_LOG4J_LOGGERS: "kafka.controller=INFO,kafka.producer.async.DefaultEventHandler=INFO,state.change.logger=INFO" | |
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1 | |
volumes: | |
- ./zk-single-kafka-single/kafka/data:/var/lib/kafka/data | |
depends_on: | |
- zookeeper | |
kafka-rest-proxy: | |
image: confluentinc/cp-kafka-rest:4.1.0 | |
hostname: kafka-rest-proxy | |
ports: | |
- "8084:8084" | |
environment: | |
KAFKA_REST_ZOOKEEPER_CONNECT: zookeeper:2181 | |
KAFKA_REST_LISTENERS: http://0.0.0.0:8084/ | |
KAFKA_REST_HOST_NAME: kafka-rest-proxy | |
KAFKA_REST_BOOTSTRAP_SERVERS: kafka:9092 | |
depends_on: | |
- zookeeper | |
- kafka | |
kafka-topic-ui: | |
image: landoop/kafka-topics-ui | |
ports: | |
- "8000:8000" | |
environment: | |
KAFKA_REST_PROXY_URL: http://kafka-rest-proxy:8084 | |
MAX_BYTES: 50000 | |
RECORD_POLL_TIMEOUT: 2000 | |
DEBUG_LOGS_ENABLED: "true" | |
PROXY: "true" | |
PORT: 8000 | |
PROXY_SKIP_VERIFY: "true" | |
depends_on: | |
- kafka-rest-proxy |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment