Add cleanup_env scripts and update doc
parent
3a098625a6
commit
48f5699459
|
@ -26,6 +26,7 @@ If you want to setup the environment manually, then can follow the below steps i
|
|||
Pull necessary images of peer, orderer, ca, and base image.
|
||||
|
||||
```sh
|
||||
$ bash scripts/cleanup_env.sh
|
||||
$ bash scripts/download_images.sh
|
||||
```
|
||||
|
||||
|
@ -90,7 +91,7 @@ You should see the following output:
|
|||
|_____| |_| \_| |____/
|
||||
```
|
||||
|
||||
#### Chaincode operation
|
||||
#### Chaincode Operations
|
||||
|
||||
After initialize network, you can execute some chaincode operations, such as `query` or `invoke`,
|
||||
and you can modify the parameters and execute this script repeatedly.
|
||||
|
@ -122,7 +123,7 @@ UTC [main] main -> INFO 008 Exiting.....
|
|||
|
||||
So far, we have quickly started a fabric network successfully.
|
||||
|
||||
## Expand
|
||||
## More to explore
|
||||
|
||||
### [Explain the steps](./docs/docker-compose-1peer-usage.md)
|
||||
|
||||
|
@ -149,6 +150,7 @@ Will explain the usage of `cryptogen` and `configtxgen`
|
|||
|
||||
### [Use database couchDB](./docs/couchdb-usage.md)
|
||||
|
||||
|
||||
### [WIP] [kafka usage](./docs/kafka-usage.md)
|
||||
|
||||
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# This script will remove all containers and hyperledger related images
|
||||
|
||||
# Detecting whether can import the header file to render colorful cli output
|
||||
if [ -f ./header.sh ]; then
|
||||
source ./header.sh
|
||||
elif [ -f worker_node_setup/header.sh ]; then
|
||||
source scripts/header.sh
|
||||
else
|
||||
alias echo_r="echo"
|
||||
alias echo_g="echo"
|
||||
alias echo_b="echo"
|
||||
fi
|
||||
|
||||
echo_b "Clean up all containers..."
|
||||
docker rm -f `docker ps -qa`
|
||||
|
||||
echo_b "Clean up all hyperledger related images..."
|
||||
docker rmi $(docker images |grep 'hyperledger')
|
||||
|
||||
echo_g "Env cleanup done!"
|
|
@ -1,6 +1,15 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# Detecting whether can import the header file to render colorful cli output
|
||||
if [ -f ./header.sh ]; then
|
||||
source ./header.sh
|
||||
elif [ -f worker_node_setup/header.sh ]; then
|
||||
source scripts/header.sh
|
||||
else
|
||||
alias echo_r="echo"
|
||||
alias echo_g="echo"
|
||||
alias echo_b="echo"
|
||||
fi
|
||||
|
||||
ARCH=x86_64
|
||||
BASEIMAGE_RELEASE=0.3.1
|
||||
|
|
|
@ -1,13 +1,22 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Detecting whether can import the header file to render colorful cli output
|
||||
if [ -f ./header.sh ]; then
|
||||
source ./header.sh
|
||||
elif [ -f worker_node_setup/header.sh ]; then
|
||||
source scripts/header.sh
|
||||
else
|
||||
alias echo_r="echo"
|
||||
alias echo_g="echo"
|
||||
alias echo_b="echo"
|
||||
fi
|
||||
|
||||
echo
|
||||
echo " ============================================== "
|
||||
echo " ==========initialize businesschannel========== "
|
||||
echo " ============================================== "
|
||||
echo
|
||||
|
||||
source scripts/header.sh
|
||||
|
||||
CHANNEL_NAME="$1"
|
||||
: ${CHANNEL_NAME:="businesschannel"}
|
||||
: ${TIMEOUT:="60"}
|
||||
|
|
|
@ -1,6 +1,15 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# Detecting whether can import the header file to render colorful cli output
|
||||
if [ -f ./header.sh ]; then
|
||||
source ./header.sh
|
||||
elif [ -f worker_node_setup/header.sh ]; then
|
||||
source scripts/header.sh
|
||||
else
|
||||
alias echo_r="echo"
|
||||
alias echo_g="echo"
|
||||
alias echo_b="echo"
|
||||
fi
|
||||
|
||||
if [ xroot != x$(whoami) ]
|
||||
then
|
||||
|
|
|
@ -1,6 +1,15 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# Detecting whether can import the header file to render colorful cli output
|
||||
if [ -f ./header.sh ]; then
|
||||
source ./header.sh
|
||||
elif [ -f worker_node_setup/header.sh ]; then
|
||||
source scripts/header.sh
|
||||
else
|
||||
alias echo_r="echo"
|
||||
alias echo_g="echo"
|
||||
alias echo_b="echo"
|
||||
fi
|
||||
|
||||
COMPOSE_FILE=${1:-"docker-compose-2orgs-4peers.yaml"}
|
||||
|
||||
|
|
|
@ -1,6 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Detecting whether can import the header file to render colorful cli output
|
||||
if [ -f ./header.sh ]; then
|
||||
source ./header.sh
|
||||
elif [ -f worker_node_setup/header.sh ]; then
|
||||
source scripts/header.sh
|
||||
else
|
||||
alias echo_r="echo"
|
||||
alias echo_g="echo"
|
||||
alias echo_b="echo"
|
||||
fi
|
||||
|
||||
CHANNEL_NAME="$1"
|
||||
: ${CHANNEL_NAME:="businesschannel"}
|
||||
|
|
|
@ -1,6 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Detecting whether can import the header file to render colorful cli output
|
||||
if [ -f ./header.sh ]; then
|
||||
source ./header.sh
|
||||
elif [ -f worker_node_setup/header.sh ]; then
|
||||
source scripts/header.sh
|
||||
else
|
||||
alias echo_r="echo"
|
||||
alias echo_g="echo"
|
||||
alias echo_b="echo"
|
||||
fi
|
||||
|
||||
echo
|
||||
echo " ______ __ __ _ _____ ____ _ ______ ______ ______ _____ "
|
||||
|
|
Loading…
Reference in New Issue