Tools, FAQ, Tutorials:
Peer and CouchDB Container Dependency
Which Peer container depends which CouchDB container in BYFN network?
✍: FYIcenter.com
If you are running BYFN (Build Your First Network) with the CouchDB option,
the Peer and CouchDB Container Dependency is defined in the
"docker-compose-couch.yaml" file.
$ cd ~/hyperledger-binaries/fabric-samples/first-network
$ more docker-compose-couch.yaml
# Copyright IBM Corp. All Rights Reserved.
version: '2'
networks:
byfn:
services:
couchdb0:
container_name: couchdb0
image: hyperledger/fabric-couchdb
environment:
- COUCHDB_USER=
- COUCHDB_PASSWORD=
ports:
- "5984:5984"
networks:
- byfn
peer0.org1.example.com:
environment:
- CORE_LEDGER_STATE_STATEDATABASE=CouchDB
- CORE_LEDGER_STATE_COUCHDBCONFIG_COUCHDBADDRESS=couchdb0:5984
- CORE_LEDGER_STATE_COUCHDBCONFIG_USERNAME=
- CORE_LEDGER_STATE_COUCHDBCONFIG_PASSWORD=
depends_on:
- couchdb0
...
couchdb3:
container_name: couchdb3
image: hyperledger/fabric-couchdb
environment:
- COUCHDB_USER=
- COUCHDB_PASSWORD=
ports:
- "8984:5984"
networks:
- byfn
peer1.org2.example.com:
environment:
- CORE_LEDGER_STATE_STATEDATABASE=CouchDB
- CORE_LEDGER_STATE_COUCHDBCONFIG_COUCHDBADDRESS=couchdb3:5984
- CORE_LEDGER_STATE_COUCHDBCONFIG_USERNAME=
- CORE_LEDGER_STATE_COUCHDBCONFIG_PASSWORD=
depends_on:
- couchdb3
As you can see, the Peer and CouchDB dependency is defined as:
peer0.org1.example.com -> couchdb0 peer1.org1.example.com -> couchdb1 peer0.org2.example.com -> couchdb2 peer1.org2.example.com -> couchdb3
By the way, there is no user names and passwords defined to protect CouchDB servers. This is ok for a developer environment.
⇒ Query CouchDB Container API Directly
⇐ CouchDB Container Used in Hyperledger Fabric
2020-07-03, ∼1317🔥, 1💬
Popular Posts:
How to use the built-in "context" object in Policy expressions? The built-in "context" object can be...
What Is session_register() in PHP? session_register() is old function that registers global variable...
How to use the "set-variable" Policy Statement to create custom variables for an Azure API service o...
Where to find tutorials on HTML language? I want to know how to learn HTML. Here is a large collecti...
How to Install Docker Desktop 2.5.0 on Windows 10? You can follow this tutorial to Install Docker De...