Hi there,
I was trying to explore the API and such and see what I can do to automate my snapshots, but I’m still a bit lost. For one, I cannot use the API to safely shutdown my droplet (have a support issue open but seems like they consider it “best effort”) and I don’t want to risk a power_off due to this being a production server and writing to a database frequently.
I’m open to scripts, other solutions, advice, etc.
Ultimately, I would like to implement the following as a close example:
Does a solution like this exist so that I can automate my snapshots and maintain the images too? At the very least hoping to automate the snapshots and I can manually maintain the images.
Your help would be greatly appreciated, thank you in advance!
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
In case people are wondering about easy and free solutions to this problem, we developed a tool for that because we needed daily backups with custom retention in our company: https://github.com/tomochain/goutte
Second part of this tutorial shows how you can setup an automated snapshot capture using ruby script with crontab.
I’m interested to hear if of any solutions people are using for this. There aren’t any public projects doing this that I know of that have set up the automation. Though, there are a lot of different ways to interact with the API that should make taking snapshots simple as well as API wrappers in different languages. Take a look at our projects page for a list.
One popular tool for using the API is Tugboat. Check out the tutorial here. You can snapshot a droplet as easily as running:
tugboat snapshot snapshot_name droplet_name
As the API commands need to be issues from outside of the droplet, you’ll need to use some sort of local automation tool. If you have a Linux box or a Mac, there is always cron.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.