Last active
March 15, 2023 18:32
-
-
Save adeshpandey/874feb5aa0e00dc1741e3cf2b064141b to your computer and use it in GitHub Desktop.
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.7" | |
services: | |
zookeeper: | |
image: confluentinc/cp-zookeeper:6.2.1 | |
environment: | |
ZOOKEEPER_CLIENT_PORT: 2181 | |
ZOOKEEPER_TICK_TIME: 2000 | |
ports: | |
- "22181:2181" | |
kafka: | |
image: confluentinc/cp-kafka:6.2.1 | |
container_name: kafka | |
depends_on: | |
- zookeeper | |
ports: | |
- "9092:${KAFKA_PORT}" | |
environment: | |
KAFKA_BROKER_ID: 1 | |
KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181 | |
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://${KAFKA_IP}:${KAFKA_PORT} | |
KAFKA_INTER_BROKER_LISTENER_NAME: PLAINTEXT | |
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1 | |
kafdrop: | |
image: obsidiandynamics/kafdrop:latest | |
depends_on: | |
- kafka | |
ports: | |
- "9000:9000" | |
environment: | |
SERVER_SERVLET_CONTEXTPATH: / | |
KAFKA_BROKERCONNECT: ${KAFKA_IP}:${KAFKA_PORT} | |
JVM_OPTS: "-Xms32M -Xmx64M" | |
filebeat: | |
image: docker.elastic.co/beats/filebeat:8.5.3 | |
depends_on: | |
- kafka | |
- zookeeper | |
- kafdrop | |
environment: | |
ELASTICSEARCH_HOSTS: kafka:9200 | |
ELASTICSEARCH_USERNAME: elastic | |
ELASTICSEARCH_PASSWORD: adesh123 | |
KAFKA_BROKERS: ${KAFKA_IP}:${KAFKA_PORT} | |
volumes: | |
- "./app.log:/app.log" | |
- "./filebeat.yml:/usr/share/filebeat/filebeat.yml:ro" | |
- "./my-script.js:/usr/share/filebeat/my-script.js" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment