do some sql-minor-fixing, refs #1486 - set version to 0.9.33-rc1 for possible upcoming release-candidate

Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann (d00p)
2014-12-29 14:59:58 +01:00
parent d765cc8633
commit c6f3b03891
5 changed files with 42 additions and 32 deletions

View File

@@ -226,15 +226,15 @@ CREATE TABLE `panel_domains` (
`zonefile` varchar(255) NOT NULL default '',
`dkim` tinyint(1) NOT NULL default '0',
`dkim_id` int(11) unsigned NOT NULL default '0',
`dkim_privkey` text NOT NULL default '',
`dkim_pubkey` text NOT NULL default '',
`dkim_privkey` text,
`dkim_pubkey` text,
`wwwserveralias` tinyint(1) NOT NULL default '1',
`parentdomainid` int(11) unsigned NOT NULL default '0',
`openbasedir` tinyint(1) NOT NULL default '0',
`openbasedir_path` tinyint(1) NOT NULL default '0',
`speciallogfile` tinyint(1) NOT NULL default '0',
`ssl_redirect` tinyint(4) NOT NULL default '0',
`specialsettings` text NOT NULL,
`specialsettings` text,
`deactivated` tinyint(1) NOT NULL default '0',
`bindserial` varchar(10) NOT NULL default '2000010100',
`add_date` int( 11 ) NOT NULL default '0',
@@ -260,12 +260,12 @@ CREATE TABLE `panel_ipsandports` (
`namevirtualhost_statement` tinyint(1) NOT NULL default '0',
`vhostcontainer` tinyint(1) NOT NULL default '0',
`vhostcontainer_servername_statement` tinyint(1) NOT NULL default '0',
`specialsettings` text NOT NULL default '',
`specialsettings` text,
`ssl` tinyint(4) NOT NULL default '0',
`ssl_cert_file` varchar(255) NOT NULL,
`ssl_key_file` varchar(255) NOT NULL,
`ssl_ca_file` varchar(255) NOT NULL,
`default_vhostconf_domain` text NOT NULL,
`default_vhostconf_domain` text,
`ssl_cert_chainfile` varchar(255) NOT NULL,
`docroot` varchar(255) NOT NULL default '',
PRIMARY KEY (`id`)
@@ -535,14 +535,14 @@ INSERT INTO `panel_settings` (`settinggroup`, `varname`, `value`) VALUES
('panel', 'password_numeric', '0'),
('panel', 'password_special_char_required', '0'),
('panel', 'password_special_char', '!?<>§$%&+#=@'),
('panel', 'version', '0.9.33-dev3');
('panel', 'version', '0.9.33-rc1');
DROP TABLE IF EXISTS `panel_tasks`;
CREATE TABLE `panel_tasks` (
`id` int(11) unsigned NOT NULL auto_increment,
`type` int(11) NOT NULL default '0',
`data` text NOT NULL default '',
`data` text NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM CHARSET=utf8 COLLATE=utf8_general_ci;
@@ -815,8 +815,8 @@ CREATE TABLE IF NOT EXISTS `domain_ssl_settings` (
`domainid` int(11) NOT NULL,
`ssl_cert_file` text NOT NULL,
`ssl_key_file` text NOT NULL,
`ssl_ca_file` text NOT NULL,
`ssl_cert_chainfile` text NOT NULL,
`ssl_ca_file` text,
`ssl_cert_chainfile` text,
PRIMARY KEY (`id`)
) ENGINE=MyISAM CHARSET=utf8 COLLATE=utf8_general_ci;

View File

@@ -2818,3 +2818,19 @@ if (isFroxlorVersion('0.9.33-dev2')) {
updateToVersion('0.9.33-dev3');
}
if (isFroxlorVersion('0.9.33-dev3')) {
showUpdateStep("Updating from 0.9.33-dev3 to 0.9.33-rc1", false);
showUpdateStep("Updating database-scheme");
Database::query("ALTER TABLE `".TABLE_PANEL_DOMAINS."` MODIFY `dkim_privkey` text");
Database::query("ALTER TABLE `".TABLE_PANEL_DOMAINS."` MODIFY `dkim_pubkey` text");
Database::query("ALTER TABLE `".TABLE_PANEL_DOMAINS."` MODIFY `specialsettings` text");
Database::query("ALTER TABLE `".TABLE_PANEL_IPSANDPORTS."` MODIFY `specialsettings` text");
Database::query("ALTER TABLE `".TABLE_PANEL_IPSANDPORTS."` MODIFY `default_vhostconf_domain` text");
Database::query("ALTER TABLE `".TABLE_PANEL_DOMAIN_SSL_SETTINGS."` MODIFY `ssl_ca_file` text");
Database::query("ALTER TABLE `".TABLE_PANEL_DOMAIN_SSL_SETTINGS."` MODIFY `ssl_cert_chainfile` text");
lastStepStatus(0);
updateToVersion('0.9.33-rc1');
}

View File

@@ -25,10 +25,15 @@
* @param string Parameter 2
* @param string Parameter 3
* @author Florian Lippert <flo@syscp.org>
* @author Froxlor team <team@froxlor.org>
*/
function inserttask($type, $param1 = '', $param2 = '', $param3 = '', $param4 = '') {
// prepare the insert-statement
$ins_stmt = Database::prepare("
INSERT INTO `" . TABLE_PANEL_TASKS . "` SET `type` = :type, `data` = :data
");
if ($type == '1'
|| $type == '3'
|| $type == '4'
@@ -44,14 +49,15 @@ function inserttask($type, $param1 = '', $param2 = '', $param3 = '', $param4 = '
if ($type == '10' && Settings::Get('system.diskquota_enabled') == '0') {
return;
}
// delete previously inserted tasks if they are the same as we only need ONE
$del_stmt = Database::prepare("
DELETE FROM `" . TABLE_PANEL_TASKS . "` WHERE `type` = :type
");
Database::pexecute($del_stmt, array('type' => $type));
$ins_stmt = Database::prepare("
INSERT INTO `" . TABLE_PANEL_TASKS . "` SET `type` = :type
");
Database::pexecute($ins_stmt, array('type' => $type));
// insert the new task
Database::pexecute($ins_stmt, array('type' => $type, 'data' => ''));
} elseif ($type == '2'
&& $param1 != ''
@@ -65,10 +71,7 @@ function inserttask($type, $param1 = '', $param2 = '', $param3 = '', $param4 = '
$data['gid'] = $param3;
$data['store_defaultindex'] = $param4;
$data = serialize($data);
$ins_stmt = Database::prepare("
INSERT INTO `" . TABLE_PANEL_TASKS . "` SET `type` = '2', `data` = :data
");
Database::pexecute($ins_stmt, array('data' => $data));
Database::pexecute($ins_stmt, array('type' => '2', 'data' => $data));
} elseif ($type == '6'
&& $param1 != ''
@@ -76,10 +79,7 @@ function inserttask($type, $param1 = '', $param2 = '', $param3 = '', $param4 = '
$data = array();
$data['loginname'] = $param1;
$data = serialize($data);
$ins_stmt = Database::prepare("
INSERT INTO `" . TABLE_PANEL_TASKS . "` SET `type` = '6', `data` = :data
");
Database::pexecute($ins_stmt, array('data' => $data));
Database::pexecute($ins_stmt, array('type' => '6', 'data' => $data));
} elseif ($type == '7'
&& $param1 != ''
@@ -89,10 +89,7 @@ function inserttask($type, $param1 = '', $param2 = '', $param3 = '', $param4 = '
$data['loginname'] = $param1;
$data['email'] = $param2;
$data = serialize($data);
$ins_stmt = Database::prepare("
INSERT INTO `" . TABLE_PANEL_TASKS . "` SET `type` = '7', `data` = :data
");
Database::pexecute($ins_stmt, array('data' => $data));
Database::pexecute($ins_stmt, array('type' => '7', 'data' => $data));
} elseif ($type == '8'
&& $param1 != ''
@@ -102,10 +99,7 @@ function inserttask($type, $param1 = '', $param2 = '', $param3 = '', $param4 = '
$data['loginname'] = $param1;
$data['homedir'] = $param2;
$data = serialize($data);
$ins_stmt = Database::prepare("
INSERT INTO `" . TABLE_PANEL_TASKS . "` SET `type` = '8', `data` = :data
");
Database::pexecute($ins_stmt, array('data' => $data));
Database::pexecute($ins_stmt, array('type' => '8', 'data' => $data));
}
}

View File

@@ -51,6 +51,6 @@ define('TABLE_PANEL_DOMAIN_SSL_SETTINGS', 'domain_ssl_settings');
define('TABLE_DOMAINTOIP', 'panel_domaintoip');
// VERSION INFO
$version = '0.9.33-dev3';
$version = '0.9.33-rc1';
$dbversion = '2';
$branding = '';

View File

@@ -955,7 +955,7 @@ $lng['admin']['phpconfig']['domain'] = 'Will be replaced with the domain.';
$lng['admin']['phpconfig']['customer'] = 'Will be replaced with the loginname of the customer who owns this domain.';
$lng['admin']['phpconfig']['admin'] = 'Will be replaced with the loginname of the admin who owns this domain.';
$lng['login']['backtologin'] = 'Back to login';
$lng['serversettings']['mod_fcgid']['starter']['title'] = 'Processes per Domain';
$lng['serversettings']['mod_fcgid']['starter']['title'] = 'Processes per domain';
$lng['serversettings']['mod_fcgid']['starter']['description'] = 'How many processes should be started/allowed per domain? The value 0 is recommended cause PHP will then manage the amount of processes itself very efficiently.';
$lng['serversettings']['mod_fcgid']['wrapper']['title'] = 'Wrapper in Vhosts';
$lng['serversettings']['mod_fcgid']['wrapper']['description'] = 'How should the wrapper be included in the Vhosts';