mirror of
https://github.com/hyperledger/fabric-samples.git
synced 2026-06-17 15:35:09 +00:00
and fix incorrect function name in byfn.sh add *.tx and *.block files to .gitignore add FABRIC_CFG_PATH setting Change-Id: Id3457455354b1f2aea1a9661aa89dc677e05124b Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com> Signed-off-by: Rameshbabu <rameshbabu.thoomu@gmail.com>
89 lines
3.4 KiB
YAML
89 lines
3.4 KiB
YAML
#
|
|
# Copyright IBM Corp All Rights Reserved
|
|
#
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
#
|
|
version: '2'
|
|
|
|
networks:
|
|
basic:
|
|
|
|
services:
|
|
ca.example.com:
|
|
image: hyperledger/fabric-ca:x86_64-1.0.0-beta
|
|
environment:
|
|
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
|
|
- FABRIC_CA_SERVER_CA_NAME=ca.example.com
|
|
ports:
|
|
- "7054:7054"
|
|
command: sh -c 'fabric-ca-server start --ca.certfile /etc/hyperledger/fabric-ca-server-config/org1.example.com-cert.pem --ca.keyfile /etc/hyperledger/fabric-ca-server-config/a22daf356b2aab5792ea53e35f66fccef1d7f1aa2b3a2b92dbfbf96a448ea26a_sk -b admin:adminpw -d'
|
|
volumes:
|
|
- ./crypto-config/peerOrganizations/org1.example.com/ca/:/etc/hyperledger/fabric-ca-server-config
|
|
container_name: ca.example.com
|
|
networks:
|
|
- basic
|
|
|
|
orderer.example.com:
|
|
container_name: orderer.example.com
|
|
image: hyperledger/fabric-orderer:x86_64-1.0.0-beta
|
|
environment:
|
|
- ORDERER_GENERAL_LOGLEVEL=debug
|
|
- ORDERER_GENERAL_LISTENADDRESS=0.0.0.0
|
|
- ORDERER_GENERAL_GENESISMETHOD=file
|
|
- ORDERER_GENERAL_GENESISFILE=/etc/hyperledger/configtx/twoorgs.genesis.block
|
|
- ORDERER_GENERAL_LOCALMSPID=OrdererMSP
|
|
- ORDERER_GENERAL_LOCALMSPDIR=/etc/hyperledger/msp/orderer
|
|
working_dir: /opt/gopath/src/github.com/hyperledger/fabric/orderer
|
|
command: orderer
|
|
ports:
|
|
- 7050:7050
|
|
volumes:
|
|
- ./config/:/etc/hyperledger/configtx
|
|
- ./crypto-config/ordererOrganizations/example.com/orderers/orderer.example.com/:/etc/hyperledger/msp/orderer
|
|
- ./crypto-config/peerOrganizations/org1.example.com/peers/peer0.org1.example.com/:/etc/hyperledger/msp/peerOrg1
|
|
- ./crypto-config/peerOrganizations/org2.example.com/peers/peer0.org2.example.com/:/etc/hyperledger/msp/peerOrg2
|
|
networks:
|
|
- basic
|
|
|
|
peer0.org1.example.com:
|
|
container_name: peer0.org1.example.com
|
|
image: hyperledger/fabric-peer:x86_64-1.0.0-beta
|
|
environment:
|
|
- CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock
|
|
- CORE_PEER_ID=peer0.org1.example.com
|
|
- CORE_LOGGING_PEER=debug
|
|
- CORE_CHAINCODE_LOGGING_LEVEL=DEBUG
|
|
- CORE_PEER_LOCALMSPID=Org1MSP
|
|
- CORE_PEER_MSPCONFIGPATH=/etc/hyperledger/msp/peer/
|
|
- CORE_PEER_ADDRESS=peer0.org1.example.com:7051
|
|
# # the following setting starts chaincode containers on the same
|
|
# # bridge network as the peers
|
|
# # https://docs.docker.com/compose/networking/
|
|
- CORE_VM_DOCKER_HOSTCONFIG_NETWORKMODE=${COMPOSE_PROJECT_NAME}_basic
|
|
- CORE_LEDGER_STATE_STATEDATABASE=CouchDB
|
|
- CORE_LEDGER_STATE_COUCHDBCONFIG_COUCHDBADDRESS=couchdb:5984
|
|
working_dir: /opt/gopath/src/github.com/hyperledger/fabric
|
|
command: peer node start
|
|
# command: peer node start --peer-chaincodedev=true
|
|
ports:
|
|
- 7051:7051
|
|
- 7053:7053
|
|
volumes:
|
|
- /var/run/:/host/var/run/
|
|
- ./crypto-config/peerOrganizations/org1.example.com/peers/peer0.org1.example.com/:/etc/hyperledger/msp/peer
|
|
- ./crypto-config/peerOrganizations/org1.example.com/users:/etc/hyperledger/msp/users
|
|
- ./config:/etc/hyperledger/configtx
|
|
depends_on:
|
|
- orderer.example.com
|
|
networks:
|
|
- basic
|
|
|
|
couchdb:
|
|
container_name: couchdb
|
|
image: hyperledger/fabric-couchdb:x86_64-1.0.0-beta
|
|
ports:
|
|
- 5984:5984
|
|
environment:
|
|
DB_URL: http://localhost:5984/member_db
|
|
networks:
|
|
- basic
|