Hyperledger fabric Fabric sdk go应用程序可以';无法连接到SaveChannel上的订购者

Hyperledger fabric Fabric sdk go应用程序可以';无法连接到SaveChannel上的订购者,hyperledger-fabric,hyperledger-fabric-sdk-go,Hyperledger Fabric,Hyperledger Fabric Sdk Go,我正在尝试在fabric sdk中部署我的应用,转到我的hyperledger fabric网络,但在使用SaveChannel功能时出现以下错误:“无法初始化fabric sdk:无法保存通道:创建通道失败:SendEnvelope失败:调用订购方'localhost:7050'失败:订购方客户端状态代码:(2)连接失败。说明:拨号连接超时[localhost:7050]“ 当我用docker日志检查orderer容器时,我有以下信息:“grpc:Server.Serve无法从“ipnumbe

我正在尝试在fabric sdk中部署我的应用,转到我的hyperledger fabric网络,但在使用SaveChannel功能时出现以下错误:“无法初始化fabric sdk:无法保存通道:创建通道失败:SendEnvelope失败:调用订购方'localhost:7050'失败:订购方客户端状态代码:(2)连接失败。说明:拨号连接超时[localhost:7050]“

当我用docker日志检查orderer容器时,我有以下信息:“grpc:Server.Serve无法从“ipnumber:port”完成安全握手:远程错误:tls:bad certificate”(我没有将原始ip和端口放在post上)。我曾尝试在容器中使用TLS disable,但没有成功,发送错误“transport:http2Server.HandleStreams收到来自客户端的虚假问候”

sdk的config.yaml(仅提供有关订购方的信息):

我尝试过其他帖子的一些技巧,比如将url更改为localhost:7050,grpcs://localhost:7050,但什么都不起作用

我发现让一切都起作用的“解决方案”是在docker容器上禁用TLS,并在config.yaml上将allow unsecure设置为true。 可能问题与证书有关,我没有时间解决这个问题

orderers:
  orderer.app.com:
    url: grpc://localhost:7050

    # these are standard properties defined by the gRPC library
    # they will be passed in as-is to gRPC client constructor
    grpcOptions:
      ssl-target-name-override: orderer.app.com
      # These parameters should be set in coordination with the keepalive policy on the server,
      # as incompatible settings can result in closing of connection.
      # When duration of the 'keep-alive-time' is set to 0 or less the keep alive client parameters are disabled
      keep-alive-time: 0s
      keep-alive-timeout: 20s
      keep-alive-permit: false
      fail-fast: false
      # allow-insecure will be taken into consideration if address has no protocol defined, if true then grpc or else grpcs
      allow-insecure: false

    tlsCACerts:
      # Certificate location absolute path
      path: ${GOPATH}/src/github.com/pfc/healthapp/crypto-config/ordererOrganizations/orderer.app.com/tlsca/tlsca.orderer.app.com-cert.pem

...

entityMatchers:

  orderer:
    - pattern: (\w*)orderer.app.com(\w*)
      urlSubstitutionExp: grpc://localhost:7050
      sslTargetOverrideUrlSubstitutionExp: orderer.app.com
      mappedHost: orderer.app.com