Skip to content

Instantly share code, notes, and snippets.

@davepuchyr
Created August 14, 2020 08:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davepuchyr/f6d8c3caa14fe513487761879ceb8348 to your computer and use it in GitHub Desktop.
Save davepuchyr/f6d8c3caa14fe513487761879ceb8348 to your computer and use it in GitHub Desktop.
Pick-up new genesis_time
#!/bin/bash
sudo systemctl stop starname.service
# reset data
su ${USER_IOV}
set -o allexport ; source /etc/systemd/system/starname.env ; set +o allexport # pick-up env vars
${DIR_IOVNS}/iovnsd unsafe-reset-all --home ${DIR_WORK}
# pull the genesis file
curl --fail https://gist.githubusercontent.com/davepuchyr/e1482e63cb81443cde1616f353c4779f/raw/genesis.json > ${DIR_WORK}/config/genesis.json
sha256sum ${DIR_WORK}/config/genesis.json | grep 002f2508708f603210a137f9f27265f2b1f7ec54a6a5146d4f0de1fa614568e8 || echo 'BAD GENESIS FILE!'
exit # ${USER_IOV}
sudo systemctl start starname.service # wait for genesis_time
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment