Open jonmchan opened 2 years ago
This isn't only applicable to typescript, it also applies to Go and Java chaincode as well which require GoLang/Java to be installed otherwise deployment will fail.
It's not only an issue with the deploy script but also there is no mention of this in the docs or README for samples or test-network
Hey, @davidkel if faced the same while compiling the project on my local machine. I know where what changes are required. Can you assign me this issue? I have a past experience of writing articles.
@AyushRaj8271 I've assigned to you, thanks for working on a PR!
Using the deployCC.sh script (https://github.com/hyperledger/fabric-samples/blob/main/test-network/scripts/deployCC.sh) from the cli container errors out because npm is not installed. Simple fix -
apk add npm
.This fails at:
https://github.com/hyperledger/fabric-samples/blob/main/test-network/scripts/deployCC.sh#L82
Without this the chaincode is deployed improperly and you can easily miss the error message because I believe it tries to package up an empty chaincode package. Another feature that would be useful if the compile fails, the script should halt and not try to continue to publish a bad chaincode package.