-
-
Notifications
You must be signed in to change notification settings - Fork 649
Switch Apache to use FPM instead of mod_php #346
Comments
Steps to manually switch (at least on Ubuntu 14.04):
If it were just Ubuntu 14.04, I'd be adding the support immediately. As it is, this is a complicated enough configuration (why, oh why, Apache!?) that I'd rather add a new role, - { role: geerlingguy.apache-fastcgi-php, when: drupalvm_webserver == 'apache' } I'll also need to add the role to |
It's actually much simpler, it seems... adding the line below will proxy requests through PHP-FPM in each Drupal site virtualhost: apache_vhosts:
- servername: "{{ drupal_domain }}"
documentroot: "{{ drupal_core_path }}"
extra_parameters: |
ProxyPassMatch ^/(.*\.php(/.*)?)$ "unix:/var/run/php5-fpm.sock|fcgi://localhost{{ drupal_core_path }}" And as long as we have Apache 2.4 (e.g. use the below task to set it to 2.4 on Ubuntu 12.04), we can just enable mod_proxy_fcgi, and the above proxypass works wonderfully: - name: Add repository for Apache 2.4 on Ubuntu 12.04.
apt_repository: repo='ppa:ondrej/apache2'
when: ansible_distribution_version == "12.04" I'm updating the freshly-renamed |
So... I definitely need to add the ability to configure—at a minimum—the It might be best to default to whatever we use with Nginx currently (by default), as that would require the least amount of rework. |
I'm very close to finishing this... just completing testing against:
|
For CentOS 6, I'm just updating the docs and mentioning that users can either elect to use mod_php or switch to Nginx. I'm not going to support an extra role + more layers of setup just to get Apache 2.4+ running on CentOS 6. See also #376. |
By default, Apache 2.4 will use mod_php instead of FPM. I'd like to have Apache use FPM instead, to ensure extra consistency with Nginx and better overall performance.
The text was updated successfully, but these errors were encountered: