docker-compose-files/hyperledger/0.6/pbft/4-peers-with-explorer.yml

77 lines
1.6 KiB
YAML
Raw Normal View History

# This compose file will start a cluster with 4 hyperledger peer nodes
# vp0: validating node as root
# vp1: validating node as peer
# vp2: validating node as peer
# vp3: validating node as peer
# https://github.com/yeasy/docker-compose-files
version: '2'
services:
# blockchain-explorer
explorer:
2016-12-08 16:03:52 +08:00
extends:
file: explorer.yml
service: explorer
hostname: explorer
environment:
- HYP_REST_ENDPOINT=http://vp0:7050
ports:
- "9090:9090"
# validating node as the root
2016-12-08 16:03:52 +08:00
# vp0 will also be used for client interactive operations
# If you want to run fabric command on the host, then map 7051:7051 to host
# port, or use like `CORE_PEER_ADDRESS=172.17.0.2:7051` to specify peer addr.
vp0:
extends:
2016-12-08 16:03:52 +08:00
file: peer.yml
service: vp
hostname: vp0
environment:
- CORE_PEER_ID=vp0
ports:
- "7050:7050"
2016-12-08 16:03:52 +08:00
- "7051:7051"
# validating node
vp1:
extends:
2016-12-08 16:03:52 +08:00
file: peer.yml
service: vp
hostname: vp1
environment:
- CORE_PEER_ID=vp1
- CORE_PEER_DISCOVERY_ROOTNODE=vp0:7051
links:
- vp0
# validating node
vp2:
extends:
2016-12-08 16:03:52 +08:00
file: peer.yml
service: vp
hostname: vp2
environment:
- CORE_PEER_ID=vp2
- CORE_PEER_DISCOVERY_ROOTNODE=vp0:7051
links:
- vp0
# validating node
vp3:
extends:
2016-12-08 16:03:52 +08:00
file: peer.yml
service: vp
hostname: vp3
environment:
- CORE_PEER_ID=vp3
- CORE_PEER_DISCOVERY_ROOTNODE=vp0:7051
links:
- vp0
#networks:
# default:
# external:
# name: fabric_pbft