通过test-network-k8s和chaincode service在vscode调试智能合约

概要步骤

通过fabric sample中的test-network-k8s和chaincode service在vscode调试智能合约。 合约选用fabric sample中的chaincode-external
通过test-network-k8s和chaincode service在vscode调试智能合约

网络配置

127.0.0.1 host.docker.internal > /etc/hosts

合约配置

{
  "address": "host.docker.internal:9999",
  "dial_timeout": "10s",
  "tls_required": false
}

启动test-network-k8s指向位于host.docker.internal:9999的合约

$ ./network up
$ ./network channel create
$ export TEST_NETWORK_CHAINCODE_NAME=asset-transfer-basic-debug
$ export TEST_NETWORK_CHAINCODE_IMAGE=localhost:5000/asset-transfer-basic

$ ./network chaincode install
Installing chaincode "asset-transfer-basic-debug":
✅ - Packaging chaincode folder chaincode/asset-transfer-basic-debug ...
✅ - Transferring chaincode archive to org1 ...
✅ - Installing chaincode for org org1 ...
上一篇:git remote: HTTP Basic: Access denied 错误解决办法


下一篇:蓝桥杯 基础练习 BASIC-3 字母图形