]> git.ozlabs.org Git - patchwork/commitdiff
notifications: Add NOTIFICATION_FROM_EMAIL setting
authorJeremy Kerr <jk@ozlabs.org>
Thu, 14 Apr 2011 03:25:47 +0000 (11:25 +0800)
committerJeremy Kerr <jk@ozlabs.org>
Thu, 14 Apr 2011 09:24:31 +0000 (17:24 +0800)
Allow a separate From: address for notificaton emails.

Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
apps/patchwork/utils.py
apps/settings.py
docs/INSTALL

index 94b3f53851613fdf244cf607e8df0892034ec76e..58edb194564f1f4167dbac2e338629ce61f90f5e 100644 (file)
@@ -181,7 +181,7 @@ def send_notifications():
                                 context)
 
         message = EmailMessage(subject = subject, body = content,
-                               from_email = settings.DEFAULT_FROM_EMAIL,
+                               from_email = settings.NOTIFICATION_FROM_EMAIL,
                                to = [recipient.email],
                                headers = {'Precedence': 'bulk'})
 
index d5595e01013054423519cd805e99f16f59f6fc4c..4432f3f04d7cbdf953e21d70bc87ba5b78d3cfa4 100644 (file)
@@ -104,6 +104,7 @@ DEFAULT_FROM_EMAIL = 'Patchwork <patchwork@patchwork.example.com>'
 CONFIRMATION_VALIDITY_DAYS = 7
 
 NOTIFICATION_DELAY_MINUTES = 10
+NOTIFICATION_FROM_EMAIL = DEFAULT_FROM_EMAIL
 
 # Set to True to enable the Patchwork XML-RPC interface
 ENABLE_XMLRPC = False
index 6a1a0bf6498ed46c9529bd902e41453c3e86dba8..050fc9f10a4cefcef22454967d2d234ee3326d30 100644 (file)
@@ -104,6 +104,8 @@ in brackets):
           ADMINS
           TIME_ZONE
           LANGUAGE_CODE
+          DEFAULT_FROM_EMAIL
+          NOTIFICATION_FROM_EMAIL
 
         You can generate the SECRET_KEY with the following python code: