Giter VIP home page Giter VIP logo

tron-deployment's Introduction

Scope of use

This script could be used on Linux/MacOS, but not on Windows. Just Support FullNode and SolidityNode.

Download and run script

wget https://raw.githubusercontent.com/tronprotocol/TronDeployment/master/deploy_tron.sh -O deploy_tron.sh

Parameter Illustration

bash deploy_tron.sh --app [FullNode|SolidityNode] --net [mainnet|testnet|privatenet] --db [keep|remove|backup] --heap-size <heapsize>

--app	Optional, Running application. The default node is Fullnode and it could be FullNode or SolidityNode.
--net	Optional, Connecting network. The default network is mainnet and it could be mainnet, testnet.
--db	Optional, The way of data processing could be keep, remove and backup. Default is keep. If you launch two different networks, like from mainnet to testnet or from testnet to mainnet, you need to delete database.
--trust-node	Optional, It only works when deploying SolidityNode. Default is 127.0.0.1:50051. The specified gRPC service of Fullnode, like 127.0.0.1:50051 or 13.125.249.129:50051.
--rpc-port	Optional, Port of grpc. Default is 50051. If you deploy SolidityNode and FullNode on the same host,you need to configure different ports.
--commit	Optional, commitid of project.
--branch	Optional, branch of project.  Mainnet default is latest release and Testnet default is master.
--heap-size  Optional, jvm option: Xmx. The default heap-size is 0.8 * memory size.
--work_space  Optional, default is current directory.

Examples

Deployment of FullNode on the one host.

wget https://raw.githubusercontent.com/tronprotocol/TronDeployment/master/deploy_tron.sh -O deploy_tron.sh
bash deploy_tron.sh

Deployment of SolidityNode on the one host.

wget https://raw.githubusercontent.com/tronprotocol/TronDeployment/master/deploy_tron.sh -O deploy_tron.sh
# User can self-configure the IP and Port of GRPC service in the turst-node field of SolidityNode. trust-node is the fullnode you just deploy.
bash deploy_tron.sh --app SolidityNode --trust-node <grpc-ip:grpc-port>

Deployment of FullNode and SolidityNode on the same host.

# You need to configure different gRPC ports on the same host because gRPC port is available on SolidityNode and FullNodeConfigure and it cannot be set as default value 50051. In this case the default value of rpc port is set as 50041.
wget https://raw.githubusercontent.com/tronprotocol/TronDeployment/master/deploy_tron.sh -O deploy_tron.sh
bash deploy_tron.sh --app FullNode
bash deploy_tron.sh --app SolidityNode --rpc-port 50041

Deployment of grpc gateway

Summary

This script helps you download the code from https://github.com/tronprotocol/grpc-gateway and deploy the code on your environment.

Pre-requests

Please follow the guide on https://github.com/tronprotocol/grpc-gateway Install Golang, Protoc, and set $GOPATH environment variable according to your requirement.

Download and run script

wget https://raw.githubusercontent.com/tronprotocol/TronDeployment/master/deploy_grpc_gateway.sh -O deploy_grpc_gateway.sh

Parameter Illustration

bash deploy_grpc_gateway.sh --rpchost [rpc host ip] --rpcport [rpc port number] --httpport [http port number] 

--rpchost The fullnode or soliditynode IP where the grpc service is provided. Default value is "localhost".
--rpcport The fullnode or soliditynode port number grpc service is consuming. Default value is 50051.
--httpport The port intends to provide http service provided by grpc gateway. Default value is 18890.

Example

Use default configuration:

bash deploy_grpc_gateway.sh

Use customized configuration:

bash deploy_grpc_gateway.sh --rpchost 127.0.0.1 --rpcport 50052 --httpport 18891

tron-deployment's People

Contributors

ithinker1991 avatar forfreeday avatar yrp avatar hyxc avatar shydesky avatar xiechang33 avatar dorianrust avatar huzhenyuan avatar unforgivenzzz avatar 317787106 avatar tjchern avatar halibobo1205 avatar lvs007 avatar jiangyy0824 avatar taihaofu avatar ss334452 avatar wubin12 avatar kookiekrak avatar ybhgenius avatar tomatoishealthy avatar ahonnecke avatar m1s5 avatar zhaohong avatar olenheim avatar rlaace423 avatar gologo13 avatar jwrct avatar shiruitao avatar lcgogo avatar shenyongri110 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.