drupal-docker / php

Dockerized PHP for Drupal :droplet::whale:
https://hub.docker.com/r/drupaldocker/php/
MIT License
38 stars 51 forks source link

Custom php.ini #9

Closed slashrsm closed 8 years ago

slashrsm commented 8 years ago

When using official php images in my projects I needed to use custom php (memory_limit, ...).

Would it be possible to ship images with Drupal-optimized php.ini?

zaporylie commented 8 years ago

Definitely! You are welcome to share Drupal-optimized php.ini, and we can add it to drupaldocker/php. Lets call it drupal.ini and copy to /usr/local/etc/php/conf.d/ like that:

COPY drupal.ini /usr/local/etc/php/conf.d/

I would say we could keep there only overwrites for specific keys like memory_limit etc. - no need to override whole php.ini.

That has to be done for all php variations - from fpm to apache and from 5.4 to 7. The same for CLI image when it will be merged into master.

For now I just added opcache-recommended.ini (eg. https://github.com/drupal-docker/php/blob/master/apache/5.6/opcache-recommended.ini) for all images 5.5+ which adds optimized opcache settings.