From fde06390ea7faa3e25fc47795c336e434fc07f2b Mon Sep 17 00:00:00 2001 From: Disassembler Date: Sat, 3 Feb 2018 13:42:32 +0100 Subject: [PATCH] Integrate Sahana with postfix --- sahana.sh | 1 + sahana/etc/init.d/sahana | 3 ++- sahana/srv/sahana/conf/000_config.py | 2 +- sambro.sh | 1 + sambro/etc/init.d/sambro | 3 ++- sambro/srv/sambro/conf/000_config.py | 2 +- 6 files changed, 8 insertions(+), 4 deletions(-) diff --git a/sahana.sh b/sahana.sh index 90fb366..7d269a3 100755 --- a/sahana.sh +++ b/sahana.sh @@ -3,6 +3,7 @@ SOURCE_DIR=$(realpath $(dirname "${0}"))/sahana # Check prerequisites +docker image ls | grep -q postfix || $(realpath $(dirname "${0}"))/postfix.sh docker image ls | grep -q postgres || $(realpath $(dirname "${0}"))/postgres.sh # Build Docker container diff --git a/sahana/etc/init.d/sahana b/sahana/etc/init.d/sahana index 02f64a7..64bdc87 100755 --- a/sahana/etc/init.d/sahana +++ b/sahana/etc/init.d/sahana @@ -4,7 +4,7 @@ description="Sahana Eden docker container" depend() { need docker net - use dns logger netmount + use dns logger netmount postfix after postgres } @@ -12,6 +12,7 @@ start() { /usr/bin/docker run -d --rm \ --name sahana \ -h sahana \ + --link postfix \ --link postgres \ -p 127.0.0.1:8001:8001 \ -v /srv/sahana/conf:/srv/web2py/applications/eden/models \ diff --git a/sahana/srv/sahana/conf/000_config.py b/sahana/srv/sahana/conf/000_config.py index 2bb6f01..77eb7b7 100644 --- a/sahana/srv/sahana/conf/000_config.py +++ b/sahana/srv/sahana/conf/000_config.py @@ -92,7 +92,7 @@ settings.auth.hmac_key = "${SAHANA_HMAC}" # Email settings # Outbound server -settings.mail.server = "postfix:587" +settings.mail.server = "postfix:25" #settings.mail.tls = True # Useful for Windows Laptops: # https://www.google.com/settings/security/lesssecureapps diff --git a/sambro.sh b/sambro.sh index a141af6..2366d50 100755 --- a/sambro.sh +++ b/sambro.sh @@ -3,6 +3,7 @@ SOURCE_DIR=$(realpath $(dirname "${0}"))/sambro # Check prerequisites +docker image ls | grep -q postfix || $(realpath $(dirname "${0}"))/postfix.sh docker image ls | grep -q postgres || $(realpath $(dirname "${0}"))/postgres.sh docker image ls | grep -q sahana || docker build -t sahana $(realpath $(dirname "${0}"))/sahana diff --git a/sambro/etc/init.d/sambro b/sambro/etc/init.d/sambro index 58bbbd2..7f4c7fc 100755 --- a/sambro/etc/init.d/sambro +++ b/sambro/etc/init.d/sambro @@ -4,7 +4,7 @@ description="SAMBRO docker container" depend() { need docker net - use dns logger netmount + use dns logger netmount postfix after postgres } @@ -12,6 +12,7 @@ start() { /usr/bin/docker run -d --rm \ --name sambro \ -h sambro \ + --link postfix \ --link postgres \ -p 127.0.0.1:8099:8001 \ -v /srv/sambro/conf:/srv/web2py/applications/eden/models \ diff --git a/sambro/srv/sambro/conf/000_config.py b/sambro/srv/sambro/conf/000_config.py index ebb90c4..cb18639 100644 --- a/sambro/srv/sambro/conf/000_config.py +++ b/sambro/srv/sambro/conf/000_config.py @@ -92,7 +92,7 @@ settings.auth.hmac_key = "${SAMBRO_HMAC}" # Email settings # Outbound server -settings.mail.server = "postfix:587" +settings.mail.server = "postfix:25" #settings.mail.tls = True # Useful for Windows Laptops: # https://www.google.com/settings/security/lesssecureapps