From 6db036235287dbf4d7920027fa2118d239e0e6d5 Mon Sep 17 00:00:00 2001
From: Till Brehm <tbrehm@ispconfig.org>
Date: Wed, 29 Oct 2014 05:28:09 -0400
Subject: [PATCH] Fixed a Bug in Centos 7 were php-fpm uses sockets while mod_proxy_fcgi in centos 7 does not support that yet.

---
 server/plugins-available/apache2_plugin.inc.php |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/server/plugins-available/apache2_plugin.inc.php b/server/plugins-available/apache2_plugin.inc.php
index 969851d..5f2229b 100644
--- a/server/plugins-available/apache2_plugin.inc.php
+++ b/server/plugins-available/apache2_plugin.inc.php
@@ -2664,7 +2664,8 @@
 		$tpl->newTemplate('php_fpm_pool.conf.master');
 		$tpl->setVar('apache_version', $app->system->getapacheversion());
 		
-		if($data['new']['php_fpm_use_socket'] == 'y'){
+		// Use sockets, but not with apache 2.4 on centos (mod_proxy_fcgi) as socket support is buggy in that version
+		if($data['new']['php_fpm_use_socket'] == 'y' && in_array('fastcgi_module',$apache_modules)){
 			$use_tcp = 0;
 			$use_socket = 1;
 			if(!is_dir($socket_dir)) $app->system->mkdirpath($socket_dir);

--
Gitblit v1.9.1