This repo contains instructions for genesis validators to create genesis staking transactions (gentxs) to start the Mars Hub network.
Install Go 1.18+. On Ubuntu this can be done by:
wget -q -O - https://go.dev/dl/go1.19.2.linux-amd64.tar.gz | sudo tar xvzf - -C /usr/localConfigure relevant environment variables:
cat <<EOT >> $HOME/.bashrc
export GOROOT=/usr/local/go
export GOPATH=$HOME/.go
export GOBIN=$GOPATH/bin
export PATH=$PATH:$GOPATH/bin:$GOROOT/bin
EOTDownload Mars Hub daemon source code and compile. This will generate a marsd executable under your $GOBIN directory:
git clone https://github.com/mars-protocol/hub.git
cd hub
git checkout v1.0.0
make installInitialize your node. This will generate your validator signing key at ~/.mars/priv_validator_key.json; make sure to backup this file:
marsd initCreate your validator operator key:
marsd keys add validatorAdd your operator key to the genesis state:
marsd genesis add-account validator 1000000umarsNote that the chain id is mars-1 and set the self-bond amount to 1000000umars:
marsd genesis gentx validator 1000000umars \
--pubkey "$(marsd tendermint show-validator)" \
--chain-id mars-1 \
--commission-rate "..." \
--commission-max-rate "..." \
--commission-max-change-rate "..." \
--moniker "..." \
--identity "..." \
--details "..." \
--website "..." \
--security-contact "..."The gentx can be found in ~/.mars/config/gentx/gentx-<hash>.json. Add the file to this repository under the mars-1/gentxs folder by making a PR.