chrisspen/django-chroniker

Custom Email System

Closed this issue · 2 comments

fechu commented

We are using a custom system for sending emails. We would therefore also like to use that with Chroniker to get the notifications about failed runs. The idea is to add a further setting that allows the user to define a send_mail method that accepts the same parameters as send_mail from Django. If it is set that one is used instead of the one from Django.

I'm willing to implement this functionality. Are you interested in merging that functionality into chroniker?

I'm looking forward to feedback as well as different approaches to the problem.

What do you mean by "custom system"? Chroniker uses Django's standard send_mail() interface for email notifications. The way to customize that is to implement your own subclass of Django's EmailBackend and set that in your EMAIL_BACKEND setting. That requires no modification to Chroniker.

fechu commented

Oh that's perfect! I didn't know about that. Obviously I was not looking deep enough into how Django handles emails. I'll go the way to write a custom Email backend.