Browse Source

Merge branch 'python' of github.com:rtCamp/easyengine into python

bugfixes
harshadyeola 10 years ago
parent
commit
2ca37c87b3
  1. 15
      ee/cli/plugins/stack.py
  2. 48
      ee/cli/templates/dovecot.mustache
  3. 8
      ee/core/variables.py

15
ee/cli/plugins/stack.py

@ -101,6 +101,18 @@ class EEStackController(CementBaseController):
else:
EERepo.add(ppa=EEVariables.ee_php_repo)
if set(EEVariables.ee_dovecot).issubset(set(apt_packages)):
if EEVariables.ee_platform_codename == 'squeeze':
print("Adding repository for dovecot ... ")
EERepo.add(repo_url=EEVariables.ee_dovecot_repo)
EEShellExec.cmd_exec("echo \"dovecot-core dovecot-core/"
"create-ssl-cert boolean yes\" "
"| debconf-set-selections")
EEShellExec.cmd_exec("echo \"dovecot-core dovecot-core/ssl-cert-"
"name string $(hostname -f)\""
" | debconf-set-selections")
@expose(hide=True)
def post_pref(self, apt_packages, packages):
if len(apt_packages):
@ -243,8 +255,7 @@ class EEStackController(CementBaseController):
pass
# apt_packages = apt_packages + EEVariables.ee_nginx
if self.app.pargs.mail:
pass
# apt_packages = apt_packages + EEVariables.ee_nginx
apt_packages = apt_packages + EEVariables.ee_dovecot
if self.app.pargs.nginx:
apt_packages = apt_packages + EEVariables.ee_nginx
if self.app.pargs.php:

48
ee/cli/templates/dovecot.mustache

@ -0,0 +1,48 @@
protocols = imap pop3 lmtp sieve
mail_location = maildir:/var/vmail/%d/%n
disable_plaintext_auth = no
auth_mechanisms = plain login
#!include auth-system.conf.ext
!include auth-sql.conf.ext
ssl_protocols = !SSLv2 !SSLv3
service lmtp {
unix_listener /var/spool/postfix/private/dovecot-lmtp {
mode = 0600
user = postfix
group = postfix
}
}
service auth {
unix_listener /var/spool/postfix/private/auth {
mode = 0666
user = postfix
group = postfix
}
unix_listener auth-userdb {
mode = 0600
user = vmail
}
user = dovecot
}
service auth-worker {
user = vmail
}
log_path = /var/log/dovecot.log
mail_plugins = $mail_plugins autocreate
plugin {
autocreate = Trash
autocreate2 = Junk
autocreate3 = Drafts
autocreate4 = Sent
autosubscribe = Trash
autosubscribe2 = Junk
autosubscribe3 = Drafts
autosubscribe4 = Sent
}

8
ee/core/variables.py

@ -39,6 +39,14 @@ class EEVariables():
ee_postfix_repo = ""
ee_postfix = ["postfix"]
# Dovecot repo and packages
ee_dovecot_repo = ("deb http://http.debian.net/debian-backports {codename}"
"-backports main".format(codename=ee_platform_codename))
ee_dovecot = ["dovecot-core", "dovecot-imapd", "dovecot-pop3d",
"dovecot-lmtpd", "dovecot-mysql", "dovecot-sieve",
"dovecot-managesieved"]
# Repo
ee_repo_file = "ee-repo.list"
ee_repo_file_path = ("/etc/apt/sources.list.d/" + ee_repo_file)

Loading…
Cancel
Save