1、方式一
直接去Docker Hub上直接下載:
https://hub.docker.com/r/hyperledger/
docker pull hyperledger/fabric-peer:x86_64-1.0.1
docker pull hyperledger/fabric-orderer:x86_64-1.0.1
docker pull hyperledger/fabric-ccenv:x86_64-1.0.1
docker pull hyperledger/fabric-ca:x86_64-1.0.1
docker pull hyperledger/fabric-baseos:x86_64-0.3.1
docker pull hyperledger/fabric-tools:x86_64-1.0.1
docker tag docker.io/hyperledger/fabric-ca:x86_64-1.0.1 hyperledger/fabric-ca:latest
docker tag docker.io/hyperledger/fabric-peer:x86_64-1.0.1 hyperledger/fabric-peer:latest
docker tag docker.io/hyperledger/fabric-orderer:x86_64-1.0.1 hyperledger/fabric-orderer:latest
docker tag docker.io/hyperledger/fabric-ccenv:x86_64-1.0.1 hyperledger/fabric-ccenv:latest
docker tag docker.io/hyperledger/fabric-tools:x86_64-1.0.1 hyperledger/fabric-tools:latest
2、方式二
下載fabric的源碼檔案:curl -O https://codeload.github.com/hyperledger/fabric/tar.gz/v1.0.1
解壓:tar -zxvf v1.0.1
在解壓後的源檔案路徑中找到一份bootstrap-1.0.1.sh:github.com/hyperledger/fabric/scripts/bootstrap-1.0.1.sh
執行:sh bootstrap-1.0.1.sh
執行後就要開始等待鏡像下載了,下載完成後,可以用以下命令,查看下載的鏡像
docker images | grep hyperledger*
3、方式三
仍然是方式二下載的源檔案中路徑github.com/hyperledger/fabric/examples/e2e_cli/下邊有個download-dockerimages.sh的檔案
執行命令:source download-dockerimages.sh -c x86_64-1.0.0 -f x86_64-1.0.0
這樣也可以下載所有需要的Fabric Docker鏡像了。
4、方式四
在這個地址https://github.com/hyperledger/fabric-samples/tree/v1.0.2/scripts有個fabric-preload.sh的指令檔可以用來自動下載需要版本的鏡像。
fabric-preload.sh will preload all of the requisite docker images for Hyperledger Fabric and tag them with the 'latest' tag. Optionally, specify a specific version (e.g. 1.0.1). Default version is 1.0.0.
./fabric-preload.sh [version]