artefactual/archivematica-storage-service — pull request #17 by mistydemeo (2014-06-12 00:32:04+00:00)
Title: Add email notification for deletion requests, fixity failures

This adds email notifications to a couple of events: AIP deletion requests, and fixity check failures.

The storage service will send emails to every user account with superuser privileges, are the accounts with permission to do things like approve AIP deletion. It's implemented using Django signals, and a new `signals` module had been added to `locations`.

It uses Django's email support; in order for it to work, the email server and authentication information to use must be configured in Django's settings files (or in environment variables). If email isn't configured, then these signals won't send an email (they'll print the message they would have sent to stdout instead).

Django is not configured with a way to get the site's URL by default; in order for the AIP deletion request to provide a URL, this must be configured with the SITE_BASE_URL config setting, with a value similar to "http://example.com". If that parameter is omitted, then the AIP deletion request email won't include a link to the page where requests can be approved or denied.