mirror of
https://github.com/hyperledger/fabric-samples.git
synced 2026-06-22 17:45:10 +00:00
There have been lots of changes and quirks with the docker-compose .env file, this change removes the file and explicitly creates and assigns the networks in the compose yaml files. Signed-off-by: Brett Logan <lindluni@github.com> Signed-off-by: David Enyeart <enyeart@us.ibm.com> Co-authored-by: Brett Logan <lindluni@github.com>
This commit is contained in:
parent
46b92e22da
commit
e496083c0b
7 changed files with 16 additions and 24 deletions
|
|
@ -1,3 +0,0 @@
|
||||||
COMPOSE_PROJECT_NAME=net
|
|
||||||
IMAGE_TAG=latest
|
|
||||||
SYS_CHANNEL=system-channel
|
|
||||||
|
|
@ -1,2 +0,0 @@
|
||||||
COMPOSE_PROJECT_NAME=net
|
|
||||||
IMAGE_TAG=latest
|
|
||||||
|
|
@ -5,10 +5,14 @@
|
||||||
|
|
||||||
version: '2'
|
version: '2'
|
||||||
|
|
||||||
|
networks:
|
||||||
|
test:
|
||||||
|
name: fabric_test
|
||||||
|
|
||||||
services:
|
services:
|
||||||
|
|
||||||
ca_org3:
|
ca_org3:
|
||||||
image: hyperledger/fabric-ca:$IMAGE_TAG
|
image: hyperledger/fabric-ca:latest
|
||||||
environment:
|
environment:
|
||||||
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
|
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
|
||||||
- FABRIC_CA_SERVER_CA_NAME=ca-org3
|
- FABRIC_CA_SERVER_CA_NAME=ca-org3
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,7 @@ version: '2'
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
test:
|
test:
|
||||||
|
name: fabric_test
|
||||||
|
|
||||||
services:
|
services:
|
||||||
couchdb4:
|
couchdb4:
|
||||||
|
|
|
||||||
|
|
@ -10,19 +10,17 @@ volumes:
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
test:
|
test:
|
||||||
|
name: fabric_test
|
||||||
|
|
||||||
services:
|
services:
|
||||||
|
|
||||||
peer0.org3.example.com:
|
peer0.org3.example.com:
|
||||||
container_name: peer0.org3.example.com
|
container_name: peer0.org3.example.com
|
||||||
image: hyperledger/fabric-peer:$IMAGE_TAG
|
image: hyperledger/fabric-peer:latest
|
||||||
environment:
|
environment:
|
||||||
#Generic peer variables
|
#Generic peer variables
|
||||||
- CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock
|
- CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock
|
||||||
# the following setting starts chaincode containers on the same
|
- CORE_VM_DOCKER_HOSTCONFIG_NETWORKMODE=fabric_test
|
||||||
# bridge network as the peers
|
|
||||||
# https://docs.docker.com/compose/networking/
|
|
||||||
- CORE_VM_DOCKER_HOSTCONFIG_NETWORKMODE=${COMPOSE_PROJECT_NAME}_test
|
|
||||||
- FABRIC_LOGGING_SPEC=INFO
|
- FABRIC_LOGGING_SPEC=INFO
|
||||||
#- FABRIC_LOGGING_SPEC=DEBUG
|
#- FABRIC_LOGGING_SPEC=DEBUG
|
||||||
- CORE_PEER_TLS_ENABLED=true
|
- CORE_PEER_TLS_ENABLED=true
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ networks:
|
||||||
services:
|
services:
|
||||||
|
|
||||||
ca_org1:
|
ca_org1:
|
||||||
image: hyperledger/fabric-ca:$IMAGE_TAG
|
image: hyperledger/fabric-ca:latest
|
||||||
environment:
|
environment:
|
||||||
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
|
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
|
||||||
- FABRIC_CA_SERVER_CA_NAME=ca-org1
|
- FABRIC_CA_SERVER_CA_NAME=ca-org1
|
||||||
|
|
@ -30,7 +30,7 @@ services:
|
||||||
- test
|
- test
|
||||||
|
|
||||||
ca_org2:
|
ca_org2:
|
||||||
image: hyperledger/fabric-ca:$IMAGE_TAG
|
image: hyperledger/fabric-ca:latest
|
||||||
environment:
|
environment:
|
||||||
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
|
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
|
||||||
- FABRIC_CA_SERVER_CA_NAME=ca-org2
|
- FABRIC_CA_SERVER_CA_NAME=ca-org2
|
||||||
|
|
@ -48,7 +48,7 @@ services:
|
||||||
- test
|
- test
|
||||||
|
|
||||||
ca_orderer:
|
ca_orderer:
|
||||||
image: hyperledger/fabric-ca:$IMAGE_TAG
|
image: hyperledger/fabric-ca:latest
|
||||||
environment:
|
environment:
|
||||||
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
|
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
|
||||||
- FABRIC_CA_SERVER_CA_NAME=ca-orderer
|
- FABRIC_CA_SERVER_CA_NAME=ca-orderer
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ services:
|
||||||
|
|
||||||
orderer.example.com:
|
orderer.example.com:
|
||||||
container_name: orderer.example.com
|
container_name: orderer.example.com
|
||||||
image: hyperledger/fabric-orderer:$IMAGE_TAG
|
image: hyperledger/fabric-orderer:latest
|
||||||
environment:
|
environment:
|
||||||
- FABRIC_LOGGING_SPEC=INFO
|
- FABRIC_LOGGING_SPEC=INFO
|
||||||
- ORDERER_GENERAL_LISTENADDRESS=0.0.0.0
|
- ORDERER_GENERAL_LISTENADDRESS=0.0.0.0
|
||||||
|
|
@ -53,13 +53,10 @@ services:
|
||||||
|
|
||||||
peer0.org1.example.com:
|
peer0.org1.example.com:
|
||||||
container_name: peer0.org1.example.com
|
container_name: peer0.org1.example.com
|
||||||
image: hyperledger/fabric-peer:$IMAGE_TAG
|
image: hyperledger/fabric-peer:latest
|
||||||
environment:
|
environment:
|
||||||
#Generic peer variables
|
#Generic peer variables
|
||||||
- CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock
|
- CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock
|
||||||
# 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=fabric_test
|
- CORE_VM_DOCKER_HOSTCONFIG_NETWORKMODE=fabric_test
|
||||||
- FABRIC_LOGGING_SPEC=INFO
|
- FABRIC_LOGGING_SPEC=INFO
|
||||||
#- FABRIC_LOGGING_SPEC=DEBUG
|
#- FABRIC_LOGGING_SPEC=DEBUG
|
||||||
|
|
@ -93,13 +90,10 @@ services:
|
||||||
|
|
||||||
peer0.org2.example.com:
|
peer0.org2.example.com:
|
||||||
container_name: peer0.org2.example.com
|
container_name: peer0.org2.example.com
|
||||||
image: hyperledger/fabric-peer:$IMAGE_TAG
|
image: hyperledger/fabric-peer:latest
|
||||||
environment:
|
environment:
|
||||||
#Generic peer variables
|
#Generic peer variables
|
||||||
- CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock
|
- CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock
|
||||||
# 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=fabric_test
|
- CORE_VM_DOCKER_HOSTCONFIG_NETWORKMODE=fabric_test
|
||||||
- FABRIC_LOGGING_SPEC=INFO
|
- FABRIC_LOGGING_SPEC=INFO
|
||||||
#- FABRIC_LOGGING_SPEC=DEBUG
|
#- FABRIC_LOGGING_SPEC=DEBUG
|
||||||
|
|
@ -133,7 +127,7 @@ services:
|
||||||
|
|
||||||
cli:
|
cli:
|
||||||
container_name: cli
|
container_name: cli
|
||||||
image: hyperledger/fabric-tools:$IMAGE_TAG
|
image: hyperledger/fabric-tools:latest
|
||||||
tty: true
|
tty: true
|
||||||
stdin_open: true
|
stdin_open: true
|
||||||
environment:
|
environment:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue