-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmanual install
117 lines (91 loc) · 5.22 KB
/
manual install
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
# From Nodejumper.io Guide
# install dependencies, if needed
sudo apt update
sudo apt install -y curl git jq lz4 build-essential unzip
if [ ! -f "/usr/local/go/bin/go" ]; then
bash <(curl -s "https://raw.githubusercontent.com/nodejumper-org/cosmos-scripts/master/utils/go_install.sh")
source .bash_profile
fi
#!/bin/bash
NODE_MONIKER="YOUR_NODE_MONIKER"
cd || return
rm -rf defund
git clone https://github.com/defund-labs/defund.git
cd defund || return
git checkout v0.1.0
make install
defundd version # 0.1.0
defundd config keyring-backend test
defundd config chain-id defund-private-3
defundd init $NODE_MONIKER --chain-id defund-private-3
cd || return
curl -L https://github.com/defund-labs/testnet/raw/main/defund-private-3/defund-private-3-gensis.tar.gz > defund-private-3-gensis.tar.gz
tar -xvzf defund-private-3-gensis.tar.gz
rm -rf defund-private-3-gensis.tar.gz
sudo mv -f genesis.json $HOME/.defund/config/genesis.json
sha256sum $HOME/.defund/config/genesis.json # 1a10121467576ab6f633a14f82d98f0c39ab7949102a77ab6478b2b2110109e3
curl -s https://snapshots3-testnet.nodejumper.io/defund-testnet/addrbook.json > $HOME/.defund/config/addrbook.json
sed -i 's|^minimum-gas-prices *=.*|minimum-gas-prices = "0.0001ufetf"|g' $HOME/.defund/config/app.toml
seeds=""
peers="6366ac3af3995ecbc48c13ce9564aef0c7a6d7df@defund-testnet.nodejumper.io:28656,[email protected]:29656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:36656,[email protected]:36656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:34656,[email protected]:24666,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:27656"
sed -i -e 's|^seeds *=.*|seeds = "'$seeds'"|; s|^persistent_peers *=.*|persistent_peers = "'$peers'"|' $HOME/.defund/config/config.toml
# in case of pruning
sed -i 's|pruning = "default"|pruning = "custom"|g' $HOME/.defund/config/app.toml
sed -i 's|pruning-keep-recent = "0"|pruning-keep-recent = "100"|g' $HOME/.defund/config/app.toml
sed -i 's|pruning-interval = "0"|pruning-interval = "17"|g' $HOME/.defund/config/app.toml
sudo tee /etc/systemd/system/defundd.service > /dev/null << EOF
[Unit]
Description=Defund Node
After=network-online.target
[Service]
User=$USER
ExecStart=$(which defundd) start
Restart=on-failure
RestartSec=10
LimitNOFILE=10000
[Install]
WantedBy=multi-user.target
EOF
defundd tendermint unsafe-reset-all --home $HOME/.defund --keep-addr-book
cd "$HOME/.defund" || return
rm -rf data
SNAP_NAME=$(curl -s https://snapshots3-testnet.nodejumper.io/defund-testnet/ | egrep -o ">defund-private-3.*\.tar.lz4" | tr -d ">")
curl https://snapshots3-testnet.nodejumper.io/defund-testnet/${SNAP_NAME} | lz4 -dc - | tar -xf - -C $HOME/.defund
sudo systemctl daemon-reload
sudo systemctl enable defundd
sudo systemctl restart defundd
sudo journalctl -u defundd -f --no-hostname -o cat
# Create wallet
defundd keys add wallet
## Console output
#- name: wallet
# type: local
# address: defund1r9kmadqs9nsppn4wz5yp4rw8zn9545rc4zwvs7
# pubkey: '{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"Auq9WzVEs5pCoZgr2WctjI7fU+lJCH0I3r6GC1oa0tc0"}'
# mnemonic: ""
#!!! SAVE SEED PHRASE
kite upset hip dirt pet winter thunder slice parent flag sand express suffer chest custom pencil mother bargain remember patient other curve cancel sweet
# Wait util the node is synced, should return FALSE
defundd status 2>&1 | jq .SyncInfo.catching_up
# Go to https://discord.gg/UsER6bWuUq and request tokens in faucet channel
# Verify the balance
defundd q bank balances $(defundd keys show wallet -a)
## Console output
# balances:
# - amount: "20000000"
# denom: ufetf
# Create validator
defundd tx staking create-validator \
--amount=19000000ufetf \
--pubkey=$(defundd tendermint show-validator) \
--moniker="YOUR_VALIDATOR_MONIKER" \
--chain-id=defund-private-3 \
--commission-rate=0.1 \
--commission-max-rate=0.2 \
--commission-max-change-rate=0.05 \
--min-self-delegation=1 \
--fees=2000ufetf \
--from=wallet \
-y
# Make sure you see the validator details
defundd q staking validator $(defundd keys show wallet --bech val -a)