Make cloud email domain configurable (#4982)
# What this PR does Fixes https://github.com/grafana/oncall-private/issues/2889 ## Checklist - [x] Unit, integration, and e2e (if applicable) tests updated - [x] Documentation added (or `pr:no public docs` PR label added if not required) - [x] Added the relevant release notes label (see labels prefixed w/ `release:`). These labels dictate how your PR will show up in the autogenerated release notes.
This commit is contained in:
parent
392fa4c52c
commit
bb2113db58
2 changed files with 2 additions and 1 deletions
|
|
@ -21,7 +21,7 @@ def get_from_email(user):
|
|||
return live_settings.EMAIL_FROM_ADDRESS
|
||||
|
||||
if settings.LICENSE == settings.CLOUD_LICENSE_NAME:
|
||||
return "oncall@{}.grafana.net".format(user.organization.stack_slug)
|
||||
return "oncall@{}.{}".format(user.organization.stack_slug, settings.EMAIL_FROM_DOMAIN)
|
||||
|
||||
return live_settings.EMAIL_HOST_USER
|
||||
|
||||
|
|
|
|||
|
|
@ -844,6 +844,7 @@ EMAIL_PORT = getenv_integer("EMAIL_PORT", 587)
|
|||
EMAIL_USE_TLS = getenv_boolean("EMAIL_USE_TLS", True)
|
||||
EMAIL_USE_SSL = getenv_boolean("EMAIL_USE_SSL", False)
|
||||
EMAIL_FROM_ADDRESS = os.getenv("EMAIL_FROM_ADDRESS")
|
||||
EMAIL_FROM_DOMAIN = os.getenv("EMAIL_FROM_DOMAIN", "grafana.net")
|
||||
EMAIL_NOTIFICATIONS_LIMIT = getenv_integer("EMAIL_NOTIFICATIONS_LIMIT", 200)
|
||||
|
||||
EMAIL_BACKEND_INTERNAL_ID = 8
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue