|
1 |
| -# mainnet |
2 |
| -Passage3d mainnet repository |
| 1 | +# Passage3D Mainnet |
| 2 | + |
| 3 | +This code is inspired from Regen Network's mainnet script |
| 4 | + |
| 5 | +## Building genesis.json (For admin use) |
| 6 | + |
| 7 | +Execute: |
| 8 | +```shell |
| 9 | +go run . build-genesis passage-1 |
| 10 | +``` |
| 11 | + |
| 12 | +For pre-launch, we can ignore errors: |
| 13 | + |
| 14 | +```shell |
| 15 | +go run . build-genesis passage-prelaunch-1 --errors-as-warnings |
| 16 | +``` |
| 17 | + |
| 18 | +## Join as a validator |
| 19 | + |
| 20 | +### Requirements |
| 21 | + |
| 22 | +Check out these [instructions ](./passage-1/README.md#Requirements) for installing `[email protected]` |
| 23 | + |
| 24 | +If you haven't initialized your node, init passage chain by running |
| 25 | + |
| 26 | +```sh |
| 27 | +passage init --chain-id passage-1 <my_node_moniker> |
| 28 | +``` |
| 29 | + |
| 30 | +### Start your validator node |
| 31 | + |
| 32 | +- Step-1: Verify installation |
| 33 | + ```sh |
| 34 | + passage version --long |
| 35 | + ``` |
| 36 | + |
| 37 | + it should display the following details: |
| 38 | + ```sh |
| 39 | + name: passage |
| 40 | + server_name: passage |
| 41 | + version: v1.0.0 |
| 42 | + commit: 1b7c80ef102d3ae7cc40bba3ceccd97a64dadbfd |
| 43 | + build_tags: netgo,ledger |
| 44 | + go: go version go1.15.6 linux/amd64 |
| 45 | + ``` |
| 46 | + |
| 47 | +- Step-2: Download the mainnet genesis |
| 48 | + ```sh |
| 49 | + curl -s https://raw.githubusercontent.com/envadiv/mainnet/main/passage-1/genesis.json > ~/.passage/config/genesis.json |
| 50 | + ``` |
| 51 | + |
| 52 | +- Step-3: Verify genesis |
| 53 | + ```sh |
| 54 | + jq -S -c -M '' ~/.passage/config/genesis.json | shasum -a 256 |
| 55 | + ``` |
| 56 | + It should be equal to the contents in [checksum](passage-1/checksum.txt) |
| 57 | + |
| 58 | +- Step-4: Update seeds and persistent peers |
| 59 | + |
| 60 | + Open `~/.passage/config/config.toml` and update `persistent_peers` and `seeds` (comma separated list) |
| 61 | + #### Persistent peers |
| 62 | + ```sh |
| 63 | + |
| 64 | + ``` |
| 65 | + #### Seeds |
| 66 | + ```sh |
| 67 | + |
| 68 | + ``` |
| 69 | + |
| 70 | +- Step-5: Create systemd |
| 71 | + ```sh |
| 72 | + DAEMON_PATH=$(which passage) |
| 73 | +
|
| 74 | + echo "[Unit] |
| 75 | + Description=passage daemon |
| 76 | + After=network-online.target |
| 77 | + [Service] |
| 78 | + User=${USER} |
| 79 | + ExecStart=${DAEMON_PATH} start |
| 80 | + Restart=always |
| 81 | + RestartSec=3 |
| 82 | + LimitNOFILE=4096 |
| 83 | + [Install] |
| 84 | + WantedBy=multi-user.target |
| 85 | + " >passage.service |
| 86 | + ``` |
| 87 | + |
| 88 | +- Step-6: Update system daemon and start passage node |
| 89 | + |
| 90 | + ``` |
| 91 | + sudo mv passage.service /lib/systemd/system/passage.service |
| 92 | + sudo -S systemctl daemon-reload |
| 93 | + sudo -S systemctl enable passage |
| 94 | + sudo -S systemctl start passage |
| 95 | + ``` |
| 96 | + |
| 97 | +That's all! Your node should be up and running now. You can query your node by executing the following command after the genesis time |
| 98 | +
|
| 99 | +```sh |
| 100 | +passage status |
| 101 | +``` |
| 102 | +
|
| 103 | +### Create validator (Optional) |
| 104 | +Note: This section is applicable for validators who wants to join post genesis time. |
| 105 | +
|
| 106 | +> **IMPORTANT:** Make sure your validator node is fully synced before running this command. Otherwise your validator will start missing blocks. |
| 107 | +
|
| 108 | +```sh |
| 109 | +passage tx staking create-validator \ |
| 110 | + --amount=9000000upasg \ |
| 111 | + --pubkey=$(passage tendermint show-validator) \ |
| 112 | + --moniker="<your_moniker>" \ |
| 113 | + --chain-id=passage-1 \ |
| 114 | + --commission-rate="0.10" \ |
| 115 | + --commission-max-rate="0.20" \ |
| 116 | + --commission-max-change-rate="0.01" \ |
| 117 | + --min-self-delegation="1" \ |
| 118 | + --gas="auto" \ |
| 119 | + --from=<your_wallet_name> |
| 120 | +``` |
0 commit comments