- Added check for the apps vhost to find out if the default PHP-FPM pool uses port 9000 or the socket /var/run/php5-fpm.sock.
| | |
| | | //$content = str_replace('{fpm_port}', ($conf['nginx']['php_fpm_start_port']+1), $content); |
| | | $content = str_replace('{fpm_socket}', $fpm_socket, $content); |
| | | $content = str_replace('{cgi_socket}', $cgi_socket, $content); |
| | | |
| | | if(file_exists('/var/run/php5-fpm.sock')){ |
| | | $use_tcp = '#'; |
| | | $use_socket = ''; |
| | | } else { |
| | | $use_tcp = ''; |
| | | $use_socket = '#'; |
| | | } |
| | | $content = str_replace('{use_tcp}', $use_tcp, $content); |
| | | $content = str_replace('{use_socket}', $use_socket, $content); |
| | | |
| | | wf($vhost_conf_dir.'/apps.vhost', $content); |
| | | |
| | |
| | | root /usr/share/; |
| | | include /etc/nginx/fastcgi_params; |
| | | # To access phpMyAdmin, the default user (like www-data on Debian/Ubuntu) must be used |
| | | fastcgi_pass 127.0.0.1:9000; |
| | | {use_tcp}fastcgi_pass 127.0.0.1:9000; |
| | | {use_socket}fastcgi_pass unix:/var/run/php5-fpm.sock; |
| | | fastcgi_index index.php; |
| | | fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; |
| | | fastcgi_buffer_size 128k; |
| | |
| | | root /usr/share/; |
| | | include /etc/nginx/fastcgi_params; |
| | | # To access SquirrelMail, the default user (like www-data on Debian/Ubuntu) must be used |
| | | fastcgi_pass 127.0.0.1:9000; |
| | | {use_tcp}fastcgi_pass 127.0.0.1:9000; |
| | | {use_socket}fastcgi_pass unix:/var/run/php5-fpm.sock; |
| | | fastcgi_index index.php; |
| | | fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; |
| | | fastcgi_buffer_size 128k; |
| | |
| | | root /usr/share/; |
| | | include /etc/nginx/fastcgi_params; |
| | | # To access phpMyAdmin, the default user (like www-data on Debian/Ubuntu) must be used |
| | | fastcgi_pass 127.0.0.1:9000; |
| | | {use_tcp}fastcgi_pass 127.0.0.1:9000; |
| | | {use_socket}fastcgi_pass unix:/var/run/php5-fpm.sock; |
| | | fastcgi_index index.php; |
| | | fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; |
| | | fastcgi_buffer_size 128k; |
| | |
| | | root /usr/share/; |
| | | include /etc/nginx/fastcgi_params; |
| | | # To access SquirrelMail, the default user (like www-data on Debian/Ubuntu) must be used |
| | | fastcgi_pass 127.0.0.1:9000; |
| | | {use_tcp}fastcgi_pass 127.0.0.1:9000; |
| | | {use_socket}fastcgi_pass unix:/var/run/php5-fpm.sock; |
| | | fastcgi_index index.php; |
| | | fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; |
| | | fastcgi_buffer_size 128k; |
| | |
| | | //$content = str_replace('{fpm_port}', $web_config['php_fpm_start_port']+1, $content); |
| | | $content = str_replace('{fpm_socket}', $fpm_socket, $content); |
| | | $content = str_replace('{cgi_socket}', $cgi_socket, $content); |
| | | if(file_exists('/var/run/php5-fpm.sock')){ |
| | | $use_tcp = '#'; |
| | | $use_socket = ''; |
| | | } else { |
| | | $use_tcp = ''; |
| | | $use_socket = '#'; |
| | | } |
| | | $content = str_replace('{use_tcp}', $use_tcp, $content); |
| | | $content = str_replace('{use_socket}', $use_socket, $content); |
| | | |
| | | // PHP-FPM |
| | | // Dont just copy over the php-fpm pool template but add some custom settings |