TransWikia.com

Hyperledger fabric instantiate timeout because of internet speed, how can I use taobao.org npm image , not official image

Stack Overflow Asked by user14014310 on February 25, 2021

houyuqi@ubuntu:~/fabric-samples/raft-4node-swarm$ sudo docker exec cli peer chaincode instantiate -o orderer.example.com:7050 –tls –cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem -C mychannel -n xiot13 -v 1.0 -c ‘{"Args":["org.xiotnet.xiotdata:instantiate"]}’ -P "AND (‘Org1MSP.peer’, ‘Org2MSP.peer’)" -l node
2020-08-22 03:02:51.094 UTC [chaincodeCmd] checkChaincodeCmdParams -> INFO 001 Using default escc
2020-08-22 03:02:51.094 UTC [chaincodeCmd] checkChaincodeCmdParams -> INFO 002 Using default vscc
Error: could not assemble transaction, err proposal response was not successful, error code 500, msg chaincode registration failed: error starting container: error starting container: Failed to generate platform-specific docker build: Error returned from build: 1 "npm WARN >[email protected] No repository field.

npm ERR! network timeout at: https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2020-08-22T03_05_22_721Z-debug.log
"

Firstly, chaincode is implemented using fabric-chaincode-node.
Instantiattion can succeed on a server, whose internet speeds is quick,
but on local virtual machine, It always fail。

I try another way — replace official npm mirror to https://registry.npm.taobao.org, through the command:
npm config set registry https://registry.npm.taobao.org.

But, build image still use official https://registry.npmjs.org.
can I use https://registry.npm.taobao.org ?

anyone help me, thank you.

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP