The last one said to install the Docker and Docker-compose, now start downloading the source code and joining the channel
Download and install the Curl tool
1, create Fabric Engineering and project directory.
Mkdir-p work
CD work Then, execute the following code:
Curl-l https://raw.githubusercontent.com/voodoo12345/polaris/master/fabpre.tar.gz-o fabpre.tar.gz 2>/dev/null; TAR-XVF fabpre.tar.gz
After this command is executed, the related components of the deployment fabric network are downloaded and uncompressed, including Docker Compose scripts, channel creation/addition scripts, authentication-used cryptographic elements, and so on.
Your current directory looks like this:
Ls
ccenv channel_test.sh docker-compose.yml fabpre.tar.gz src tmp 2, creating a fabric network with Docker
1 Ensure that the hyperledger/fabric-ccenv mirrors are labeled Latest:
Execute Docker-compose Build
2 Create Fabric network, create channel (original), add peer node to channel:
Before up, first modify
Of these two files
Address is Order container address, address can be viewed through PS-EF
Otherwise, the CLI grpc timeout is caused
Execute docker-compose up
3) Check your container:
Docker PS
4 Ensure that the channel was successfully created and that the node was successfully joined:
Execute Docker exec-it CLI sh
5 View the results of channel creation/node joins:
Cat Results.txt
The results of the screen display are as follows:
6 Verify the creation of the creation block successfully, execute the following command:
Ls-ltr Myc1.block