安装最新版本curl
sudo apt-get install curl
安装python 2.7
sudo apt-get install python
安装golang 1.12.x
wget https://dl.google.com/go/go1.12.13.linux-amd64.tar.gz
sudo tar -C /usr/local -zxvf go1.12.13.linux-amd64.tar.gz
vim ~/.bashrc
export GOROOT=/usr/local/go
export GOPATH=~/go
export PATH=$PATH:$GOROOT/bin
export PATH=$PATH:$GOPATH/bin
source ~/.bashrc
安装docker 17.06.2 或更新版本
sudo apt-get update
sudo apt-get install \
apt-transport-https \
ca-certificates \
curl \
gnupg-agent \
software-properties-common
curl -fsSL http://mirrors.aliyun.com/docker-ce/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] http://mirrors.aliyun.com/docker-ce/linux/ubuntu $(lsb_release -cs) stable"
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io
sudo vim /etc/docker/daemon.json
{"registry-mirrors":["http://hub-mirror.c.163.com"]}
sudo systemctl daemon-reload
service docker restart
sudo usermod -a -G docker [USER]
service docker restart
docker version
sudo groupadd docker
sudo gpasswd -a $USER docker
newgrp docker
安装docker-compose
sudo curl -L "https://github.com/docker/compose/releases/download/1.26.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
安装node.js(版本>=8.9.4或>=10.15.3)
wget -qO- https://deb.nodesource.com/setup_10.x | sudo -E bash -
sudo apt-get install -y nodejs
npm config list
npm set registry https://registry.npm.taobao.org/
下载fabric-samples和镜像
cd go
curl -sSL https://raw.githubusercontent.com/hyperledger/fabric/master/scripts/bootstrap.sh -o bootstrap.sh
https://github.com/hyperledger/fabric/releases/download/v1.4.4/hyperledger-fabric-linux-amd64-1.4.4.tar.gz
https://github.com/hyperledger/fabric-ca/releases/download/v1.4.4/hyperledger-fabric-ca-linux-amd64-1.4.4.tar.gz
tar -zxvf hyperledger-fabric-linux-amd64-1.4.4.tar.gz
tar -zxvf hyperledger-fabric-ca-linux-amd64-1.4.4.tar.gz
sudo ./bootstrap.sh