User Controls
ISS email server
-
2019-02-21 at 5:22 PM UTCJust curious, what email server was set up on this deployment? Just a local SMTP?
At the minute the github seems to send emails to locmem by default, and I have no idea how to read them. The documentation says that "the 'locmem' backend stores messages in a special attribute of the django.core.mail module. It’s a list with an EmailMessage instance for each message that would be sent."
I'm guessing that is all Python/Django stuff.
Is sending emails using something like Mailgun or SendGrid a more portable alternative to setting up a local email server? -
2019-02-21 at 8:21 PM UTCUnfortunately running an SMTP server that actually does what you want is kind of a black art. I've written an SMTP server before, it's not that it's particularly technically challenging, the problem is that out of necessity novel hosts are considered spam by most reputable nodes. Like if I ran a SMTP server on the machine that hosts the site, google/MS/yahoo would spamcan everything. I don't even know what the process for getting considered a non-spammer is but it's not an ordeal I want to undergo.
As a result, in production I'm using gandi's SMTP server, gandi being the registrar for the domain. Mailgun and sendgrid are also options to get around trust issues in the SMTP ecosystem and are probably better than Gandi's service since their business model depends on their outbound email not getting trashed.
For local development I suggest adding this to your settings file:
EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'
The locmem backend is nice for unit testing because you can programmatically inspect emails, but for development that one will print out emails to stdout while the dev server is running which makes it easier to inspect them manually. -
2019-02-21 at 8:42 PM UTCISIS
-
2019-02-21 at 8:44 PM UTC
Originally posted by Lanny Unfortunately running an SMTP server that actually does what you want is kind of a black art. I've written an SMTP server before, it's not that it's particularly technically challenging, the problem is that out of necessity novel hosts are considered spam by most reputable nodes. Like if I ran a SMTP server on the machine that hosts the site, google/MS/yahoo would spamcan everything. I don't even know what the process for getting considered a non-spammer is but it's not an ordeal I want to undergo.
As a result, in production I'm using gandi's SMTP server, gandi being the registrar for the domain. Mailgun and sendgrid are also options to get around trust issues in the SMTP ecosystem and are probably better than Gandi's service since their business model depends on their outbound email not getting trashed.
For local development I suggest adding this to your settings file:
EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'
The locmem backend is nice for unit testing because you can programmatically inspect emails, but for development that one will print out emails to stdout while the dev server is running which makes it easier to inspect them manually.
Google apps works just as well, it's cheaper and you do get more out of it. -
2019-02-22 at 12:17 AM UTCYou can easily run a full-fledged SMTP server right off your own box.
-
2019-02-22 at 12:28 AM UTC
Originally posted by Lanny Unfortunately running an SMTP server that actually does what you want is kind of a black art. I've written an SMTP server before, it's not that it's particularly technically challenging, the problem is that out of necessity novel hosts are considered spam by most reputable nodes. Like if I ran a SMTP server on the machine that hosts the site, google/MS/yahoo would spamcan everything. I don't even know what the process for getting considered a non-spammer is but it's not an ordeal I want to undergo.
As a result, in production I'm using gandi's SMTP server, gandi being the registrar for the domain. Mailgun and sendgrid are also options to get around trust issues in the SMTP ecosystem and are probably better than Gandi's service since their business model depends on their outbound email not getting trashed.
For local development I suggest adding this to your settings file:
EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'
The locmem backend is nice for unit testing because you can programmatically inspect emails, but for development that one will print out emails to stdout while the dev server is running which makes it easier to inspect them manually.
I actually might try with the backend that outputs email to the filesystem. I have a weird system due to still being on BASH on Windows. Next lappy will be a decent Linux one hopefully.