From 7945034004b5cf8e334bac9640f1a59a186ddd0b Mon Sep 17 00:00:00 2001 From: Benjamin Sonntag Date: Sun, 24 Jun 2018 19:05:59 +0200 Subject: [PATCH] [fix] name of variable + fix of upgrade script --- bureau/class/m_ftp.php | 2 +- bureau/class/m_mail.php | 4 ++-- install/upgrades/3.5.0.1.sql | 9 +++++---- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/bureau/class/m_ftp.php b/bureau/class/m_ftp.php index 558f0631..74ec743d 100644 --- a/bureau/class/m_ftp.php +++ b/bureau/class/m_ftp.php @@ -33,7 +33,7 @@ class m_ftp { */ function m_ftp() { global $L_FQDN; - $this->srv_proftpd = variable_get('fqdn_proftpd', $L_FQDN, 'Human name for FTP server', array('desc' => 'Name', 'type' => 'string')); + $this->srv_proftpd = variable_get('fqdn_proftpd', $L_FQDN, 'Human name for FTP server. If you change it, launch reload-certs', array('desc' => 'Name', 'type' => 'string')); } diff --git a/bureau/class/m_mail.php b/bureau/class/m_mail.php index 9f6fdb8b..b7bc782f 100644 --- a/bureau/class/m_mail.php +++ b/bureau/class/m_mail.php @@ -72,8 +72,8 @@ class m_mail { */ function m_mail() { global $L_FQDN; - $this->srv_postfix = variable_get('fqdn_postfix', $L_FQDN, 'FQDN name for humans for smtp services', array('desc' => 'Name', 'type' => 'string')); - $this->srv_dovecot = variable_get('fqdn_dovecot', $L_FQDN, 'FQDN name for humans for pop/imap services', array('desc' => 'Name', 'type' => 'string')); + $this->srv_postfix = variable_get('fqdn_postfix', $L_FQDN, 'FQDN name for humans for smtp services. If you change it, launch reload-certs', array('desc' => 'Name', 'type' => 'string')); + $this->srv_dovecot = variable_get('fqdn_dovecot', $L_FQDN, 'FQDN name for humans for pop/imap services. If you change it, launch reload-certs', array('desc' => 'Name', 'type' => 'string')); } diff --git a/install/upgrades/3.5.0.1.sql b/install/upgrades/3.5.0.1.sql index 4044a77d..c057bc85 100644 --- a/install/upgrades/3.5.0.1.sql +++ b/install/upgrades/3.5.0.1.sql @@ -1,7 +1,8 @@ -- upgrade to merge alternc-ssl into alternc + change the way we work on SSL -DROP TABLE `certif_alias`; +DROP TABLE IF EXISTS `certif_alias`; + ALTER TABLE `certificates` DROP `shared`, DROP `ssl_action`, @@ -21,7 +22,7 @@ UPDATE `domaines_type` SET `has_https_option`=1 WHERE name='vhost'; -- Backport old certif_hosts data to sub_domaines UPDATE `sub_domaines` LEFT JOIN `certif_hosts` ON `sub_domaines`.`id` = `certif_hosts`.`sub` SET `sub_domaines`.`certificate_id` = `certif_hosts`.`certif` WHERE 1; -DROP TABLE `certif_hosts`; +DROP TABLE IF EXISTS `certif_hosts`; -- Set https status (http,https,both) UPDATE `sub_domaines` SET `https` = "https" WHERE `type` LIKE '%-ssl' AND https = ''; @@ -40,8 +41,8 @@ UPDATE sub_domaines AS sd INNER JOIN -- Delete duplicate lines DELETE sd1 FROM sub_domaines sd1, sub_domaines sd2 WHERE sd1.id > sd2.id AND sd1.domaine = sd2.domaine AND sd1.sub = sd2.sub AND sd1.type = sd2.type AND sd1.https <> '' AND sd2.https <> ''; --- Regenerate all vhost -UPDATE `sub_domaines` SET `web_action` = 'UPDATE'; +-- we need to regenerate all vhost, they will be by AlternC.install +-- UPDATE `sub_domaines` SET `web_action` = 'UPDATE'; -- change some variable names :