From e88873f2e17c370160abe7079724d1d008e3208e Mon Sep 17 00:00:00 2001 From: BA Date: Thu, 22 Jun 2017 16:06:11 +0200 Subject: [PATCH] Error when trying to instanciate chaincode CORE_VM_DOCKER_HOSTCONFIG_NETWORKMODE is set to "byfn_default" but this network interface does not exist, resulting in an error when trying to instanciate chainecode. As the docker compose file is in the folder "first-network", docker will create a default network called "firstnetwork_default", so should change the env. variable accordingly. Other solution could be to define a custom network "byfn_default" in the docker-compose-cli.yaml file using top-level key "networks" (https://docs.docker.com/compose/networking/) --- first-network/base/peer-base.yaml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/first-network/base/peer-base.yaml b/first-network/base/peer-base.yaml index 89ed7283..ee4dbfa7 100644 --- a/first-network/base/peer-base.yaml +++ b/first-network/base/peer-base.yaml @@ -10,9 +10,11 @@ services: environment: - CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock # the following setting starts chaincode containers on the same - # bridge network as the peers + # bridge network as the peers. + # As the docker compose file is in the folder "first-network", + # docker will create a default network called "firstnetwork_default" # https://docs.docker.com/compose/networking/ - - CORE_VM_DOCKER_HOSTCONFIG_NETWORKMODE=byfn_default + - CORE_VM_DOCKER_HOSTCONFIG_NETWORKMODE=firstnetwork_default #- CORE_LOGGING_LEVEL=ERROR - CORE_LOGGING_LEVEL=DEBUG - CORE_PEER_TLS_ENABLED=true