aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers/action_mailbox/ingresses/postfix/inbound_emails_controller.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/controllers/action_mailbox/ingresses/postfix/inbound_emails_controller.rb')
-rw-r--r--app/controllers/action_mailbox/ingresses/postfix/inbound_emails_controller.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/app/controllers/action_mailbox/ingresses/postfix/inbound_emails_controller.rb b/app/controllers/action_mailbox/ingresses/postfix/inbound_emails_controller.rb
new file mode 100644
index 0000000000..2631302606
--- /dev/null
+++ b/app/controllers/action_mailbox/ingresses/postfix/inbound_emails_controller.rb
@@ -0,0 +1,11 @@
+class ActionMailbox::Ingresses::Postfix::InboundEmailsController < ActionMailbox::BaseController
+ cattr_accessor :username, default: "actionmailbox"
+ cattr_accessor :password
+
+ before_action :authenticate
+
+ def create
+ ActionMailbox::InboundEmail.create_and_extract_message_id! params.require(:message)
+ head :no_content
+ end
+end