Add mailgun output

Add mailer to send email via the mailgun http api. This will allow users
to send emails alerts, without having to configure sendmail or some
equivalent.

Still need to create unit tests. I wanted to get this PR up if only for visibility and to ensure I don't forget.
Will do. I will take care of that and the doc change tomorrow.
On Sep 30, 2014 11:38 PM, "Pierre-Yves Ritschard" <notifications@github.com>
wrote:

> In src/riemann/mailgun.clj:
>
> > @@ -0,0 +1,90 @@
> > +;(ns riemann.mailgun
> > +  ;"Forwards events to Mailgun"
> > +  ;(:require [clj-http.client :as client]))
> > +(use 'aleph.http)
> > +(use '[riemann.common :only [body subject]])
> > +
> > +(def ^:private event-url
> > +  "https://api.mailgun.net/v2/%s/messages")
> > +
> > +(defn- post
> > +  "POST to the Mailgun events API."
> > +  [mgun-opts msg-opts]
> > +  (sync-http-request
>
> switching away from aleph only involves modifying this one call
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/aphyr/riemann/pull/447/files#r18263175>.
>