|
|
|
@ -5043,6 +5043,29 @@ outdated. If the backup is obsolete, use cl-backup."))
|
|
|
|
|
"""
|
|
|
|
|
# Создаем переменные
|
|
|
|
|
self.createClVars()
|
|
|
|
|
# Настройка почты
|
|
|
|
|
if options.has_key("t"):
|
|
|
|
|
mailType = options['t']
|
|
|
|
|
if mailType:
|
|
|
|
|
if not set(mailType.split(",")) <= set(["imap","pop3"]):
|
|
|
|
|
self.printERROR(\
|
|
|
|
|
_("Мail type not 'imap' or 'pop3' or 'pop3,imap'"))
|
|
|
|
|
return False
|
|
|
|
|
if len(mailType.split(",")) == 2:
|
|
|
|
|
mailType = "all"
|
|
|
|
|
else:
|
|
|
|
|
self.printERROR(_("Мail type incorrect"))
|
|
|
|
|
return False
|
|
|
|
|
self.clVars.Set("sr_mail_type", mailType)
|
|
|
|
|
if options.has_key("c"):
|
|
|
|
|
mailCrypt = options['c']
|
|
|
|
|
if not mailCrypt in ["none", "tls"]:
|
|
|
|
|
self.printERROR(_("Мail encryption not 'none' or 'tls'"))
|
|
|
|
|
return False
|
|
|
|
|
if mailCrypt == "none":
|
|
|
|
|
mailCrypt = ""
|
|
|
|
|
self.clVars.Set("sr_mail_crypt", mailCrypt, True)
|
|
|
|
|
# История для jabber
|
|
|
|
|
if options.has_key("history"):
|
|
|
|
|
history = options["history"].strip()
|
|
|
|
|
if history in ("on", "off"):
|
|
|
|
@ -5115,11 +5138,21 @@ outdated. If the backup is obsolete, use cl-backup."))
|
|
|
|
|
if not self.startServices([service], False):
|
|
|
|
|
return False
|
|
|
|
|
self.printOK(_("Restarting service %s")%service.capitalize())
|
|
|
|
|
#запишем переменные для сервера
|
|
|
|
|
# запишем переменные для сервера
|
|
|
|
|
if not flagError:
|
|
|
|
|
self.clVars.Write("sr_jabber_history",
|
|
|
|
|
self.clVars.Get("sr_jabber_history"),
|
|
|
|
|
True,"local")
|
|
|
|
|
self.clVars.Write("sr_mail_type",
|
|
|
|
|
self.clVars.Get("sr_mail_type"),
|
|
|
|
|
True,"local")
|
|
|
|
|
self.clVars.Write("sr_mail_crypt",
|
|
|
|
|
self.clVars.Get("sr_mail_crypt"),
|
|
|
|
|
True,"local")
|
|
|
|
|
# запишем переменные для клиента
|
|
|
|
|
clientVars = ["sr_mail_type", "sr_mail_crypt"]
|
|
|
|
|
if not self.saveVarsClient(clientVars):
|
|
|
|
|
return False
|
|
|
|
|
if flagError:
|
|
|
|
|
return False
|
|
|
|
|
else:
|
|
|
|
@ -6383,6 +6416,20 @@ the password will be changed only for Samba account")
|
|
|
|
|
'help':_("enabled or disabled jabber history logging, default disable.\
|
|
|
|
|
(on/off)")
|
|
|
|
|
},
|
|
|
|
|
{'progAccess':(9,),
|
|
|
|
|
'shortOption':"t",
|
|
|
|
|
'optVal':"TYPE",
|
|
|
|
|
'longOption':"type",
|
|
|
|
|
'helpChapter':_("Mail service options"),
|
|
|
|
|
'help':_("mail type - 'imap', 'pop3', 'pop3,imap'")
|
|
|
|
|
},
|
|
|
|
|
{'progAccess':(9,),
|
|
|
|
|
'shortOption':"c",
|
|
|
|
|
'optVal':"CRYPT",
|
|
|
|
|
'longOption':"crypt",
|
|
|
|
|
'helpChapter':_("Mail service options"),
|
|
|
|
|
'help':_("encryption type - 'none', 'tls'")
|
|
|
|
|
},
|
|
|
|
|
{'progAccess':(9,10),
|
|
|
|
|
'shortOption':"v",
|
|
|
|
|
'longOption':"verbose",
|
|
|
|
|