Sha256: 595eb3db0d2b533ead162c917a378a0e11755a37d9717b60c024a92d360b62c7
Contents?: true
Size: 974 Bytes
Versions: 8
Compression:
Stored size: 974 Bytes
Contents
module Glue # Add support for incoming mail handling. # # You need to setup your MTA to support incoming email # handling. Here is an example for Postfix. Edit these files: # # /etc/postfix/master.cf: # mailman unix - n n - - pipe # flags= user=nobody argv=/path/to/ruby /path/to/app/script/runner.rb Mailer.receive(STDIN) # # /etc/postfix/main.cf: # transport_maps = hash:/etc/postfix/transport # virtual_mailbox_domains = lists.yourdomain.com # # /etc/postfix/transport: # lists.yourdomain.com mailman: # # Then run: # # sudo postmap transport # sudo postfix stop # sudo postfix start module IncomingMailer on_included %{ base.extend ClassMethods } # You can overide this class for specialized handling. def receive(mail) end module ClassMethods def receive(encoded) mail = Glue::Mail.new_from_encoded(encoded) self.new.receive(mail) end end end end # * George Moschovitis <gm@navel.gr>
Version data entries
8 entries across 8 versions & 1 rubygems