diff --git a/CHANGELOG.md b/CHANGELOG.md index 4580c18..cc8212a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), - [SECURITY] Additional Nginx directives to prevent access to log files or backup from web browser - [CORE] apt-mirror-updater to select the fastest debian/ubuntu mirror with automatic switching between mirrors if the current mirror is being updated - [SITE] add `--force` to force Let's Encrypt certificate issuance even if DNS check fail +- [STACK] check if another mta is installed before installing sendmail #### Changed diff --git a/wo/cli/plugins/stack.py b/wo/cli/plugins/stack.py index 5e16aca..956f9f5 100644 --- a/wo/cli/plugins/stack.py +++ b/wo/cli/plugins/stack.py @@ -265,11 +265,16 @@ class WOStackController(CementBaseController): # sendmail if pargs.sendmail: Log.debug(self, "Setting apt_packages variable for Sendmail") - if not WOAptGet.is_installed(self, 'sendmail'): + if (not WOAptGet.is_installed(self, 'sendmail') and + not WOAptGet.is_installed(self, 'postfix')): apt_packages = apt_packages + ["sendmail"] else: - Log.debug(self, "Sendmail already installed") - Log.info(self, "Sendmail already installed") + if WOAptGet.is_installed(self, 'sendmail'): + Log.debug(self, "Sendmail already installed") + Log.info(self, "Sendmail already installed") + else: + Log.debug(self, "Another mta is already installed") + Log.info(self, "Another mta is already installed") # proftpd if pargs.proftpd: