安装 sshsudo apt-get updatesudo apt-get install ssh安装 Go下载Go源码下载 选择对应的平台下载。准备在下载的位置打开 terminal 。安装sudo tar -zxvf goxxxxx.tar.gz -C /usr/local, 建议 /usr/local 位置安装。配置sudo gedit /etc/profile, 追加以下配置到环境变量。export GOROOT=/usr/local/goexport GOPATH=~/code/gosave and exit.测试source /etc/profile 立即适应新环境输入 go version,成功查看版本信息杂表示配置成功。安装 Docker-CE前置工作sudo apt-get updatesudo apt-get install apt-transport-https ca-certificates curl software-properties-commoncurl -fsSL https://mirrors.ustc.edu.cn/docker-ce/linux/ubuntu/gpg | sudo apt-key add -sudo apt-get update安装 Dockersudo apt-get install docker-ce将当前用户添加到 Docker Group(支持不使用 sudo 执行 docker 命令)sudo usermod -aG docker bey测试docker run hello-world,正确输出结果如下:Hello from Docker!This message shows that your installation appears to be working correctly.To generate this message, Docker took the following steps: 1. The Docker client contacted the Docker daemon. 2. The Docker daemon pulled the “hello-world” image from the Docker Hub. (amd64) 3. The Docker daemon created a new container from that image which runs the executable that produces the output you are currently reading. 4. The Docker daemon streamed that output to the Docker client, which sent it to your terminal.To try something more ambitious, you can run an Ubuntu container with: $ docker run -it ubuntu bashShare images, automate workflows, and more with a free Docker ID: https://hub.docker.com/For more examples and ideas, visit: https://docs.docker.com/get-started/安装 Docker-Compose下载最先版本的 Docker Composesudo curl -L https://github.com/docker/compose/releases/download/1.24.0-rc1/docker-compose-uname -s-uname -m -o /usr/local/bin/docker-compose给二进制文件添加执行权sudo chmod +x /usr/local/bin/docker-compose查看版本docker-compose -v下载 fabric 及其镜像go get可以的话,直接 go get 获取 go get github.com/hyperledger/fabric,如果 go get 命令无法执行,再试试 Gitgit clone创建目录 mkdir -p $GOPATH/src/github.com/hyperledger/,进入目录 cd $GOPATH/src/github.com/hyperledger/克隆 fabric git clone https://github.com/hyperledger/fabric.git,下载完成后,进入 fabric 文件夹切换 1.4 版本(可选)git checkout v1.4.0生成 fabric-tools下载 fabric-samplecd $GOPATH/src/github.com/hyperledger/fabric/scripts./bootstrap.sh该脚本运行时间较长,主要是在下载 fabrice 各个组件的 docker 镜像将 fabric-tools 复制到 usr/local/bin 目录cd $GOPATH/src/github.com/hyperledger/fabric/scripts/fabric-samples/binsudo cp -r . /usr/local/bin这样就可以到处使用 fabric-tools 了。测试cd $GOPATH/src/github.com/hyperledger/fabric/scripts/fabric-samples/first-network./byfn.sh down./byfn.sh up看到如下信息表示部署成功,恭喜!========= All GOOD, BYFN execution completed =========== _____ _ _ ____ | | | \ | | | _ \ | | | | | | | | | | | | |\ | | || | |_____| || _| |____/