hyperledger fabric 1.4.4 + explorer搭建
基础配置:setenforce 0、关闭防火墙
安装docker
cat <<EOF > /etc/yum.repos.d/kubernetes.repo [kubernetes] name=Kubernetes baseurl=https://mirrors.aliyun.com/kubernetes/yum/repos/kubernetes-el7-x86_64/ enabled=1 gpgcheck=1 repo_gpgcheck=1 gpgkey=https://mirrors.aliyun.com/kubernetes/yum/doc/yum-key.gpg https://mirrors.aliyun.com/kubernetes/yum/doc/rpm-package-key.gpg EOF yum update #安装docker yum install docker.x86_64 -y
安装docker-compose
下载好需要的docker镜像以及配置和代码,如下链接进行下载:https://pan.baidu.com/s/1yujG_pw9HNT_3127vltMWw
上传下载的所有文件到centos中
执行如下命令进行镜像还原:
docker load < docker.io_prom_prometheus.tar docker load < docker.io_grafana_grafana.tar docker load < docker.io_hyperledger_explorer-db.tar docker load < docker.io_hyperledger_explorer.tar docker load < docker.io_hyperledger_fabric-javaenv.tar docker load < hyperledger_fabric-javaenv.tar docker load < docker.io_hyperledger_fabric-ca.tar docker load < hyperledger_fabric-ca.tar docker load < docker.io_hyperledger_fabric-tools.tar docker load < hyperledger_fabric-tools.tar docker load < docker.io_hyperledger_fabric-ccenv.tar docker load < hyperledger_fabric-ccenv.tar docker load < docker.io_hyperledger_fabric-orderer.tar docker load < hyperledger_fabric-orderer.tar docker load < docker.io_hyperledger_fabric-peer.tar docker load < hyperledger_fabric-peer.tar docker load < hyperledger_fabric-zookeeper.tar docker load < docker.io_hyperledger_fabric-zookeeper.tar docker load < docker.io_hyperledger_fabric-kafka.tar docker load < hyperledger_fabric-kafka.tar docker load < docker.io_hyperledger_fabric-couchdb.tar docker load < hyperledger_fabric-couchdb.tar
启动hyperledger fabric网络:
cd /root/fabric-samples/first-network ./byfn.sh up -l java -o etcdraft -s couchdb
启动hyperledger explorer:
配置blockchain-explorer/docker-compose.yaml
explorer.mynetwork.com: image: hyperledger/explorer:latest ...... volumes: ...... - ./examples/net1/crypto:/tmp/crypto
上面红色部分需要改成实际的fabric配置路径,默认为:/root/fabric-samples/first-network/crypto-config
配置blockchain-explorer\examples\net1\connection-profile\first-network.json
修改红色部分到实际密钥文件路径:
启动
cd /blockchain-explorer docker-compose up -d
http://ip:8090
用户名/密码是 admin/adminpw
cat <<EOF > /etc/yum.repos.d/kubernetes.repo
[kubernetes]
name=Kubernetes
baseurl=https://mirrors.aliyun.com/kubernetes/yum/repos/kubernetes-el7-x86_64/
enabled=1
gpgcheck=1
repo_gpgcheck=1
gpgkey=https://mirrors.aliyun.com/kubernetes/yum/doc/yum-key.gpg https://mirrors.aliyun.com/kubernetes/yum/doc/rpm-package-key.gpg
EOF
yum update
#安装 wget
sudo
yum
install
-y wget
#安装docker
yum
install
docker.x86_64 -y
相关推荐
pxy 2020-08-15
Walter的学习笔记 2020-03-04
Aggressivesnail 2020-03-03
ShiShuo 2019-12-31
pxy 2019-12-08
photoed 2019-11-04
Aggressivesnail 2019-10-31
zhuce 2018-08-23
zhuce 2018-09-24
whb 2018-04-03
开发学习者 2019-07-01
加油码农 2019-07-01
willorfang的学习 2019-07-01
开发学习者 2019-07-01
岳英豪 2019-07-01
ShangQuan0 2019-07-01
withjeffrey 2019-07-01
加油码农 2019-07-01
hackeey 2020-03-26