diff --git a/sefaria/settings.py b/sefaria/settings.py index bee97b9c3f..a377fba9ed 100644 --- a/sefaria/settings.py +++ b/sefaria/settings.py @@ -1,7 +1,10 @@ # Django settings for sefaria project. - +import os import os.path from django.utils.translation import ugettext_lazy as _ +from dotenv import load_dotenv + +load_dotenv() relative_to_abs_path = lambda *x: os.path.join(os.path.dirname( os.path.realpath(__file__)), *x) @@ -365,4 +368,11 @@ } DATA_UPLOAD_MAX_MEMORY_SIZE = 24000000 -BASE_DIR = os.path.dirname(os.path.dirname(__file__)) \ No newline at end of file +BASE_DIR = os.path.dirname(os.path.dirname(__file__)) + +EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend' +EMAIL_HOST = 'smtp.gmail.com' +EMAIL_PORT = 587 +EMAIL_HOST_USER = os.getenv("EMAIL_HOST_USER") +EMAIL_HOST_PASSWORD = os.getenv("EMAIL_HOST_PASSWORD") # Use the app password you generated +EMAIL_USE_TLS = True diff --git a/templates/registration/password_reset_email.html b/templates/registration/password_reset_email.html index b0c071dd77..b0cc597d1a 100644 --- a/templates/registration/password_reset_email.html +++ b/templates/registration/password_reset_email.html @@ -1,7 +1,7 @@ {% load i18n %} -
{% trans "A request has been made to reset the password for this email address on Sefaria.org." %}
+{% trans "A request has been made to reset the password for this email address on Pecha.org." %}
{% trans "Click this link, or copy it to your browser, to choose a new password:" %}
diff --git a/templates/registration/password_reset_email.txt b/templates/registration/password_reset_email.txt index fd83967c33..07eaa8913b 100644 --- a/templates/registration/password_reset_email.txt +++ b/templates/registration/password_reset_email.txt @@ -1,6 +1,6 @@ {% load i18n %} -{% trans "A request has been made to reset the password for this email address on Sefaria.org." %} +{% trans "A request has been made to reset the password for this email address on Pecha.org." %} {% trans "Click this link, or copy it to your browser, to choose a new password:" %} diff --git a/templates/registration/password_reset_subject.txt b/templates/registration/password_reset_subject.txt index 750e4ec84b..a1ffddba8b 100644 --- a/templates/registration/password_reset_subject.txt +++ b/templates/registration/password_reset_subject.txt @@ -1,3 +1,3 @@ {% load i18n %}{% autoescape off %} -{% trans "Sefaria.org Password Reset" %} +{% trans "Pecha.org Password Reset" %} {% endautoescape %} \ No newline at end of file