References:
Note: use stop.sh
to shutdown daemons!
This is easiest and recommended way. The only caveat is the fixed password for postgres user. As long as you keep the firewall rejecting connections to postgres server, this won't be an issue; otherwise you'll have to change the password after restoring from backup and update the password configuration in docker-compose.yml
accordingly.
The scripts are tested on debian 12. Clone this repo and follow the steps.
- Run ./setup.sh and reboot the server
- Restore the latest backup from https://github.com/alexgo-io/stacks-node-mainnet/releases
- Run ./start.sh
- Run
watch 'curl -s http://127.0.0.1:3999/extended'
, wait until the block height matches that fromhttps://api.hiro.so/v2/info
- Done
The scripts are tested on debian 12. Remember to check if you're using the latest versions in docker-compose.yml
before following the steps below.
# prerequisites
./setup.sh
Start 2 terminals to restore stacks node and postgres, this will take a long time.
# terminal 1
./restore-archive-pg.sh
# terminal 2
./restore-archive-node.sh
Start all daemons
./start.sh
Check if everything works.
docker-compose logs -f
Wait until the block height catches up with official node: https://api.hiro.so/v2/info
watch 'curl -s http://127.0.0.1:3999/extended'