How to handle database working with docker?

0

I started working with docker recently and here's a question and in preparation for a wordpress lamp environment, I came up with my bank and my files.

The idea was to leave everything inside a repository within git-hub that I could clone from anywhere to create the image and reestablish my site, however the git-hub repository has a limit of 100 megs.

How can I work effectively with the bank in these cases using docker?

Do you have to be part of an image to upload to the server or do I treat% share%?

    
asked by anonymous 10.09.2016 / 06:38

1 answer

3

It does not make sense to have BD in image, what you will get will be the DB service, not the bank itself!

You should have the database in a file system docker, and you should do regular backups from your own database tool.

In case of disaster the bank will be recovered through backup, not an image.

Databases perform transactions, calculations, etc ... The database tool has the intelligence to not let the transaction stop in the middle of the path. And also has the fact that it is possible depending on the bank to make online transactions backups, that is, every 15 minutes you can have a backup, in case of disaster the possibility is that you lose only 15 minutes of transaction, this type feature you do not have in an image.

    
12.09.2016 / 19:45