From fbb24acd8b3f31561cd4c2aee789997e515fcff8 Mon Sep 17 00:00:00 2001 From: ftimme Date: Tue, 20 Sep 2011 13:04:49 +0000 Subject: [PATCH] - Updated apps vhost configuration fir nginx. - Enabled Security Level (Server Config > Web > Security Level) for nginx. --- install/lib/installer_base.lib.php | 11 ++++++++++- .../web/admin/templates/server_config_web_edit.htm | 9 +++------ server/conf/php_fpm_pool.conf.master | 4 ++++ server/plugins-available/nginx_plugin.inc.php | 7 +++---- 4 files changed, 20 insertions(+), 11 deletions(-) diff --git a/install/lib/installer_base.lib.php b/install/lib/installer_base.lib.php index b69912bef..7e6fc2379 100644 --- a/install/lib/installer_base.lib.php +++ b/install/lib/installer_base.lib.php @@ -1459,9 +1459,18 @@ class installer_base { $content = str_replace('{apps_vhost_port}', $conf['web']['apps_vhost_port'], $content); $content = str_replace('{apps_vhost_dir}', $conf['web']['website_basedir'].'/apps', $content); $content = str_replace('{apps_vhost_servername}', $apps_vhost_servername, $content); - $content = str_replace('{fpm_port}', $conf['nginx']['php_fpm_start_port'], $content); + $content = str_replace('{fpm_port}', ($conf['nginx']['php_fpm_start_port']+1), $content); wf($vhost_conf_dir.'/apps.vhost', $content); + + // PHP-FPM + // Dont just copy over the php-fpm pool template but add some custom settings + $content = rf('tpl/php_fpm_pool.conf.master'); + $content = str_replace('{fpm_pool}', 'apps', $content); + $content = str_replace('{fpm_port}', ($conf['nginx']['php_fpm_start_port']+1), $content); + $content = str_replace('{fpm_user}', $apps_vhost_user, $content); + $content = str_replace('{fpm_group}', $apps_vhost_group, $content); + wf($conf['nginx']['php_fpm_pool_dir'].'/apps.conf', $content); //copy('tpl/nginx_ispconfig.vhost.master', "$vhost_conf_dir/ispconfig.vhost"); //* and create the symlink diff --git a/interface/web/admin/templates/server_config_web_edit.htm b/interface/web/admin/templates/server_config_web_edit.htm index a7d1026a0..4b85025f5 100644 --- a/interface/web/admin/templates/server_config_web_edit.htm +++ b/interface/web/admin/templates/server_config_web_edit.htm @@ -8,7 +8,7 @@

{tmpl_var name='server_type_txt'}

- {tmpl_var name='server_type'}
@@ -55,7 +55,7 @@
-
+

{tmpl_var name='security_level_txt'}