我正在超级账本结构提供的开发环境中编写我的链码应用程序。我想为这个应用程序提供一个 Web UI。IBM-BlockChain 提供了一个使用 HFC SDK 和 node.js 应用程序的示例。我正在尝试遵循此处所示的相同示例SDK-Demo。此示例部署在 IBM-BlueMix 上,并具有 ServiceCredentials.json 文件,其中包含以下条目
{
"peers": [
{
"discovery_host": "36a78535bcdf4ef0g96h85619i046271-vp3.us.blockchain.ibm.com",
"discovery_port": 30001,
"api_host": "36a78535bcdf4ef0g96h85619i046271-vp3.us.blockchain.ibm.com",
"api_port_tls": 5001,
"api_port": 5001,
"event_host": "36a78535bcdf4ef0g96h85619i046271-vp3.us.blockchain.ibm.com",
"event_port": 31001,
"type": "peer",
"network_id": "36a78535bcdf4ef0g96h85619i046271",
"container_id": "b90e4977ff987e34ceb193daafdf7723751f6a195771125a12051ac44442367e",
"id": "36a78535bcdf4ef0g96h85619i046271-vp3",
"api_url": "http://36a78535bcdf4ef0g96h85619i046271-vp3.us.blockchain.ibm.com:5001"
},
{
"discovery_host": "36a78535bcdf4ef0g96h85619i046271-vp0.us.blockchain.ibm.com",
"discovery_port": 30001,
"api_host": "36a78535bcdf4ef0g96h85619i046271-vp0.us.blockchain.ibm.com",
"api_port_tls": 5001,
"api_port": 5001,
"event_host": "36a78535bcdf4ef0g96h85619i046271-vp0.us.blockchain.ibm.com",
"event_port": 31001,
"type": "peer",
"network_id": "36a78535bcdf4ef0g96h85619i046271",
"container_id": "dea7d34e49827e1ddb465fae16bb40724a7aeaac8775d8193a7071f0cf51e13b",
"id": "36a78535bcdf4ef0g96h85619i046271-vp0",
"api_url": "http://36a78535bcdf4ef0g96h85619i046271-vp0.us.blockchain.ibm.com:5001"
},
],
"ca": {
"36a78535bcdf4ef0g96h85619i046271-ca": {
"url": "36a78535bcdf4ef0g96h85619i046271-ca.us.blockchain.ibm.com:30001",
"discovery_host": "36a78535bcdf4ef0g96h85619i046271-ca.us.blockchain.ibm.com",
"discovery_port": 30001,
"api_host": "36a78535bcdf4ef0g96h85619i046271-ca.us.blockchain.ibm.com",
"api_port_tls": 30001,
"api_port": 30001,
"type": "ca",
"network_id": "36a78535bcdf4ef0g96h85619i046271",
"container_id": "0083cc6af273d82a18698763348494708063af871bead073f1899ce1726f5e07"
}
},
"users": [
{
"enrollId": "admin",
"enrollSecret": "c62d4d9a5d",
"affiliation": "group1",
"username": "admin",
"secret": "c62d4d9a5d"
},
{
"enrollId": "WebAppAdmin",
"enrollSecret": "50dd43e4c0",
"affiliation": "group1",
"username": "WebAppAdmin",
"secret": "50dd43e4c0"
}
],
"cert": "https://blockchain-certs.mybluemix.net/us.blockchain.ibm.com.cert",
"cert_path": "/certs/peer/cert.pem"
}
我没有使用 IBM-BlueMix,因此无法获取自动生成的凭据文件。如何为我的环境生成凭据文件?