0

I have project running on Apache and PHP7 to handle web requests (UI, Forms, etc), it's build on Symfony components, if that makes any difference.

In addition to this, I have a console command that is using pthreads to sent emails concurrently (for speed reasons).

Would like to move the whole project on Docker (transitioning all other projects) and I'm not sure how to do that. There is a php-zts image variant, but that won't work with Nginx (or Apache).

One option I was considering is to have 2 separate php containers (one for fpm and one for zts), but I don't know how the fpm container will call a command on the zts container.

Any ideas/pointer would be appreciated.

Dan F.
  • 1,353
  • 16
  • 23
  • Although it's adding to the container count, you could implement a message queue (I've used RabbitMQ in docker) and the main container just puts tasks into a queue and the zts container sits and polls the queue and does the job. Also means you can add multiple containers of either type to increase capacity. – Nigel Ren Aug 08 '18 at 10:42
  • That's an interesting idea. I'll consider it. thank you – Dan F. Aug 08 '18 at 11:00

0 Answers0