This project provides several useful Docker-Compose script to help quickly bootup a Hyperledger Fabric network, and do simple testing with deploy, invoke and query transactions.
Currently we support Hyperledger Fabric releases from v0.6.0 and 1.x up to the latest 3.1.x example in this repository.
If you're not familiar with Docker and Blockchain, can have a look at these books (in CN):
| Fabric Release | Description |
|---|---|
| Fabric Latest | latest fabric code, unstable. |
| Fabric v3.1.4 | fabric 3.1.4 release with CCAAS lifecycle tests. |
| Fabric v3.0.0 | fabric 3.0.0 release with CCAAS lifecycle tests. |
| Fabric v2.5.0 | fabric 2.5.0 release. |
| Fabric v2.4.0 | fabric 2.4.0 release. |
| Fabric v2.3.3 | fabric 2.3.3 release. |
| Fabric v2.3.0 | fabric 2.3.0 release. |
| Fabric v2.2.8 | fabric 2.2.8 LTS release. |
| Fabric v2.2.4 | fabric 2.2.4 LTS release. |
| Fabric v2.2.1 | fabric 2.2.1 LTS release. |
| Fabric v2.2.0 | fabric 2.2.0 LTS release. |
| Fabric v2.1.0 | fabric 2.1.0 release. |
| Fabric v2.0.0 | fabric 2.0.0 release. |
| Fabric v1.4.9 | fabric 1.4.9 LTS release. |
| Fabric v1.4.8 | fabric 1.4.8 LTS release. |
| Fabric v1.4.7 | fabric 1.4.7 LTS release. |
| Fabric v1.4.6 | fabric 1.4.6 LTS release. |
| Fabric v1.4.5 | fabric 1.4.5 LTS release. |
| Fabric v1.4.4 | fabric 1.4.4 LTS release. |
| Fabric v1.4.3 | fabric 1.4.3 release. |
| Fabric v1.4.2 | fabric 1.4.2 release. |
| Fabric v1.4.0 | fabric 1.4.0 release. |
| Fabric v1.3.0 | fabric 1.3.0 release. |
| Fabric v1.2.0 | fabric 1.2.0 release. |
| Fabric v1.1.0 | fabric 1.1.0 release. |
| Fabric v1.0.6 | fabric v1.0.6 release. |
| Fabric v1.0.0 | fabric v1.0.0 release. |
| Fabric v0.6.0 | fabric v0.6.0 release (too old, not recommend to use). |
$ export RELEASE=v3.1.4$ cd ${RELEASE}; make setup testMore details are as below.
Enter the subdir of specific version and setup, e.g.,
$ cd ${RELEASE} # select a fabric version
$ make setup download # Install docker/compose, and pull required imagesThe following command will run the entire process (start a fabric network, create channel, test chaincode and stop it.) pass-through.
$ make test # Test with default fabric RAFT modeFor v3.1.4, chaincode lifecycle tests use an external chaincode service
instead of the legacy in-peer Docker build flow. The validated sequence is:
$ make stop clean
$ make start
$ make channel_test update_anchors
$ make test_cc_install test_cc_queryinstalled
$ make test_cc_approveformyorg test_cc_queryapproved
$ make test_cc_checkcommitreadiness test_cc_commit
$ make test_cc_querycommitted test_cc_invoke_queryPrometheus dashboard listens at http://localhost:9090 to track the network statistics.
In v2.x and v3.x, only raft is supported.
In v1.4.x, solo and kafka are also supported.
$ HLF_MODE=raft make test # Bootup a fabric network with solo modeSee detailed steps
.env: docker images tags, used by those docker-compose files;scripts/variable.sh: docker images tags and project versions, used by scripts;
- Hyperledger Fabric project.