Last active
December 11, 2018 17:42
-
-
Save mohammadobaid1/3c91de74fa14f3b2bf0546c3e9ed9b7f to your computer and use it in GitHub Desktop.
kafka.yaml
This file contains hidden or 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' | |
| services: | |
| kafka1st: | |
| image: hyperledger/fabric-kafka | |
| restart: always | |
| networks: | |
| - fabric | |
| environment: | |
| - KAFKA_MESSAGE_MAX_BYTES=103809024 | |
| - KAFKA_MAX_REQUEST_SIZE=104857600 | |
| - KAFKA_REPLICA_FETCH_MAX_BYTES=103809024 | |
| - KAFKA_UNCLEAN_LEADER_ELECTION_ENABLE=true | |
| - KAFKA_BROKER_ID=1 | |
| - KAFKA_MIN_INSYNC_REPLICAS=1 | |
| - KAFKA_DEFAULT_REPLICATION_FACTOR=1 | |
| - KAFKA_ZOOKEEPER_CONNECT=node_zookeeper1st:2181,node_zookeeper2nd:2181,node_zookeeper3rd:2181 | |
| deploy: | |
| placement: | |
| constraints: [node.hostname == your-swarm-hostname-of-node] | |
| depends_on: | |
| - node_zookeeper1st | |
| - node_zookeeper2nd | |
| - node_zookeeper3rd | |
| ports: | |
| - 9092:9092 | |
| - 9093:9093 | |
| zookeeper1st: | |
| image: hyperledger/fabric-zookeeper | |
| restart: always | |
| networks: | |
| - fabric | |
| environment: | |
| - ZOO_MY_ID=1 | |
| - ZOO_SERVERS=server.1=0.0.0.0:2888:3888 server.2=zookeeper2nd:2888:3888 server.3=zookeeper3rd:2888:3888 | |
| - ZOO_TICK_TIME=2000 | |
| - ZOO_INIT_LIMIT=10 | |
| - ZOO_SYNC_LIMIT=5 | |
| deploy: | |
| placement: | |
| constraints: [node.hostname == your-swarm-hostname-of-node] | |
| ports: | |
| - 2181:2181 | |
| zookeeper2nd: | |
| image: hyperledger/fabric-zookeeper | |
| restart: always | |
| networks: | |
| - fabric | |
| environment: | |
| - ZOO_MY_ID=2 | |
| - ZOO_SERVERS=server.1=zookeeper1st:2888:3888 server.2=0.0.0.0:2888:3888 server.3=_zookeeper3rd:2888:3888 | |
| - ZOO_TICK_TIME=2000 | |
| - ZOO_INIT_LIMIT=10 | |
| - ZOO_SYNC_LIMIT=5 | |
| deploy: | |
| placement: | |
| constraints: [node.hostname == your-swarm-hostname-of-node] | |
| ports: | |
| - 12181:2181 | |
| zookeeper3rd: | |
| image: hyperledger/fabric-zookeeper | |
| restart: always | |
| networks: | |
| - fabric | |
| environment: | |
| - ZOO_MY_ID=3 | |
| - ZOO_SERVERS=server.1=zookeeper1st:2888:3888 server.2=zookeeper2nd:2888:3888 server.3=0.0.0.0:2888:3888 | |
| - ZOO_TICK_TIME=2000 | |
| - ZOO_INIT_LIMIT=10 | |
| - ZOO_SYNC_LIMIT=5 | |
| deploy: | |
| placement: | |
| constraints: [node.hostname == your-swarm-hostname-of-node] | |
| ports: | |
| - 22181:2181 | |
| networks: | |
| fabric: | |
| external: true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment