I have a complex question. I’m running my own physical server where I host my project and project for my paying clients. I offer standard hosting with Apache/PHP/MySQL/FTP/mails. I’ve been doing this for years and I always used ISPConfig to manage my websites and mails.
Now, I’m configuring a new server and I want to catch up with trends and make my client websites/mails more secure. I’d like to make my server more manageable than ever - so, if I ever want to host client’s project on some other server, the process would’t be so time consuming like it’s now.
I’m thinking of doing this with Docker. I came to conclusion that Docker would be the best solution for making everything more secure (sandboxing) and manageable. I’ve learnt a lot about Docker in past days and I think that I undestand more than just basics.
The problem is, I have no idea how to do this - I mean how to do the topology of whole solution, how to interconnect Docker containers and how much abstraction should I introduce to the whole solution. And since I have no experience in this area, I thought someone more experienced could help me with this.
To give you some examples:
- I could make every domain sepparate interconnected docker containers (one container for mails of domain foo.com, one container for websites on foo.com, one container for databases on foo.com, another for bar.com and so on and have them accesed via reverse proxy)
- I could do one container for all websites, one for all databases and one for all mails
- I could do sepparate container with Apache/MySQL/whatever per domain and access via reverse proxy
- Doing some magic with Docker swarm?
What path should I take? What is a bad idea? Are there any practical articles about this matter? Is there any way to introduce ISPConfig to this solution, or some similiar graphical tool?