Tools, FAQ, Tutorials:
Turn on Ledger Peer Operation RESTful API
How to Turn on Ledger Peer Operation RESTful API?
✍: FYIcenter.com
You can follow this tutorial to Turn on Ledger Peer Operation RESTful API.
1. Update Docker Compose YAML file, docker-compose-peer.yaml to override the "operations" settings:
$ cd fabric-peer $ vi docker-compose-peer.yaml # Copyright (c) FYIcenter.com version: '2' services: peer: container_name: peer image: hyperledger/fabric-peer:amd64-1.4.0 command: peer node start environment: - PEER_OPERATIONS_LISTENADDRESS=0.0.0.0:9443 - PEER_OPERATIONS_TLS_ENABLED=false
2. Re-deploy the Peer Docker container:
$ docker stop peer $ docker rm peer $ docker-compose -f docker-compose-peer.yaml up -d $ docker ps hyperledger/fabric-peer:amd64-1.4.0 Up 3 minutes 0.0.0.0:8443->8443/tcp orderer
3. Test the Operation RESTful API:
$ curl http://localhost:9443/healthz {"status":"OK","time":"2019-04-01T21:27:27.323195562Z"} $ curl http://localhost:9443/logspec 404 page not found
As you can see, the operation RESTful API is working. The container is running with 0.0.0.0 as the local IP address. The RESTful API server is listening at 0.0.0.0:9443, which is mapped to the hosting address of localhost:9443 by default. But somehow the "/logspec" operation is not supported.
Â
⇒ Hyperledger Related Terminology
⇠What Is Ledger Peer Operation RESTful API
⇑ Setting Up Ledger Peer Manually
⇑⇑ Hyperledger Tutorials
2019-02-09, 825👍, 0💬
Popular Posts:
How to access Request body from "context.Request.Body" object in Azure API Policy? Request body is t...
How to use "json-to-xml" Azure API Policy Statement? The "json-to-xml" Policy Statement allows you t...
How To Use an Array as a Queue in PHP? A queue is a simple data structure that manages data elements...
What is Azure API Management Publisher Dashboard? Azure API Management Publisher Dashboard is an Azu...
How To Submit Values without Using a Form in PHP? If you know the values you want to submit, you can...