eos:ubuntu18.04环境配置

1. 虚拟机硬件要求:内存8G、双核(单核执行eosio-cpp会卡住)。

2. 安装eosio1.5.0

wget https://github.com/eosio/eos/releases/download/v1.5.0/eosio_1.5.0-1-ubuntu-18.04_amd64.deb
sudo apt install ./eosio_1.5.0-1-ubuntu-18.04_amd64.deb

3. 安装eosio.cdt-1.4.1

wget https://github.com/eosio/eosio.cdt/releases/download/v1.4.1/eosio.cdt-1.4.1.x86_64.deb
sudo apt install ./eosio.cdt-1.4.1.x86_64.deb

4. 启动keosd 

keosd &

5. 启动nodeos

nodeos -e -p eosio --plugin eosio::producer_plugin --plugin eosio::history_plugin --plugin eosio::chain_api_plugin --plugin eosio::history_api_plugin --plugin eosio::http_plugin -d /home/bit/bin/eosio/data --config-dir /home/bit/bin/eosio/config --http-server-address=0.0.0.0:8888 --access-control-allow-origin='*' --contracts-console --http-validate-host=false —filter-on='*' 

 6. 修改配置config.ini

# Track actions which match receiver:action:actor. Actor may be blank to include all. Action and Actor both blank allows all from Recieiver. Receiver may not be blank. (eosio::history_plugin)
#filter-on =  -> filter-on = *

# The local IP and port to listen for incoming http connections; set blank to disable. (eosio::http_plugin)
http-server-address = 127.0.0.1:8888 -> http-server-address = 0.0.0.0:8888

7. 重启nodeos

pkill nodeos
nodeos -e -p eosio --plugin ......

8. 测试是否正常运行

    在虚拟机内

http://localhost:8888/v1/chain/get_info

     在主机

http://xxxx:8888/v1/chain/get_info
xxxx:虚拟机IP地址

猜你喜欢

转载自blog.csdn.net/lzt20007/article/details/85000601