We have now successfully written our asset management chaincode using the Go language. It is now time to build and deploy our assetmgr chaincode to Hyperledger Fabric.
Compiling and deploying Fabric chaincode
Getting ready
Let's first get the fabric library in our environment. Navigate to the assetmgr directory, run the get chaincode library command, and then start build:
cd $GOPATH/src/assetmgr
go get -u github.com/hyperledger/fabric/core/chaincode/shim
go build
This will load the chaincode library and compile the Go code. Next, we will deploy the chaincode using the dev mode. Normally, we need to define our own channel, peer, and configuration Docker container to run our chaincode. Hyperledger, however, provides a sample...