Open J0WI opened 5 years ago
Thanks for opening this and getting it started. I have had a similar idea for quite some time now to attempt to simplify / use more "off the shelf" components, so this is a welcome proposal.
I am interested to see if there are any comments from the greater CachetHQ community on this one, I'm not sure if there are any strong preferences either way :)
No further comments so far. How should I proceed with this?
@J0WI Sorry for the long delay in responding.
It seems like this would be a welcome change and refresh, if you are still interested. As you may have noticed, the myself and the other current maintainers of this docker image are not super active here.
For me it appears useful to ditch nginx and supervisor from this image completely, and rather integrate nginx with a dedicated nginx.conf through docker compose.
This also allows to keep up to date with newer Nginx versions more easily.
Examples can be taken from
Then the examples could also note how to configure the queue, a suiting database (Redis, Memcached, ...) and how to run workers in a separate container.
Agreed. But this would result in a whole rewrite of the Dockerfile and break everything. I wanted to start with this part first. If you prefer to do the rewrite in a single step I can push all changes to this PR.
I believe the current test failure is due to a missing mysql-client
package for the MySQL DB tests.
@djdefi thanks for the hint, all tests are now passing.
I propose to use the PHP image of the docker library: https://hub.docker.com/_/php
As a first step, this PR keeps the current concept with nginx and supervisor running the same container. I'd also like to introduce some best practices for writing Dockerfiles. My goal is to get rid of supervisor completely and providing a pure FPM variant and a variant using php-apache as an alternative. This concept is inspired by other well known PHP images like Wordpress, Drupal, Joomla, Nextcloud, Matomo etc. They all run and scale pretty well in production.
You can find more information about the docker library and how to become an "official image" yourself here:
Please let me know how you think about it and if I should continue with this. Feel free to reach out if you have any questions.