ClickHouse/docker/test/integration/runner/compose/docker_compose_kafka.yml

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

85 lines
3.2 KiB
YAML
Raw Normal View History

version: '2.3'
services:
# kafka_zookeeper:
# image: zookeeper:3.4.9
# hostname: kafka_zookeeper
# environment:
# ZOO_MY_ID: 1
# ZOO_PORT: 2181
# ZOO_SERVERS: server.1=kafka_zookeeper:2888:3888
# security_opt:
# - label:disable
kafka_zookeeper:
image: confluentinc/cp-zookeeper
ports:
- 2181:2181
environment:
ZOOKEEPER_CLIENT_PORT: 2181
# security_opt:
# - label:disable
kafka1:
image: confluentinc/cp-kafka
hostname: kafka1
ports:
- ${KAFKA_EXTERNAL_PORT}:${KAFKA_EXTERNAL_PORT}
environment:
KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: PLAINTEXT:PLAINTEXT, PLAINTEXT_HOST:PLAINTEXT
# KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: INSIDE:PLAINTEXT,OUTSIDE:PLAINTEXT
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://kafka1:19092, PLAINTEXT_HOST://localhost:${KAFKA_EXTERNAL_PORT}
KAFKA_ADVERTISED_HOST_NAME: kafka1
# KAFKA_LISTENERS: INSIDE://0.0.0.0:${KAFKA_EXTERNAL_PORT},OUTSIDE://0.0.0.0:19092
KAFKA_INTER_BROKER_LISTENER_NAME: PLAINTEXT
# KAFKA_BROKER_ID: 1
KAFKA_ZOOKEEPER_CONNECT: kafka_zookeeper:2181
# KAFKA_LOG4J_LOGGERS: "kafka.controller=INFO,kafka.producer.async.DefaultEventHandler=INFO,state.change.logger=INFO"
2021-02-20 18:59:45 +00:00
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1
depends_on:
2021-02-20 18:59:45 +00:00
- kafka_zookeeper
# security_opt:
# - label:disable
2020-02-03 00:02:19 +00:00
schema-registry:
image: confluentinc/cp-schema-registry:5.2.0
hostname: schema-registry
ports:
- ${SCHEMA_REGISTRY_EXTERNAL_PORT}:${SCHEMA_REGISTRY_EXTERNAL_PORT}
2020-02-03 00:02:19 +00:00
environment:
2021-02-20 18:59:45 +00:00
SCHEMA_REGISTRY_HOST_NAME: schema-registry
# SCHEMA_REGISTRY_KAFKASTORE_SECURITY_PROTOCOL: PLAINTEXT
2021-02-20 18:59:45 +00:00
SCHEMA_REGISTRY_KAFKASTORE_BOOTSTRAP_SERVERS: PLAINTEXT://kafka1:19092
SCHEMA_REGISTRY_KAFKASTORE_CONNECTION_URL: kafka_zookeeper:2181
SCHEMA_REGISTRY_LISTENERS: http://0.0.0.0:${SCHEMA_REGISTRY_EXTERNAL_PORT:-12313}
depends_on:
- kafka_zookeeper
- kafka1
# security_opt:
# - label:disable
schema-registry-auth:
image: confluentinc/cp-schema-registry:5.2.0
hostname: schema-registry-auth
ports:
- ${SCHEMA_REGISTRY_AUTH_EXTERNAL_PORT}:${SCHEMA_REGISTRY_AUTH_EXTERNAL_PORT}
environment:
# SCHEMA_REGISTRY_EXTERNAL_PORT: ${SCHEMA_REGISTRY_AUTH_EXTERNAL_PORT}
SCHEMA_REGISTRY_HOST_NAME: schema-registry-auth
SCHEMA_REGISTRY_LISTENERS: http://0.0.0.0:${SCHEMA_REGISTRY_AUTH_EXTERNAL_PORT}
# SCHEMA_REGISTRY_KAFKASTORE_SECURITY_PROTOCOL: PLAINTEXT
SCHEMA_REGISTRY_KAFKASTORE_BOOTSTRAP_SERVERS: PLAINTEXT://kafka1:19092
SCHEMA_REGISTRY_KAFKASTORE_CONNECTION_URL: kafka_zookeeper:2181
2023-04-29 21:23:55 +00:00
SCHEMA_REGISTRY_AUTHENTICATION_METHOD: BASIC
SCHEMA_REGISTRY_AUTHENTICATION_ROLES: user
2023-04-29 21:23:55 +00:00
SCHEMA_REGISTRY_AUTHENTICATION_REALM: RealmFooBar
SCHEMA_REGISTRY_OPTS: "-Djava.security.auth.login.config=/etc/schema-registry/secrets/schema_registry_jaas.conf"
# SCHEMA_REGISTRY_GROUP_ID: auth
SCHEMA_REGISTRY_ZK_NAMESPACE: schema_registry_auth
SCHEMA_REGISTRY_KAFKASTORE_TOPIC: _schemas2
2023-04-29 21:23:55 +00:00
volumes:
- ${SCHEMA_REGISTRY_DIR:-}/secrets:/etc/schema-registry/secrets
2020-02-03 00:02:19 +00:00
depends_on:
2021-02-20 18:59:45 +00:00
- kafka_zookeeper
- kafka1
2020-02-03 00:02:19 +00:00
security_opt:
2021-02-20 18:59:45 +00:00
- label:disable