Re:Learn Docker by building a Microservice
by tayo42 on Wednesday June 01, 2016 @11:20AM
(#11815054)
What is there to gain by putting your database in a container? A database probably has its own dedicated server so, your probably not deploying databases often and there's the added complexity of making your data persistent.
[ Parent
| on HN ]
Re:Learn Docker by building a Microservice
by mdk754 on Wednesday June 01, 2016 @12:53PM
(#11816002)
Your point stands, and obviously makes more sense.
My curiosity was more in whether there were performance (or other) bottlenecks which made it technically infeasible.
Re:Learn Docker by building a Microservice
by imaginology on Wednesday June 01, 2016 @01:11PM
(#11816155)
I run my production database in a container, even if it has its own dedicated server. It's nice being able to install, start and initialize the database with a simple docker command or two to get a consistent build, instead of manually setting it up (copying/editing configuration files, deploying schemas, initializing data, setting permissions, etc.) And it makes upgrading the database very easy. Having this process automated and in source control is great. I also have the awesome ability to bundle cron in my database container to schedule regular backups. Persisting data is as simple as mounting a data volume.