You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by ma...@apache.org on 2019/06/17 19:58:23 UTC

[airavata] branch develop updated: AIRAVATA-2638 Separating error email recipients

This is an automated email from the ASF dual-hosted git repository.

machristie pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/airavata.git


The following commit(s) were added to refs/heads/develop by this push:
     new 92a2d19  AIRAVATA-2638 Separating error email recipients
92a2d19 is described below

commit 92a2d1913f8664a5e274774c4e4eaef23d440bca
Author: Marcus Christie <ma...@apache.org>
AuthorDate: Mon Jun 17 15:58:10 2019 -0400

    AIRAVATA-2638 Separating error email recipients
---
 .../ansible/inventories/scigap/develop/group_vars/django/vars.yml  | 1 +
 dev-tools/ansible/roles/django/defaults/main.yml                   | 1 +
 dev-tools/ansible/roles/django/templates/settings_local.py.j2      | 7 ++++++-
 3 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/dev-tools/ansible/inventories/scigap/develop/group_vars/django/vars.yml b/dev-tools/ansible/inventories/scigap/develop/group_vars/django/vars.yml
index 31a583f..9321d54 100644
--- a/dev-tools/ansible/inventories/scigap/develop/group_vars/django/vars.yml
+++ b/dev-tools/ansible/inventories/scigap/develop/group_vars/django/vars.yml
@@ -27,3 +27,4 @@ gateway_data_store_ssh_public_key: "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDWgLve
 django_wsgi_processes: 1
 doc_root_dir: "/data/portals/django-{{gateway_id}}"
 admin_emails: "[('SGRC Group', 'sgrc-iu-group@iu.edu')]"
+django_error_emails: "[('Marcus Christie', 'machrist@iu.edu')]"
diff --git a/dev-tools/ansible/roles/django/defaults/main.yml b/dev-tools/ansible/roles/django/defaults/main.yml
index 1472e5c..13323c7 100644
--- a/dev-tools/ansible/roles/django/defaults/main.yml
+++ b/dev-tools/ansible/roles/django/defaults/main.yml
@@ -45,6 +45,7 @@ django_extra_settings: {}
 django_wsgi_processes: 2
 
 django_debug: false
+django_error_emails: "{{ admin_emails }}"
 
 ## Keycloak related variables
 tenant_domain: "{{ gateway_id }}"
diff --git a/dev-tools/ansible/roles/django/templates/settings_local.py.j2 b/dev-tools/ansible/roles/django/templates/settings_local.py.j2
index 513eefe..a794ac7 100644
--- a/dev-tools/ansible/roles/django/templates/settings_local.py.j2
+++ b/dev-tools/ansible/roles/django/templates/settings_local.py.j2
@@ -49,7 +49,12 @@ EMAIL_PORT = {{ portal_email_port }}
 EMAIL_HOST_USER = '{{ portal_email_username }}'
 EMAIL_HOST_PASSWORD = '{{ portal_email_password }}'
 EMAIL_USE_TLS = {{ portal_email_tls | ternary("True", "False") }}
-ADMINS = {{ admin_emails }}
+# ADMINS receive error emails
+ADMINS = {{ django_error_emails }}
+# PORTAL_ADMINS receive administrative emails, like when a new user is created
+# This can be set to a different value than ADMINS so that the PORTAL_ADMINS
+# don't receive error emails
+PORTAL_ADMINS = {{ admin_emails }}
 SERVER_EMAIL = '{{ portal_server_email }}'
 
 # Keycloak Configuration