stacksfoundation / stacks-machine-images

Image validation, automation, and other tools for Public Cloud providers
Other
1 stars 3 forks source link

Document and reduce time to sync for AWS images #5

Open sbs2001 opened 11 months ago

sbs2001 commented 11 months ago

Currently it takes significant time to sync the node.

@wileyj suggested to bootstrap the node from chainstate archive to speed up the process.

wileyj commented 11 months ago

Thanks for the issue!

This repo essentially uses this repo here to run the Stacks blockchain with an API: https://github.com/stacks-network/stacks-blockchain-docker

after this machine-image was created - Hiro added some public chainstate archives, which I've scripted as part of the docker repo: https://github.com/stacks-network/stacks-blockchain-docker/blob/master/scripts/seed-chainstate.sh

I think it would be trivial to trigger that script to run if and env var is added to the instance when it starts, i.e. SEED_CHAINSTATE=true etc.

wileyj commented 11 months ago

long term, i think we can use webhooks to trigger some builds (i.e. when there is a new version of the api or blockchain)

sbs2001 commented 11 months ago

Do you think we should have a github action to build+publish the image to AWS ? We could start by manually triggering it and eventually have webhooks triggering it as you said.