操作系统环境:CentOS 7.6.1810,操作基础目录/data,如无该目录请手动创建(mkdir /data)
Operating system environment: CentOS 7.6.1810, Basic Directory of Operations/data, created manually without this directory (mkdir/data)
yum install -y yum-utils device-mapper-persistent-data lvm2 yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo yum update -y && yum install docker-ce systemctl daemon-reload && systemctl restart docker && systemctl enable docker
docker --version
docker pull julianliu/eth-explorer:latest
docker images
docker run -d -p 8000:8000 --name eth-explorer julianliu/eth-explorer
docker ps
启动成功后,打开对应服务器8000端口访问权限即可看到界面,但界面上并没有区块数据,需要修改容器内页面配置
After the start-up has been successful, the interface can be seen by opening the corresponding server's 8,000 port access rights, but there is no block data on the interface, and the page configuration in the container needs to be modified & nbsp;
docker exec -it eth-explorer sh
/app/app/app.js为容器内路径,修改app.js中GETH_HOSTNAME为自己的节点ip地址
/app/app/app/app.js as the inside path of the container, modifying the GETH_HOSTNAME in the app.js as its own node ip address
angular.min.js:https://mituxiaogaoyang.club/eth-source/angular.min.js
jquery.min.js:https://mituxiaogaoyang.club/eth-source/jquery.min.js
animate.min.css:https://mituxiaogaoyang.club/eth-source/animate.min.css
mainController.js:https://mituxiaogaoyang.club/eth-source/mainController.js
index.html:https://mituxiaogaoyang.club/eth-source/index.html
docker cp /root/nginx/html/eth-source/angular.min.js eth-explorer:/app/app/scripts docker cp /root/nginx/html/eth-source/jquery.min.js eth-explorer:/app/app/scripts docker cp /root/nginx/html/eth-source/animate.min.css eth-explorer:/app/app/styles docker cp /root/nginx/html/eth-source/mainController.js eth-explorer:/app/app/scripts/controllers docker cp /root/nginx/html/eth-source/index.html eth-explorer:/app/app
geth --datadir "https://www.cnblogs.com/mituxiaogaoyang/articles/data" --rpc --rpcaddr=0.0.0.0 --rpcport 8545 --rpccorsdomain "*" --rpcapi "eth,net,web3,personal,admin,txpool,debug,miner" --nodiscover --maxpeers 30 --networkid 1981 --port 30303 --allow-insecure-unlock --mine --miner.etherbase "0xFfD4a30C08d9f16F095f6315e14bd034F7d04fb0" console
这里通过0xffd4a30c08d9f16f095f6315e14bd034f7d04fb0地址向0x1ef3c8b97c47ba09d01be4a0cf633d9f08ef4cd1地址转账2ETH,下面是区块链浏览器上的效果
& nbsp; Transfer of 2ETH via 0xffd4a30c08d9f16f095f6315e14bd034f7d04fb0 to 0x1ef3c8b97c47ba09d01be4a0cf633d9f08ef4cd1 address, below which is the effect on the block chain browser
交易详情:
& nbsp; transaction details:
注册有任何问题请添加 微信:MVIP619 拉你进入群
打开微信扫一扫
添加客服
进入交流群
发表评论