I am trying to deploy a sample business network from behind a corporate proxy. I am following the developer tutorial provided. While running the command
composer network start --networkName tutorial-network --networkVersion 0.0.1 --networkAdmin admin --networkAdminEnrollSecret adminpw --card PeerAdmin@hlfv1 --file networkadmin.card -o npmrcFile=/Users/user/.npmrc
I get the following error
Error: Error trying to start business network. Error: No valid responses from any peers. Response from attempted peer comms was an error: Error: REQUEST_TIMEOUT Command failed
Docker logs show the following error for a new container trying to install something using npm commands
*2018-07-22T03:00:58.228907438Z npm WARN notice [SECURITY] debug has the following vulnerability: 1 low. Go here for more details: https://nodesecurity.io/advisories?search=debug&version=2.6.2 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] hoek has the following vulnerability: 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=hoek&version=2.16.3 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
2018-07-22T03:01:06.734626419Z
> x509@0.3.3 install /chaincode/output/node_modules/x509
> node-gyp rebuild
2018-07-22T03:01:06.734705076Z
gyp WARN install got an error, rolling back install
gyp ERR! configure error
gyp ERR! stack Error: self signed certificate in certificate chain
gyp ERR! stack at TLSSocket.<anonymous> (_tls_wrap.js:1103:38)
gyp ERR! stack at emitNone (events.js:106:13)
gyp ERR! stack at TLSSocket.emit (events.js:208:7)
gyp ERR! stack at TLSSocket._finishInit (_tls_wrap.js:637:8)
gyp ERR! stack at TLSWrap.ssl.onhandshakedone (_tls_wrap.js:467:38)
gyp ERR! System Linux 4.9.87-linuxkit-aufs
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /chaincode/output/node_modules/x509
gyp ERR! node -v v8.9.4
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN tutorial-network@0.0.1 No repository field.
npm WARN The package composer-common is included as both a dev and production dependency.
2018-07-22T03:01:07.835711840Z
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! x509@0.3.3 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the x509@0.3.3 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.*
Logs from peer container
2018-07-22 03:00:34.761 UTC [container] lockContainer -> DEBU 64a got container (dev-peer0.org1.example.com-tutorial-network-0.0.1) lock
2018-07-22 03:00:34.762 UTC [dockercontroller] Start -> DEBU 64b Cleanup container dev-peer0.org1.example.com-tutorial-network-0.0.1
2018-07-22 03:00:34.762 UTC [dockercontroller] stopInternal -> DEBU 64c Stop container dev-peer0.org1.example.com-tutorial-network-0.0.1(No such container: dev-peer0.org1.example.com-tutorial-network-0.0.1)
2018-07-22 03:00:34.763 UTC [dockercontroller] stopInternal -> DEBU 64d Kill container dev-peer0.org1.example.com-tutorial-network-0.0.1 (No such container: dev-peer0.org1.example.com-tutorial-network-0.0.1)
2018-07-22 03:00:34.763 UTC [dockercontroller] stopInternal -> DEBU 64e Remove container dev-peer0.org1.example.com-tutorial-network-0.0.1 (No such container: dev-peer0.org1.example.com-tutorial-network-0.0.1)
2018-07-22 03:00:34.763 UTC [dockercontroller] Start -> DEBU 64f Start container dev-peer0.org1.example.com-tutorial-network-0.0.1
2018-07-22 03:00:34.763 UTC [dockercontroller] createContainer -> DEBU 650 Create container: dev-peer0.org1.example.com-tutorial-network-0.0.1
2018-07-22 03:00:34.765 UTC [dockercontroller] Start -> DEBU 651 start-could not find image <dev-peer0.org1.example.com-tutorial-network-0.0.1-6695b9314667cc296171c0da511644e9011aa9a3ba0f6e759aca9e32e458803c> (container id <dev-peer0.org1.example.com-tutorial-network-0.0.1>), because of <no such image>...attempt to recreate image
2018-07-22 03:00:34.765 UTC [chaincode-platform] generateDockerfile -> DEBU 652
FROM hyperledger/fabric-baseimage:x86_64-0.4.6
ADD binpackage.tar /usr/local/src
LABEL org.hyperledger.fabric.chaincode.id.name="tutorial-network" \
org.hyperledger.fabric.chaincode.id.version="0.0.1" \
org.hyperledger.fabric.chaincode.type="NODE" \
org.hyperledger.fabric.version="1.1.0" \
org.hyperledger.fabric.base.version="0.4.6"
ENV CORE_CHAINCODE_BUILDLEVEL=1.1.0
2018-07-22 03:00:34.766 UTC [util] DockerBuild -> DEBU 653 Attempting build with image hyperledger/fabric-ccenv:x86_64-1.1.0
.npmrc configuration
registry=http://registry.npmjs.org/
strict-ssl=false
unsafe-perm=true
ca=
rejectUnauthorized=false
proxy=my proxy
https-proxy=myproxy
My configuration
Mac OSX High Sierra
composer-cli 0.19
Hyperledger fabric version 1.1
Using a corporate firewall
Although there are numerous posts with similar issues. None of them have been able to solve my issue. Any help, guidance is greatly appreciated
you are trying to provide the npmrc file as part of the start command, which won't work. it should be passed as part of the install command
composer network install -a mybn.bna -c myadmin@fabric-network -o npmrcFile=/Users/user/.npmrc
Set the following environment variable:
NODE_TLS_REJECT_UNAUTHORIZED=0
(orexport NODE_TLS_REJECT_UNAUTHORIZED=0
).