Hemi
Last updated
Was this helpful?
Last updated
Was this helpful?
source <(curl -s https://raw.githubusercontent.com/NodersUA/Scripts/main/hemi)
sudo apt update
# Install Go
source <(curl -s https://raw.githubusercontent.com/NodersUA/Scripts/main/system/go)
git clone https://github.com/hemilabs/heminetwork.git
cd heminetwork
make deps
make install
cp popmd /usr/local/bin/
cd ~/heminetwork/bin && ./keygen -secp256k1 -json -net="testnet" > ~/heminetwork/bin/popm-address.json
Get tokens from
sudo tee /root/heminetwork/.env > /dev/null <<EOF
POPM_BTC_PRIVKEY=$(jq -r '.private_key' ~/heminetwork/bin/popm-address.json)
POPM_STATIC_FEE=20
POPM_BFG_URL=wss://testnet.rpc.hemi.network/v1/ws/public
EOF
sudo tee /etc/systemd/system/popmd.service > /dev/null <<EOF
[Unit]
Description=Hemi Service
After=network.target
[Service]
User=root
Type=simple
EnvironmentFile=/root/heminetwork/.env
ExecStart=/usr/local/bin/popmd
Restart=on-failure
[Install]
WantedBy=multi-user.target
EOF
# Start the node
systemctl daemon-reload
systemctl enable popmd
systemctl restart popmd && journalctl -u popmd -f -o cat