Automate and schedule MySQL database dumps from a docker container.

What are the best practices of getting a daily backup of mysql database from a docker container and is it possible to send them to DigitalOcean Spaces. Is DigitalOcean Spaces secure enough to store backups?


Show comments

Submit an answer

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!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

@user000001 You have quite a few options for MySQL database backups in general.

  • Duplicity is a handy tool for keeping stuff nice and secure.
  • Object Storage like the DO Space’s offering isn’t the most ideal due to latency constraints. Usually, Spaces would be used for more of your static content, than constantly changing files.
  • I like creating DigitalOcean Volumes myself. Then you have the flexibility of attaching and detaching volumes between containers or easily migrating or snapshot it too. It works great for Docker persistent volume mountpoints.
  • Also, Encryption: Volumes are encrypted using the LUKS (Linux Unified Key Setup) specification. The entire storage cluster is encrypted, which ensures that snapshots of volumes are also encrypted at rest.
  • Give doctl a try too. It’s DigitalOcean’s official command line utility and a handy way to hook into the backend with scripts.