部署Nervos ReBirth

安装Ruby

sudo apt-get install -qqy  curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libxml2-dev libxslt1-dev libcurl4-openssl-dev

git clone git://github.com/sstephenson/rbenv.git .rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc

git clone git://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build
echo 'export PATH="$HOME/.rbenv/plugins/ruby-build/bin:$PATH"' >> ~/.bashrc

rbenv install 2.5.1
rbenv global 2.5.1

安装Rails

gem install builder rails

安装Secp256k1

secp256k1是椭圆曲线加密算法的实现

git clone https://github.com/bitcoin-core/secp256k1.git && cd secp256k1

./autogen.sh && ./configure --enable-module-recovery --enable-experimental --enable-module-ecdh

make -j4
sudo make install

如果提示 autoreconf: not found 安装 sudo apt-get install autoconf automake libtool

安装PostgreSQL

sudo apt-get install -y postgresql postgresql-client

更多内容参考 PostgreSQL入门

安装ReBirth依赖

git clone https://github.com/cryptape/re-birth.git && cd re-birth

bundle install --jobs 20 --retry 5 --without development test

如果提示checking for libpq-fe.h... no, 安装 sudo apt-get install -y libpq-dev

参考:

https://github.com/cryptape/re-birth
https://juejin.im/post/5baedabcf265da0a9624dead

    原文作者:shooter
    原文地址: https://www.jianshu.com/p/6d19f37d55d2
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞