forked from TERITORI/teritori-chain
-
Notifications
You must be signed in to change notification settings - Fork 3
/
start.sh
executable file
·23 lines (16 loc) · 1.53 KB
/
start.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/bash
rm -rf $HOME/.teritorid/
cd $HOME
teritorid init --chain-id=testing testing --home=$HOME/.teritorid
teritorid keys add validator --keyring-backend=test --home=$HOME/.teritorid
teritorid add-genesis-account $(teritorid keys show validator -a --keyring-backend=test --home=$HOME/.teritorid) 100000000000utori,100000000000stake --home=$HOME/.teritorid
teritorid gentx validator 500000000stake --keyring-backend=test --home=$HOME/.teritorid --chain-id=testing
teritorid collect-gentxs --home=$HOME/.teritorid
VALIDATOR=$(teritorid keys show -a validator --keyring-backend=test --home=$HOME/.teritorid)
sed -i '' -e 's/"owner": ""/"owner": "'$VALIDATOR'"/g' $HOME/.teritorid/config/genesis.json
sed -i '' -e 's/enabled-unsafe-cors = false/enabled-unsafe-cors = true/g' $HOME/.teritorid/config/app.toml
sed -i '' -e 's/enable = false/enable = true/g' $HOME/.teritorid/config/app.toml
sed -i '' -e 's/cors_allowed_origins = \[\]/cors_allowed_origins = ["*"]/g' $HOME/.teritorid/config/config.toml
teritorid start --home=$HOME/.teritorid
# teritorid tx bank send validator pop18mu5hhgy64390q56msql8pfwps0uesn0gf0elf 10000000utori --keyring-backend=test --chain-id=testing --home=$HOME/.teritorid/ --yes --broadcast-mode=block
# teritorid tx airdrop claim-allocation 0x9d967594Cc61453aFEfD657313e5F05be7c6F88F 0xb89733c05568385a861fa20f5c4abe53c23a13962515bf5510638b4e3947b1236963b53de549ae762bbd45427dbd3712ae7d169a935d21e44e7da86b1c552f471b --from=validator --keyring-backend=test --chain-id=testing --home=$HOME/.teritorid/ --yes --broadcast-mode=block