How to setup secure docker hosted MySQL DB for use by multiple apps?
Currently I have a MySQL DB running on the same VPS as my web server. For scalability purposes, and to allow my other apps to access the MySQL DB, I would like to move the DB to it’s own server. Ideally I would like to use CoreOS to host a MySQL docker image to also run some other small dockerized services on the same VPS.
What I’m unsure about is how to ensure secure connections between my web apps and the DB? i.e. encrypted connections.
- configure SSL in MySQL?
- create SSH tunnels from the web apps to the MySQL server?
- I assume in this case I would only have an SSH port open on the VPS firewall.
It would also be great to use private networking (I know that this doesn’t secure the connections) to keep host to host communications free.
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.×