In your opinion what are the pros and cons of the two solutions? Here's what comes to my mind:
TCP/IP Socket with two containers
PRO
- better scalability
- different services on different containers are more reliable in case of problems (auto-restart etc)
CONS
- worse performance (pack/unpack every request between apache and php-fpm)
- more containers (so more OSes) to manage for the physical server (greater use of ram)
- more logs (that's supposition) so more disk space used
Unix Socket with single container
PRO
- better performance
- fewer logs on disk
CONS
- worse scalability
- a service will be executed automatically by Docker (great reliability etc). The other could be started with some workarounds (example). But more services in a single container is not the most recommended idea