我通过阅读此文档Hyperledger Fabric consortium on Azure Kubernetes Service (AKS)来设置超级账本结构网络。网络端一切正常。现在我想为这个网络设置超级账本结构浏览器。为了做到这一点,我做了以下步骤,
- git 克隆https://github.com/hyperledger/blockchain-explorer.git
- git 签出标签/v1.0.0-rc2
- 应用程序/持久性/结构/postgreSQL/db
- ./createdb.sh
- ./main.sh 安装
- 替换了连接配置文件(app/platform/fabric/connection-profile/first-network.json),如下所示,
{
"certificateAuthorities": {
"ca.xxxxxxxxxxxxx.eastus.aksapp.io": {
"caName": "ca.org1",
"tlsCACerts": {
"pem": "-----BEGIN CERTIFICATE-----dfsajk-----END CERTIFICATE-----\n"
},
"url": "grpcs://ca.xxxxxxxxxxxxx.eastus.aksapp.io:443"
}
},
"client": {
"tlsEnable": true,
"adminUser": "admin.org1",
"adminPassword": "",
"enableAuthentication": false,
"connection": {
"timeout": {
"orderer": "300",
"peer": {
"endorser": "300"
}
}
},
"organization": "org1"
},
"channels": {
"hrschannel": {
"orderers": ["orderer1.yyyyyyyyyyyyyyyyyyyyy.eastus.aksapp.io"],
"peers": {
"peer1.xxxxxxxxxxxxx.eastus.aksapp.io": {}
}
}
},
"name": "org1",
"organizations": {
"org1": {
"certificateAuthorities": [
"org1CA"
],
"mspid": "org1",
"peers": [
"peer1.xxxxxxxxxxxxx.eastus.aksapp.io"
]
}
},
"peers": {
"peer1.xxxxxxxxxxxxx.eastus.aksapp.io": {
"grpcOptions": {
"hostnameOverride": "peer1.xxxxxxxxxxxxx.eastus.aksapp.io",
"ssl-target-name-override": "peer1.xxxxxxxxxxxxx.eastus.aksapp.io"
},
"tlsCACerts": {
"pem": "-----BEGIN CERTIFICATE-----jjdadjijfifawj-----END CERTIFICATE-----\n"
},
"url": "grpcs://peer1.xxxxxxxxxxxxx.eastus.aksapp.io:443"
}
},
"version": "1.0.0",
"wallet": "org1"
}
但是我在这里收到以下错误 tail -f logs/console/console-2020-07-08.log
false 'ssl-certs' '/home/css/delete/blockchain-explorer/ssl-certs'
******* Initialization started for hyperledger fabric platform ******, { 'first-network':
{ name: 'first-network',
profile: './connection-profile/first-network.json' } }
client_configs.name first-network client_configs.profile ./connection-profile/first-network.json
FabricUtils.createFabricClient
config.client.tlsEnable true
FabricConfig, this.config.channels hrschannel
initializeChannelFromDiscover hrschannel
FabricClient.discover_results endpoint { host: 'orderer1.1111111111111111111.eastus.aksapp.io',
port: 443 }
initializeChannelFromDiscover.discoveryProtocol grpcs requesturl grpcs://orderer1.1111111111111111111.eastus.aksapp.io:443
FabricClient.discover_results endpoint { host: 'orderer2.1111111111111111111.eastus.aksapp.io',
port: 443 }
initializeChannelFromDiscover.discoveryProtocol grpcs requesturl grpcs://orderer2.1111111111111111111.eastus.aksapp.io:443
FabricClient.discover_results endpoint { host: 'orderer3.1111111111111111111.eastus.aksapp.io',
port: 443 }
initializeChannelFromDiscover.discoveryProtocol grpcs requesturl grpcs://orderer3.1111111111111111111.eastus.aksapp.io:443
2020-07-08T16:15:30.879Z - error: [Remote.js]: Error: Failed to connect before the deadline URL:grpcs://localhost:443
FabricUtils.createDetachClient
initializeListener, client_name, client first-network { name: 'first-network',
profile: './connection-profile/first-network.json' }
Please open web browser to access :http://localhost:8080/
pid is 13408
Sync process is started for the network : [first-network] and client : [first-network]
config.client.tlsEnable true
FabricConfig, this.config.channels hrschannel
(node:13836) DeprecationWarning: grpc.load: Use the @grpc/proto-loader module with grpc.loadPackageDefinition instead
An identity for the admin user: admin.org1 already exists in the wallet
initializeChannelFromDiscover hrschannel
FabricClient.discover_results endpoint { host: 'orderer1.1111111111111111111.eastus.aksapp.io',
port: 443 }
initializeChannelFromDiscover.discoveryProtocol grpcs requesturl grpcs://orderer1.1111111111111111111.eastus.aksapp.io:443
FabricClient.discover_results endpoint { host: 'orderer2.1111111111111111111.eastus.aksapp.io',
port: 443 }
initializeChannelFromDiscover.discoveryProtocol grpcs requesturl grpcs://orderer2.1111111111111111111.eastus.aksapp.io:443
FabricClient.discover_results endpoint { host: 'orderer3.1111111111111111111.eastus.aksapp.io',
port: 443 }
initializeChannelFromDiscover.discoveryProtocol grpcs requesturl grpcs://orderer3.1111111111111111111.eastus.aksapp.io:443
2020-07-08T16:15:37.490Z - error: [Remote.js]: Error: Failed to connect before the deadline URL:grpcs://localhost:443
SyncServices.synchNetworkConfigToDB client first-network channel_name hrschannel
2020-07-08T16:15:40.744Z - error: [Remote.js]: Error: Failed to connect before the deadline URL:grpcs://localhost:443
<<<<<<<<<<<<<<<<<<<<<<<<<< Synchronizer Error >>>>>>>>>>>>>>>>>>>>>
Error: Orderer with name "orderer2.1111111111111111111.eastus.aksapp.io:443" not assigned to this channel
at Channel.getOrderer (/home/css/delete/blockchain-explorer/node_modules/fabric-network/node_modules/fabric-client/lib/Channel.js:928:10)
at FabricClient.switchOrderer (/home/css/delete/blockchain-explorer/app/platform/fabric/FabricClient.js:681:27)
at FabricClient.getGenesisBlock (/home/css/delete/blockchain-explorer/app/platform/fabric/FabricClient.js:611:26)
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:189:7)
<<<<<<<<<<<<<<<<<<<<<<<<<< Closing client processor >>>>>>>>>>>>>>>>>>>>>
req.body { user: 'admin', password: 'adminpw', network: 'first-network' }
Network: first-network enableAuthentication false
请帮我解决这个问题。