How to backup a docker container | Docker Volumes Backups with Ease: A Comprehensive Guide

Ғылым және технология

Welcome to this in-depth guide on implementing a robust and hassle-free backup strategy for your Docker volumes. Whether you're a seasoned Docker pro or just diving into containerization, safeguarding your data is essential. In this video, I'll walk you through every step of the process using the powerful "offen/docker-volume-backup" tool, ensuring your data's safety with minimal effort.
🔗 Link to GitHub files: github.com/marcogreiveldinger...
🔗 offen Repository: offen/docker-volume-backup: github.com/offen/docker-volum...
🔗 Link to restore the volumes: • Never lose any docker ...
Key Points Covered:
Setting up prerequisites:
- Docker, Docker-compose, and a remote backup storage solution (Nextcloud, AWS S3, SSH, WebDAV, and more).
- Exploring the features of "offen" for backup:
- Flexible local and remote backup options
- Customizable cron schedules for automated backups
- Container management: Stop containers during backup for data integrity
- Running scripts before and after backup operations
- GPG encryption for added security
Advantages of utilizing a Docker container for backups:
- Streamlined automation with no manual intervention
- Enhanced security: No additional binaries required on the host (unlike some traditional backup solutions)
Stay ahead in the world of Docker by mastering volume backups with "offen/docker-volume-backup." Don't leave your data vulnerable-learn how to implement a reliable backup strategy that fits your needs. Like, subscribe, and hit the notification bell to stay updated with the latest tech tutorials!
🔔 Stay Connected:
Subscribe to my channel for more insightful tech tutorials and hands-on guides.
🔗 My links:
Github: github.com/marcogreiveldinger
Website: marco-greiveldinger.de
Support me at Patreon: / techwithmarco
00:00 - 00:21 Intro
00:22 - 00:55 How do I manage docker volumes backups
00:56 - 2:10 offen/docker-volume-backup
02:11 - 5:35 docker-compose setup
05:36 - 08:10 environment files for configuration
08:11 - 9:11 dumping a database
09:12 - 10:31 dumping a volume
10:32 - 12:59 global configurations and encryption
13:00 - 15:15 backup in action
15:16 - 16:08 Notifications in slack with webhooks
16:09 - 17:23 Outro and conclusion
#DockerBackup #DataProtection #Containerization #TechTutorial #DevOps #BackupStrategy #opensource #awesomeopensource

Пікірлер: 33

  • @techwithmarco
    @techwithmarco7 ай бұрын

    Here is a tutorial on how to restore the backups with some easy steps to follow :) kzread.info/dash/bejne/eISdtZh8k86anJM.html

  • @mazenyasser5303
    @mazenyasser530310 ай бұрын

    Please don't give up and continue because you deserve 1m+

  • @techwithmarco

    @techwithmarco

    10 ай бұрын

    Yeah! That's the spirit. I already have 3 videos in the pipeline, but still to find time to edit them :-) So stay tuned!

  • @SmartieTV
    @SmartieTV6 ай бұрын

    Very helpful tutorial, thanks a lot! :)

  • @joelfrojmowicz
    @joelfrojmowicz9 ай бұрын

    Amazing explanation on how to work with docker-volume-backup. Thanks for this video. Subscribed!

  • @techwithmarco

    @techwithmarco

    9 ай бұрын

    Thanks a lot! Means a lot to me :-)

  • @mazenyasser5303
    @mazenyasser530310 ай бұрын

    Your videos are very good

  • @techwithmarco

    @techwithmarco

    10 ай бұрын

    Thanks!

  • @yousefpahang
    @yousefpahang9 ай бұрын

    Amazing ! Waiting for Restore video 😉

  • @techwithmarco

    @techwithmarco

    9 ай бұрын

    Thanks! Good call! I have the video on my bucket list :-)

  • @yousefpahang

    @yousefpahang

    8 ай бұрын

    still waiting :-D @@techwithmarco

  • @techwithmarco

    @techwithmarco

    7 ай бұрын

    I hope the wait was worth it 😄 kzread.info/dash/bejne/eISdtZh8k86anJM.html

  • @techwithmarco
    @techwithmarco11 ай бұрын

    I am sorry for the shit focus on the camera after a while.... And by the way, if you have not subscribed yet, now it is the time! 😜😋

  • @davidk.3450
    @davidk.34504 ай бұрын

    Can you give me some examples how to backup volumes that are managed in another docker-compose file? (And maybee how to create a weekly-backup AND a monthly-backup within the same configuration) Thanks a lot

  • @ppaliwal89
    @ppaliwal899 ай бұрын

    this is great! would love to see how to restore from these backups when something indeed goes wrong

  • @techwithmarco

    @techwithmarco

    8 ай бұрын

    Yes, it's already on my list to showcase that in one of my next videos :-)

  • 8 ай бұрын

    +1

  • @techwithmarco

    @techwithmarco

    7 ай бұрын

    Here you go guys :) kzread.info/dash/bejne/eISdtZh8k86anJM.html

  • @Glatze603
    @Glatze6038 ай бұрын

    Hi Marco, nice method, but I personaly prefere a proxmox server so I can easyly backup the complete docker-host regularly and automatically.

  • @techwithmarco

    @techwithmarco

    7 ай бұрын

    Proxmox is on my list to get to know the software :) Lots of people using it which might not be for no reason 😄

  • @rolfamfelt9946
    @rolfamfelt994611 ай бұрын

    Remember to test restore. And a strategy for the pgp encryption pass.

  • @techwithmarco

    @techwithmarco

    11 ай бұрын

    Yes! Thanks for the hint! I just forgot to show that in the video, but having it planned for a future video as a catch up! And for the pgp, this was just to demonstrate how easy that works. But for sure, you should have it stored somewhere securely and then make sure it is not stored in plaintext in your git. But that's also a whole other discussion about credentials from a security perspective... millions of possibilities what to do and what not to do.. 😄

  • @kurukey

    @kurukey

    10 ай бұрын

    ​@@techwithmarcowhere are you from

  • @dukefleedd
    @dukefleedd8 ай бұрын

    How would it look like the compose file if Uptime-Kuma exists already as a service in the server ? Great Tuto though !

  • @techwithmarco

    @techwithmarco

    8 ай бұрын

    Can you elaborate on that? So you mean if the Uptime-Kuma service existed in another docker-compose file and then add the backup service?

  • @TheOnlyEpsilonAlpha
    @TheOnlyEpsilonAlpha11 ай бұрын

    5:31 i wonder you ready only mount the docker socket. Can it then even interact with the containers? 11:44 and I hope that values are not valid anymore when the video goes online 😅 My backup strategy is still in concept state. Currently I redundant store my important data on all servers for redundancy for a hardware failure. But that sounds nice ❤ Edit: And I use resilio sync containers for that

  • @techwithmarco

    @techwithmarco

    11 ай бұрын

    You can try :-) But I made sure to disable this account 😜 The read only mode is just enough to interact with the docker socket. You are then just not able to modify the socket file itself

  • @TheOnlyEpsilonAlpha

    @TheOnlyEpsilonAlpha

    11 ай бұрын

    @@techwithmarco I have to admit: I’m pretty new to docker, but for example, watchtower needs access to the socket to affect the other containers. How does this work in this case with a read only mode? 🤔

  • @techwithmarco

    @techwithmarco

    10 ай бұрын

    @@TheOnlyEpsilonAlpha I think a might be wrong about the docker socket. I just got a comment under my traefik video, that there are other ways to use to docker sockert. Just google for docker-socket-proxy and there is a nice project on github which restrict access to the docker api. I'll take a look at it and maybe do another video about it.

  • @ydiadi_
    @ydiadi_7 ай бұрын

    please do a restore video too

  • @techwithmarco

    @techwithmarco

    7 ай бұрын

    There you go :) kzread.info/dash/bejne/eISdtZh8k86anJM.html

  • @raylab77
    @raylab779 ай бұрын

    This is way too hard for the casual docker user. This is only for experts and deep Linux nerds. I wish someone would make a docker backup docker where most would be configured through a web portal. It would me accessible for the masses.

  • @techwithmarco

    @techwithmarco

    9 ай бұрын

    Yes I can imagine. But you have to think that docker was actually developed for non-persistent containers or data.... So volumes do the exact opposite :-) But therefore tools were created to deal with these 'consequences'. Maybe have a look at portainer, which offers a nice web-ui for configuring docker container stacks. But still, it does not have a nice gui for volume backups. Maybe have a look at borgbackup and borgweb. (I haven't used them) it seems to offer a webui to use to configure stuff.

Келесі