From c7e47ed3dfb9116dbeb8a444ec8f2fb1a41d34f9 Mon Sep 17 00:00:00 2001
From: ftimme <ft@falkotimme.com>
Date: Fri, 23 Sep 2011 08:33:25 -0400
Subject: [PATCH] - Added "ipv6only=on" to the IPv6 listen lines in the nginx vhost template to avoid "[emerg]: bind() to [::]:80 failed (98: Address already in use)" errors.

---
 interface/web/admin/form/server_config.tform.php |   99 ++++++++++++++++++++++++++++++++++++++++++++++++-
 1 files changed, 97 insertions(+), 2 deletions(-)

diff --git a/interface/web/admin/form/server_config.tform.php b/interface/web/admin/form/server_config.tform.php
index 9a36919..fe2a1c6 100644
--- a/interface/web/admin/form/server_config.tform.php
+++ b/interface/web/admin/form/server_config.tform.php
@@ -325,7 +325,7 @@
 			'datatype' => 'VARCHAR',
 			'formtype' => 'SELECT',
 			'default' => 'apache',
-			'value' => array('apache' => 'Apache', 'nginx' => 'nginx')
+			'value' => array('apache' => 'Apache', 'nginx' => 'Nginx')
 		),
 		'website_basedir' => array(
 			'datatype' => 'VARCHAR',
@@ -438,6 +438,12 @@
 			'default' => 'y',
 			'value' => array(0 => 'n', 1 => 'y')
 		),
+		'enable_sni' => array(
+			'datatype' => 'VARCHAR',
+			'formtype' => 'CHECKBOX',
+			'default' => 'y',
+			'value' => array(0 => 'n', 1 => 'y')
+		),
 		'user' => array(
 			'datatype' => 'VARCHAR',
 			'formtype' => 'TEXT',
@@ -455,6 +461,28 @@
 			'default' => '',
 			'validators' => array(0 => array('type' => 'NOTEMPTY',
 					'errmsg' => 'apache_group_error_empty'),
+			),
+			'value' => '',
+			'width' => '40',
+			'maxlength' => '255'
+		),
+		'nginx_user' => array(
+			'datatype' => 'VARCHAR',
+			'formtype' => 'TEXT',
+			'default' => '',
+			'validators' => array(0 => array('type' => 'NOTEMPTY',
+					'errmsg' => 'nginx_user_error_empty'),
+			),
+			'value' => '',
+			'width' => '40',
+			'maxlength' => '255'
+		),
+		'nginx_group' => array(
+			'datatype' => 'VARCHAR',
+			'formtype' => 'TEXT',
+			'default' => '',
+			'validators' => array(0 => array('type' => 'NOTEMPTY',
+					'errmsg' => 'nginx_group_error_empty'),
 			),
 			'value' => '',
 			'width' => '40',
@@ -482,6 +510,61 @@
 			'width' => '40',
 			'maxlength' => '255'
 		),
+		'php_fpm_init_script' => array(
+			'datatype' => 'VARCHAR',
+			'formtype' => 'TEXT',
+			'default' => '',
+			'validators' => array(0 => array('type' => 'NOTEMPTY',
+					'errmsg' => 'php_fpm_init_script_error_empty'),
+			),
+			'value' => '',
+			'width' => '40',
+			'maxlength' => '255'
+		),
+		'php_fpm_ini_path' => array(
+			'datatype' => 'VARCHAR',
+			'formtype' => 'TEXT',
+			'default' => '',
+			'validators' => array(0 => array('type' => 'NOTEMPTY',
+					'errmsg' => 'php_fpm_ini_path_error_empty'),
+			),
+			'value' => '',
+			'width' => '40',
+			'maxlength' => '255'
+		),
+		'php_fpm_pool_dir' => array(
+			'datatype' => 'VARCHAR',
+			'formtype' => 'TEXT',
+			'default' => '',
+			'validators' => array(0 => array('type' => 'NOTEMPTY',
+					'errmsg' => 'php_fpm_pool_dir_error_empty'),
+			),
+			'value' => '',
+			'width' => '40',
+			'maxlength' => '255'
+		),
+		'php_fpm_start_port' => array(
+			'datatype' => 'VARCHAR',
+			'formtype' => 'TEXT',
+			'default' => '',
+			'validators' => array(0 => array('type' => 'NOTEMPTY',
+					'errmsg' => 'php_fpm_start_port_error_empty'),
+			),
+			'value' => '',
+			'width' => '40',
+			'maxlength' => '255'
+		),
+		'php_fpm_socket_dir' => array(
+			'datatype' => 'VARCHAR',
+			'formtype' => 'TEXT',
+			'default' => '',
+			'validators' => array(0 => array('type' => 'NOTEMPTY',
+					'errmsg' => 'php_fpm_socket_dir_error_empty'),
+			),
+			'value' => '',
+			'width' => '40',
+			'maxlength' => '255'
+		),
 		'php_open_basedir' => array(
 			'datatype' => 'VARCHAR',
 			'formtype' => 'TEXT',
@@ -492,6 +575,17 @@
 			'value' => '',
 			'width' => '40',
 			'maxlength' => '4000'
+		),
+		'nginx_cgi_socket' => array(
+			'datatype' => 'VARCHAR',
+			'formtype' => 'TEXT',
+			'default' => '',
+			'validators' => array(0 => array('type' => 'NOTEMPTY',
+					'errmsg' => 'nginx_cgi_socket_empty'),
+			),
+			'value' => '',
+			'width' => '40',
+			'maxlength' => '255'
 		),
 		'htaccess_allow_override' => array(
 			'datatype' => 'VARCHAR',
@@ -799,6 +893,7 @@
 	)
 );
 
+/*
 $form["tabs"]['ufw_firewall'] = array (
 	'title' 	=> "UFW Firewall",
 	'width' 	=> 80,
@@ -860,7 +955,7 @@
 	##################################
 	)
 );
-
+*/
 
 $form["tabs"]['vlogger'] = array(
 	'title' => "vlogger",

--
Gitblit v1.9.1