Adam S.
Adam S.

Reputation: 306

Allauth emails coming from localhost instead of sendgrid account

I have set up django-allauth and everything is working but the emails generated, for example from reset password, come from localhost instead of the sender I want.

Our emails use sendgrid and send with the right sender when using the django.core.mail send_mail command in a tests emails

Is there a setting I am missing?

These are the ones I have (along with a sendgrid password):

EMAIL_HOST = 'smtp.sendgrid.net'
EMAIL_HOST_USER = '******' # This works in test emails
EMAIL_PORT = 587
EMAIL_USE_TLS = True

ACCOUNT_LOGIN_ATTEMPTS_LIMIT = 10
ACCOUNT_SIGNUP_FORM_CLASS = '******.views.SignupForm' 
ACCOUNT_AUTHENTICATION_METHOD = 'email'
ACCOUNT_EMAIL_REQUIRED = True
ACCOUNT_UNIQUE_EMAIL = True
ACCOUNT_USERNAME_REQUIRED = False
ACCOUNT_EMAIL_VERIFICATION = 'none'

Thank you!

Upvotes: 2

Views: 721

Answers (1)

Adam S.
Adam S.

Reputation: 306

the setting is DEFAULT_FROM_EMAIL

ie:

DEFAULT_FROM_EMAIL = "[email protected]"

Upvotes: 2

Related Questions