Catches mail and serves it through a dream.

Overview

MailCatcher

Catches mail and serves it through a dream.

MailCatcher runs a super simple SMTP server which catches any message sent to it to display in a web interface. Run mailcatcher, set your favourite app to deliver to smtp://127.0.0.1:1025 instead of your default SMTP server, then check out http://127.0.0.1:1080 to see the mail that's arrived so far.

MailCatcher screenshot

Features

  • Catches all mail and stores it for display.
  • Shows HTML, Plain Text and Source version of messages, as applicable.
  • Rewrites HTML enabling display of embedded, inline images/etc and opens links in a new window.
  • Lists attachments and allows separate downloading of parts.
  • Download original email to view in your native mail client(s).
  • Command line options to override the default SMTP/HTTP IP and port settings.
  • Mail appears instantly if your browser supports WebSockets, otherwise updates every thirty seconds.
  • Runs as a daemon in the background, optionally in foreground.
  • Sendmail-analogue command, catchmail, makes using mailcatcher from PHP a lot easier.
  • Keyboard navigation between messages

How

  1. gem install mailcatcher
  2. mailcatcher
  3. Go to http://127.0.0.1:1080/
  4. Send mail through smtp://127.0.0.1:1025

Use mailcatcher --help to see the command line options. The brave can get the source from the GitHub repository.

Ruby

If you have trouble with the above commands, make sure you have Ruby installed:

ruby -v
gem environment

You might need to install build tools for some of the gem dependencies. On Debian or Ubuntu, apt install build-essential. On macOS, xcode-select --install.

If you encounter issues installing thin, try:

gem install thin -v 1.5.1 -- --with-cflags="-Wno-error=implicit-function-declaration"

Bundler

Please don't put mailcatcher into your Gemfile. It will conflict with your applications gems at some point.

Instead, pop a note in your README stating you use mailcatcher, and to run gem install mailcatcher then mailcatcher to get started.

RVM

Under RVM your mailcatcher command may only be available under the ruby you install mailcatcher into. To prevent this, and to prevent gem conflicts, install mailcatcher into a dedicated gemset with a wrapper script:

rvm default@mailcatcher --create do gem install mailcatcher
ln -s "$(rvm default@mailcatcher do rvm wrapper show mailcatcher)" "$rvm_bin_path/"

Rails

To set up your rails app, I recommend adding this to your environments/development.rb:

config.action_mailer.delivery_method = :smtp
config.action_mailer.smtp_settings = { :address => '127.0.0.1', :port => 1025 }
config.action_mailer.raise_delivery_errors = false

PHP

For projects using PHP, or PHP frameworks and application platforms like Drupal, you can set PHP's mail configuration in your php.ini to send via MailCatcher with:

sendmail_path = /usr/bin/env catchmail -f [email protected]

You can do this in your Apache configuration like so:

php_admin_value sendmail_path "/usr/bin/env catchmail -f [email protected]"

If you've installed via RVM this probably won't work unless you've manually added your RVM bin paths to your system environment's PATH. In that case, run which catchmail and put that path into the sendmail_path directive above instead of /usr/bin/env catchmail.

If starting mailcatcher on alternative SMTP IP and/or port with parameters like --smtp-ip 192.168.0.1 --smtp-port 10025, add the same parameters to your catchmail command:

sendmail_path = /usr/bin/env catchmail --smtp-ip 192.160.0.1 --smtp-port 10025 -f [email protected]

Django

For use in Django, add the following configuration to your projects' settings.py

if DEBUG:
    EMAIL_HOST = '127.0.0.1'
    EMAIL_HOST_USER = ''
    EMAIL_HOST_PASSWORD = ''
    EMAIL_PORT = 1025
    EMAIL_USE_TLS = False

API

A fairly RESTful URL schema means you can download a list of messages in JSON from /messages, each message's metadata with /messages/:id.json, and then the pertinent parts with /messages/:id.html and /messages/:id.plain for the default HTML and plain text version, /messages/:id/:cid for individual attachments by CID, or the whole message with /messages/:id.source.

Caveats

  • Mail processing is fairly basic but easily modified. If something doesn't work for you, fork and fix it or file an issue and let me know. Include the whole message you're having problems with.
  • Encodings are difficult. MailCatcher does not completely support utf-8 straight over the wire, you must use a mail library which encodes things properly based on SMTP server capabilities.

Thanks

MailCatcher is just a mishmash of other people's hard work. Thank you so much to the people who have built the wonderful guts on which this project relies.

Donations

I work on MailCatcher mostly in my own spare time. If you've found Mailcatcher useful and would like to help feed me and fund continued development and new features, please donate via PayPal. If you'd like a specific feature added to MailCatcher and are willing to pay for it, please email me.

License

Copyright © 2010-2019 Samuel Cochran ([email protected]). Released under the MIT License, see LICENSE for details.

Comments
  • Mail catching smtp timeout when running in background

    Mail catching smtp timeout when running in background

    Hi Guys,

    I have a very strange issue but I do not how I could debug it any further.

    1, if I run mailcatcher in the foreground -f -v

    a, web interface works perfectly b, smtp receives emails flawlessly

    2, if I run it in the backgroud

    a, web interface works b, smtp interface does not respond.

    Dec 22 12:34:24 sendemail[10247]: ERROR => Timeout while reading from localhost:2525 There was no response after 60 seconds.

    If I want to telnet into it I CAN!

    It is not a port issue as I run the test on the same computer and when it is in foreground mode it works.

    I do not see any error logs anywhere. is there a way to enable some debug mode so that I can see why the smtp timeouts ?

    Any idea what can be wrong ?

    my ruby version is -> ruby 1.9.3p547 (2014-05-14 revision 45962) [x86_64-linux] my mailcatcher version is mailcatcher (0.5.12)

    My local gems: *** LOCAL GEMS ***

    activesupport (3.2.19) bigdecimal (1.1.0) builder (3.2.2) bundler (1.5.3) chef (11.16.4) chef-zero (2.2) coderay (1.1.0) daemons (1.1.9) diff-lcs (1.2.5) docile (1.1.5) erubis (2.7.0) eventmachine (1.0.4) ffi (1.9.5) ffi-yajl (1.1.0) haml (4.0.6) hashie (2.1.2) highline (1.6.21) i18n (0.6.11) io-console (0.3) ipaddress (0.8.0) json (1.8.1, 1.5.5) libyajl2 (1.0.1) mail (2.6.3) mailcatcher (0.5.12) method_source (0.8.2) mime-types (1.25.1) minitest (2.5.1) mixlib-authentication (1.3.0) mixlib-cli (1.5.0) mixlib-config (2.1.0) mixlib-log (1.6.0) mixlib-shellout (1.6.0) multi_json (1.10.1) mysql (2.9.1) net-ssh (2.9.1) net-ssh-gateway (1.2.0) net-ssh-multi (1.2.0) ohai (7.4.0) plist (3.1.0) pry (0.10.1) rack (1.5.2) rack-protection (1.5.3) rake (10.1.1, 0.9.2.2) rdoc (3.9.5) rest-client (1.6.7) rspec (2.14.1) rspec-core (2.14.8) rspec-expectations (2.14.5) rspec-mocks (2.14.6) rspec_junit_formatter (0.1.6) ruby-shadow (2.3.4) simplecov (0.9.1) simplecov-html (0.8.0) sinatra (1.4.5) skinny (0.2.3) slop (3.6.0) sqlite3 (1.3.10) systemu (2.6.4) thin (1.5.1) tilt (1.4.1) wmi-lite (1.0.0)

    opened by istvano 53
  • Memory leak

    Memory leak

    Hi,

    it seams that mailcatcher leaks a lot of memory. I've started it, and just reloading the page (without any mails in it) adds about 500kB to the process size:

    $ sv restart ./service/mailcatcher
    ok: run: ./service/mailcatcher: (pid 22424) 0s
    $ ps auxww | grep [m]ailcatcher # after each reload
    danielt  22424 33.3  4.5 135972 47032 ?        Sl   15:44   0:01 /home/danielt/.rvm/rubies/ruby-2.1.0/bin/ruby /home/danielt/.rvm/gems/ruby-2.1.0/bin/mailcatcher --foreground --smtp-ip 0.0.0.0 --http-port 4080
    danielt  22424 15.0  4.8 140292 49736 ?        Sl   15:44   0:01 /home/danielt/.rvm/rubies/ruby-2.1.0/bin/ruby /home/danielt/.rvm/gems/ruby-2.1.0/bin/mailcatcher --foreground --smtp-ip 0.0.0.0 --http-port 4080
    danielt  22424  9.8  4.8 140700 49980 ?        Sl   15:44   0:01 /home/danielt/.rvm/rubies/ruby-2.1.0/bin/ruby /home/danielt/.rvm/gems/ruby-2.1.0/bin/mailcatcher --foreground --smtp-ip 0.0.0.0 --http-port 4080
    danielt  22424  7.7  4.9 141268 50508 ?        Sl   15:44   0:01 /home/danielt/.rvm/rubies/ruby-2.1.0/bin/ruby /home/danielt/.rvm/gems/ruby-2.1.0/bin/mailcatcher --foreground --smtp-ip 0.0.0.0 --http-port 4080
    danielt  22424  6.5  4.9 141700 51036 ?        Sl   15:44   0:01 /home/danielt/.rvm/rubies/ruby-2.1.0/bin/ruby /home/danielt/.rvm/gems/ruby-2.1.0/bin/mailcatcher --foreground --smtp-ip 0.0.0.0 --http-port 4080
    danielt  22424  5.1  5.0 142260 51564 ?        Sl   15:44   0:01 /home/danielt/.rvm/rubies/ruby-2.1.0/bin/ruby /home/danielt/.rvm/gems/ruby-2.1.0/bin/mailcatcher --foreground --smtp-ip 0.0.0.0 --http-port 4080
    danielt  22424  4.4  5.0 142676 52092 ?        Sl   15:44   0:01 /home/danielt/.rvm/rubies/ruby-2.1.0/bin/ruby /home/danielt/.rvm/gems/ruby-2.1.0/bin/mailcatcher --foreground --smtp-ip 0.0.0.0 --http-port 4080
    danielt  22424  4.0  5.1 143220 52620 ?        Sl   15:44   0:01 /home/danielt/.rvm/rubies/ruby-2.1.0/bin/ruby /home/danielt/.rvm/gems/ruby-2.1.0/bin/mailcatcher --foreground --smtp-ip 0.0.0.0 --http-port 4080
    danielt  22424  3.7  5.1 143780 53124 ?        Sl   15:44   0:01 /home/danielt/.rvm/rubies/ruby-2.1.0/bin/ruby /home/danielt/.rvm/gems/ruby-2.1.0/bin/mailcatcher --foreground --smtp-ip 0.0.0.0 --http-port 4080
    

    As you can see something around 500kB is added after each request to the RSS.

    opened by datamuc 49
  • utf-8 encoding of source

    utf-8 encoding of source

    MailCatcher will crash when click on an email message including unicode characters.

    /var/lib/gems/1.9.1/gems/activesupport-4.2.0/lib/active_support/core_ext/object/json.rb:34:in `encode': "\xE2" from ASCII-8BIT to UTF-8 (Encoding::UndefinedConversionError)

    Some debugging shows that MailCatcher stores the message source as BLOB data type in SQLITE3, while according to https://github.com/sparklemotion/sqlite3-ruby/blob/b73fae5a4c515cbe2bbcf2bb01be4f8edd86d4b8/ext/sqlite3/database.c line 284, BLOB data are encoded to string using "rb_tainted_str_new", which creates string with ASCII-8BIT (BINARY) encoding. Therefore, the json encoder will get have an error when trying to encode unicode characters from ASCII-8BIT to UTF-8.

    force_encode message["source"] using UTF-8 fixed the issue.

    opened by nanshu 38
  • Use MidiSmtpServer for incoming SMTP Service - Enables AUTH and STARTTLS

    Use MidiSmtpServer for incoming SMTP Service - Enables AUTH and STARTTLS

    • allows optional TLS and AUTH for SMTP Clients
    • SSL cert will be generated temporarily
    • all auth credentials will be accepted

    I hope this will make it in your project. It helps to test and work also with clients that send only via SSL/TLS or needs an authentification.

    Thanks for any comments Tom

    opened by TomFreudenberg 35
  • `method_missing': undefined method `this' for #<Gem::Specification:0x3fc56a02c2bc activesupport-4.2.5.1> (NoMethodError)

    `method_missing': undefined method `this' for # (NoMethodError)

    I have installed both mailcatcher versions 0.6.3 and 0.6.1.

    When I run the command mailcatcher, I get the following error:

    /Users/jquigl44/.rvm/rubies/ruby-2.2.2/lib/ruby/site_ruby/2.2.0/rubygems/specification.rb:2159:in `method_missing': undefined method `this' for #<Gem::Specification:0x3fc0e842c3fc activesupport-4.2.5.1> (NoMethodError)
        from /Users/jquigl44/.rvm/rubies/ruby-2.2.2/lib/ruby/site_ruby/2.2.0/rubygems/specification.rb:1057:in `find_active_stub_by_path'
        from /Users/jquigl44/.rvm/rubies/ruby-
    . . .
        from /Users/jquigl44/.rvm/gems/ruby-2.2.2@avant_basic/bin/ruby_executable_hooks:15:in `<main>'
    

    Please help.

    opened by jayqui 35
  • Net::SMTPFatalError (550 Message rejected)

    Net::SMTPFatalError (550 Message rejected)

    I'm having an issue on my machine that my other developers aren't getting with the exact same code base. When sending via smtp in Rails and using mail catcher I'm getting 550s. The mail does show up in mailcatcher, however, it looks like a mime attachment instead of an html message.

    $ mailcatcher -f -v                                                                                                                                                                                                                                           Starting MailCatcher                                                                                                                                                                                                                                          ==> smtp://127.0.0.1:1025                                                                                                                                                                                                                                     ==> http://127.0.0.1:1080                                                                                                                                                                                                                                     *** Error receiving message: {:sender=>"<[email protected]>", :recipients=>["<m                                                                                                                                                                              [email protected]>"], :source=>""}                                                                                                                                                                                                                                        Exception: undefined method `match' for nil:NilClass                                                                                                                                                                                                          Backtrace:                                                                                                                                                                                                                                                       /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/mail-2.4.4/lib/mail/utilities.rb:104:in `unbracket'                                                                                                                                  
           /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/mail-2.4.4/lib/mail/part.rb:29:in `cid'                                                                                                                                              
           /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/mailcatcher-0.5.10/lib/mail_catcher/mail.rb:51:in `block in add_message'                                                                                                             
           /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/mailcatcher-0.5.10/lib/mail_catcher/mail.rb:48:in `each'                                                                                                                             
           /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/mailcatcher-0.5.10/lib/mail_catcher/mail.rb:48:in `add_message'                                                                                                                      
           /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/mailcatcher-0.5.10/lib/mail_catcher/smtp.rb:45:in `receive_message'                                                                                                                  
           /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/eventmachine-1.0.0/lib/em/protocols/smtpserver.rb:532:in `process_data_line'                                                                                                         
           /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/eventmachine-1.0.0/lib/em/protocols/smtpserver.rb:196:in `receive_line'                                                                                                              
           /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/eventmachine-1.0.0/lib/em/protocols/linetext2.rb:64:in `receive_data'                                                                                                                
           /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/eventmachine-1.0.0/lib/eventmachine.rb:187:in `run_machine'                                                                                                                                     /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/eventmachine-1.0.0/lib/eventmachine.rb:187:in `run'                                                                                                                                             /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/mailcatcher-0.5.10/lib/mail_catcher.rb:134:in `run!'                                                                                                                                            /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/gems/mailcatcher-0.5.10/bin/mailcatcher:4:in `<top (required)>'                                                                                                                                      /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/bin/mailcatcher:19:in `load'                                                                                                                                                                         /Users/matt/.rvm/gems/ruby-1.9.3-p194@merchant_messaging/bin/mailcatcher:19:in `<main>'               
    

    .

    opened by mmrobins 34
  • mailcatcher failed to start

    mailcatcher failed to start

    Following the installation instructions I get this error on Ubuntu 12.04 and Ubuntu 14.04:

    $ mailcatcher 
    /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- i18n/core_ext/string/interpolate (LoadError)
        from /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /opt/rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/activesupport-3.2.19/lib/active_support/core_ext/string/interpolation.rb:2:in `<top (required)>'
        from /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /opt/rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/activesupport-3.2.19/lib/active_support/core_ext/string.rb:9:in `<top (required)>'
        from /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /opt/rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/activesupport-3.2.19/lib/active_support/core_ext.rb:2:in `block in <top (required)>'
        from /opt/rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/activesupport-3.2.19/lib/active_support/core_ext.rb:1:in `each'
        from /opt/rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/activesupport-3.2.19/lib/active_support/core_ext.rb:1:in `<top (required)>'
        from /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /opt/rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/mailcatcher-0.5.12/lib/mail_catcher.rb:1:in `<top (required)>'
        from /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /opt/rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /opt/rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/mailcatcher-0.5.12/bin/mailcatcher:3:in `<top (required)>'
        from /opt/rbenv/versions/2.1.2/bin/mailcatcher:23:in `load'
        from /opt/rbenv/versions/2.1.2/bin/mailcatcher:23:in `<main>'
    

    List of installed gems:

    $ gem list --local
    
    *** LOCAL GEMS ***
    
    activesupport (3.2.19)
    bigdecimal (1.2.4)
    bundler (1.6.1)
    daemons (1.1.9)
    eventmachine (1.0.3)
    haml (4.1.0.beta.1)
    i18n (0.7.0.beta1)
    io-console (0.4.2)
    json (1.8.1)
    mail (2.6.1)
    mailcatcher (0.5.12)
    mime-types (2.3)
    minitest (4.7.5)
    multi_json (1.10.1)
    psych (2.0.5)
    rack (1.6.0.beta)
    rack-protection (1.5.3)
    rake (10.1.0)
    rdoc (4.1.0)
    sinatra (1.4.5)
    skinny (0.2.3)
    sqlite3 (1.3.9)
    test-unit (2.1.2.0)
    thin (1.5.1)
    tilt (1.4.1)
    

    Any ideas?

    opened by kforsthoevel 31
  • Failed to build gem native extension on Linux with no explanation

    Failed to build gem native extension on Linux with no explanation

    Hi There,

    I'm using vagrant with Ubuntu 14.04 LTS (Trusty Tahr) and have installed sqlite3-dev. When I try to install mailcatcher, the installation fails and I don't get a nice debug message telling me what went wrong. So I'm posting what happened here in hopes that someone will be able to help me out. Thanks!

    Here's what happened with the gem installer

    vagrant@vvv:~$ sudo gem install mailcatcher
    Building native extensions.  This could take a while...
    ERROR:  Error installing mailcatcher:
            ERROR: Failed to build gem native extension.
    
            /usr/bin/ruby1.9.1 extconf.rb
    
    Gem files will remain installed in /var/lib/gems/1.9.1/gems/eventmachine-1.0.3 for inspection.
    Results logged to /var/lib/gems/1.9.1/gems/eventmachine-1.0.3/ext/gem_make.out
    vagrant@vvv:~$ cat /var/lib/gems/1.9.1/gems/eventmachine-1.0.3/ext/gem_make.out 
    /usr/bin/ruby1.9.1 extconf.rb
    

    Here's what happened when I tried to install from source

    vagrant@vvv:~/mailcatcher$ gem build mailcatcher.gemspec 
      Successfully built RubyGem
      Name: mailcatcher
      Version: 0.6.0
      File: mailcatcher-0.6.0.gem
    vagrant@vvv:~/mailcatcher$ sudo gem install mailcatcher-0.6.0.gem 
    Fetching: json-1.8.1.gem (100%)
    Building native extensions.  This could take a while...
    ERROR:  Error installing mailcatcher-0.6.0.gem:
            ERROR: Failed to build gem native extension.
    
            /usr/bin/ruby1.9.1 extconf.rb
    
    Gem files will remain installed in /var/lib/gems/1.9.1/gems/json-1.8.1 for inspection.
    Results logged to /var/lib/gems/1.9.1/gems/json-1.8.1/ext/json/ext/generator/gem_make.out
    vagrant@vvv:~/mailcatcher$ cat /var/lib/gems/1.9.1/gems/eventmachine-1.0.3/ext/gem_make.out 
    /usr/bin/ruby1.9.1 extconf.rb
    
    
    opened by Faison 30
  • Ruby 1.9 no longer supported due to Mailcatcher's dependencies?

    Ruby 1.9 no longer supported due to Mailcatcher's dependencies?

    Hi, yesterday we stopped being able to install Mailcatcher. During the installation (via gem install mailcatcher) the following error comes up:

    Error installing mailcatcher:
    mime-types-data requires Ruby version >= 2.0.
    

    We have Ruby 1.9.3p484 installed from the official Ubuntu repository (there is no newer one unfortunately).

    Is this the end of the support of Ruby 1.9, or can we do something about it?

    opened by Revisor 17
  • Mailcatcher not working on Ubuntu 18 / Ruby 2.5

    Mailcatcher not working on Ubuntu 18 / Ruby 2.5

    When running mailcatcher from the shell:

    Failed to execute process '/usr/local/bin/mailcatcher'. Reason: The file '/usr/local/bin/mailcatcher' specified the interpreter '/usr/bin/ruby2.3', which is not an executable command.

    ruby -v

    ruby 2.5.1p57 (2018-03-29 revision 63029) [x86_64-linux-gnu]

    opened by cnizzardini 14
  • Support for context paths

    Support for context paths

    So that you can put mailcatcher behind a reverse proxy easily. This would make it much easier to use in staging environments, or shared test environments.

    feature 
    opened by sean-abbott 14
  • Install fails in GIT Action since yesterday

    Install fails in GIT Action since yesterday

    Operating system tested with Ubuntu latest and 20.04

    Also tried sudo gem install --pre mailcatcher

    Any idea?

    Run sudo gem install mailcatcher --no-update-sources --no-document
      sudo gem install mailcatcher --no-update-sources --no-document
      mailcatcher
      shell: /usr/bin/bash -e {0}
      env:
        COMPOSER_PROCESS_TIMEOUT: 0
        COMPOSER_NO_INTERACTION: 1
        COMPOSER_NO_AUDIT: 1
    Building native extensions. This could take a while...
    Successfully installed eventmachine-1.0.9.1
    Successfully installed net-protocol-0.2.0
    Successfully installed net-imap-0.3.1
    Successfully installed mail-2.8.0
    Successfully installed rack-1.6.13
    Successfully installed rack-protection-1.5.5
    Successfully installed tilt-2.0.11
    Successfully installed sinatra-1.4.8
    Successfully installed sqlite3-1.5.4-x86_64-linux
    Successfully installed daemons-1.4.1
    Building native extensions. This could take a while...
    Successfully installed thin-1.5.1
    Successfully installed skinny-0.2.4
    Successfully installed mailcatcher-0.8.2
    13 gems installed
    /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:168:in `require': cannot load such file -- mail/indifferent_hash (LoadError)
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:168:in `rescue in require'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:156:in `require'
    	from /var/lib/gems/2.7.0/gems/mail-2.8.0/lib/mail.rb:14:in `<module:Mail>'
    	from /var/lib/gems/2.7.0/gems/mail-2.8.0/lib/mail.rb:3:in `<top (required)>'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher/mail.rb:5:in `<top (required)>'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher/smtp.rb:5:in `<top (required)>'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher.rb:183:in `block (2 levels) in run!'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher.rb:233:in `rescue_port'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher.rb:182:in `block in run!'
    	from /var/lib/gems/2.7.0/gems/eventmachine-1.0.9.1/lib/eventmachine.rb:193:in `run_machine'
    	from /var/lib/gems/2.7.0/gems/eventmachine-1.0.9.1/lib/eventmachine.rb:193:in `run'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher.rb:180:in `run!'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/bin/mailcatcher:6:in `<top (required)>'
    	from /usr/local/bin/mailcatcher:23:in `load'
    	from /usr/local/bin/mailcatcher:23:in `<main>'
    /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require': cannot load such file -- mail/indifferent_hash (LoadError)
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /var/lib/gems/2.7.0/gems/mail-2.8.0/lib/mail.rb:14:in `<module:Mail>'
    	from /var/lib/gems/2.7.0/gems/mail-2.8.0/lib/mail.rb:3:in `<top (required)>'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher/mail.rb:5:in `<top (required)>'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher/smtp.rb:5:in `<top (required)>'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher.rb:183:in `block (2 levels) in run!'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher.rb:233:in `rescue_port'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher.rb:182:in `block in run!'
    	from /var/lib/gems/2.7.0/gems/eventmachine-1.0.9.1/lib/eventmachine.rb:193:in `run_machine'
    	from /var/lib/gems/2.7.0/gems/eventmachine-1.0.9.1/lib/eventmachine.rb:193:in `run'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/lib/mail_catcher.rb:180:in `run!'
    	from /var/lib/gems/2.7.0/gems/mailcatcher-0.8.2/bin/mailcatcher:6:in `<top (required)>'
    	from /usr/local/bin/mailcatcher:23:in `load'
    	from /usr/local/bin/mailcatcher:23:in `<main>'
    Starting MailCatcher v0.8.2
    Error: Process completed with exit code 1.
    
    opened by stell 3
  • Add HTML source view tab

    Add HTML source view tab

    I added an HTML source view because I needed to look at the HTML sources and it was so much faster to use this than the browser's developer tools.

    For an email with an HTML part such as this:

    message-html

    the HTML source view would look like this:

    message-html-source

    I noticed someone had already requested this a couple of years ago, too.

    Resolves #432.

    opened by jlamberg 0
  • macos 13.0.1, starts but quietly fails to start daemon in ruby 2.7.5, does work if run in foreground, works in ruby 3.1.2 in daemon mode

    macos 13.0.1, starts but quietly fails to start daemon in ruby 2.7.5, does work if run in foreground, works in ruby 3.1.2 in daemon mode

    Note does work in daemon mode on ruby 3.1.2 after using thin install tip: gem install thin -v 1.5.1 -- --with-cflags="-Wno-error=implicit-function-declaration" before installing mailcatcher

    more about my computer:

    % sysinfo
    Software:
    
        System Software Overview:
    
          System Version: macOS 13.0.1 (22A400)
          Kernel Version: Darwin 22.1.0
          Time since boot: 1 day, 11 hours, 17 minutes
    
    Hardware:
    
        Hardware Overview:
    
          Model Name: MacBook Pro
          Model Identifier: MacBookPro18,3
          Model Number: Z15G001X4LL/A
          Chip: Apple M1 Pro
          Total Number of Cores: 10 (8 performance and 2 efficiency)
          Memory: 32 GB
          System Firmware Version: 8419.41.10
          OS Loader Version: 8419.41.10
    

    Start as daemon, console output displays normally but daemon not started.

    ruby-2.7.5 % gem info mailcatcher
    
    *** LOCAL GEMS ***
    
    mailcatcher (0.8.2)
        Author: Samuel Cochran
        Homepage: https://mailcatcher.me
        License: MIT
        Installed at: /Users/stephen/.rbenv/versions/2.7.5/lib/ruby/gems/2.7.0
    
        Runs an SMTP server, catches and displays email in a web interface.
    ruby-2.7.5 % mailcatcher     
    Starting MailCatcher v0.8.2
    ==> smtp://127.0.0.1:1025
    ==> http://127.0.0.1:1080
    *** MailCatcher runs as a daemon by default. Go to the web interface to quit.
    ruby-2.7.5 % curl -i http://127.0.0.1:1080
    curl: (7) Failed to connect to 127.0.0.1 port 1080 after 5 ms: Connection refused
    ruby-2.7.5 % psg mailcatcher
    ruby-2.7.5 % mailcatcher -f      
    Starting MailCatcher v0.8.2
    ==> smtp://127.0.0.1:1025
    ==> http://127.0.0.1:1080
    

    Open another terminal and check to see if it is running.

    ruby-2.7.5 % curl -I http://127.0.0.1:1080
    HTTP/1.1 200 OK
    Content-Type: text/html;charset=utf-8
    Content-Length: 2156
    X-XSS-Protection: 1; mode=block
    X-Content-Type-Options: nosniff
    X-Frame-Options: SAMEORIGIN
    Connection: keep-alive
    Server: thin 1.5.1 codename Straight Razor
    
    ruby-2.7.5 % psg mailcatcher
    stephen          41774   0.0  0.1 409136896  49888 s006  S+    1:24PM   0:00.25 /Users/stephen/.rbenv/versions/2.7.5/bin/ruby /Users/stephen/.rbenv/versions/2.7.5/bin/mailcatcher -f
    

    Tested also by sending mail from rails app in dev mode -- works.

    Quit from web application.

    Try starting mailcatcher in verbose mode to see if there are any additional error messages -- no additional info.

    ruby-2.7.5 % mailcatcher -v
    Starting MailCatcher v0.8.2
    ==> smtp://127.0.0.1:1025
    ==> http://127.0.0.1:1080
    *** MailCatcher runs as a daemon by default. Go to the web interface to quit.
    ruby-2.7.5 % curl -I http://127.0.0.1:1080
    curl: (52) Empty reply from server
    
    opened by stepheneb 1
  • Show number of attachments for each message

    Show number of attachments for each message

    For my testing, it would be invaluable to see the number of attachments for each message already on the message list without having to click and open each of them to the lower pane.

    I already made a PR (#522) with the changes.

    opened by jlamberg 0
  • Can't open in browser

    Can't open in browser

    Long-time user and fan of mail catcher. Suddenly unable to load mailcatcher in the browser.

    Running Ruby (3.0.0) on Rails (7.0.2.2) and am able to start mailcatcher (v 0.8.2):

    mailcatcher
    Starting MailCatcher v0.8.2
    /Users/liam/.rvm/gems/ruby-3.0.0/gems/digest-3.1.0/lib/digest.rb:20: warning: already initialized constant Digest::REQUIRE_MUTEX
    /Users/liam/.rvm/rubies/ruby-3.0.0/lib/ruby/3.0.0/digest.rb:6: warning: previous definition of REQUIRE_MUTEX was here
    ==> smtp://127.0.0.1:1025
    ==> http://127.0.0.1:1080
    *** MailCatcher runs as a daemon by default. Go to the web interface to quit.
    

    The warnings don't seem to be causing the issue, and when I go to the web interface, I'm just met with "can't connect to server" error. I've tried on Safari, Chrome and Firefox, all are the same. Curiously, when I go back to the terminal to re-run mailcatcher, it starts as if it hadn't been initialised. If I start mailcatcher, then run a lsof on port 1025, it returns a process, but not after I've tried to access mailcatcher in the browser.

    It seems that trying to open mailcatcher in the browser is killing the server, but I can't figure out why. Most recent major changes I've made out of the ordinary are:

    • installing Xcode-select
    • upgrading macOS to Ventura 13.0

    I'm using RVM, and I also tried running uninstalling and running the RVM-installation guide, which gave the same logs as above, minus the errors. I've also tried uninstalling and reinstalling mailcatcher multiple times, restarting my Mac, running through multiple repositories, through VSCode and iterm. Not sure what else to try.

    Also, even though I was getting no errors, I tried installing mailcatcher via the command:

    gem install mailcatcher -- --with-cflags="-Wno-error=implicit-function-declaration" from https://stackoverflow.com/questions/64662290/gem-install-mailcatcher-fails-with-error-error-installing-mailcatcher-error but that also didn't work.

    Any help is greatly appreciated!

    opened by LJ-03 7
Releases(v0.9.0.beta1)
Owner
Samuel Cochran
Samuel Cochran
ViMbAdmin project provides a web based virtual mailbox administration system to allow mail administrators to easily manage domains, mailboxes and aliases.

ViMbAdmin project (vim-be-admin) provides a web based virtual mailbox administration system to allow mail administrators to easily manage domains, mailboxes and aliases.

Open Solutions 464 Jan 1, 2023
Online chatting application through a logical decentralized blockchain network that stores chat information and hashing keys implemented using AJAX, JQuery, PHP, SQL, CSS, and HTML

Online chatting application through a logical decentralized blockchain network that stores chat information and hashing keys implemented using AJAX, JQuery, PHP, SQL, CSS, and HTML. The blockchain stores a previous hash value, current hash value, time, chat data, and a special key(nonce) used for encryption in each block (node).

Dave Sharma 1 Jan 4, 2022
Server manager is a open source project made for people so that they can add the servers to one single place irrespective of their provider and manage it through one location.

Server Manager Are you sick of having to log into hundreads of different website just to access your server? Well we got you, Server manager is a open

null 8 Aug 9, 2022
Create and Control Page Redirects through Filament

Create and Control Page Redirects through Filament A Filament resource to create and maintain page redirects for your website. Installation You can in

James Harley 7 Nov 4, 2022
đŸ“„ A simple web page to download addons through the GmodStore API.

?? GmodStore Downloader In French Ce petit site Internet permet le téléchargement d'addons en provenance du GmodStore sans passer le site en ligne mai

Florian Trayon 3 Nov 2, 2022
A free and open-source accounting and production system for businesses and non-profits with support for multiple users and varied integrations

A free and open-source accounting and production system for businesses and non-profits with support for multiple users and varied integrations.

null 3 Sep 22, 2022
Emoncms is an open-source web application for processing, logging and visualising energy, temperature and other environmental data and is part of the OpenEnergyMonitor project.

Emoncms is an open-source web application for processing, logging and visualising energy, temperature and other environmental data and is part of the OpenEnergyMonitor project.

Emoncms 1.1k Dec 22, 2022
Created simple login system and chat type website using mysql database along with php and html , css and javascript.

Created simple login system and chat type website using mysql database along with php and html , css and javascript.

null 1 Jan 6, 2022
This prj we have two NODEMCU ( ESP8266) and two RFID_RC522 and some rfid tags we used ARDUINO IDE on NODEMCU and running server with XAMPP

This prj we have two NODEMCU ( ESP8266) and two RFID_RC522 and some rfid tags we used ARDUINO IDE on NODEMCU and running server with XAMPP

Mohammadamir Soltanzadeh 2 Mar 29, 2022
Rafa Cake and Bakery is a web-based application project that aims to introduce Rafa Cake and Bakery, introduce what products are sold and can also order them via Whatsapp.

Rafa-cake-and-bakery Rafa Cake and Bakery is a web-based application project that aims to introduce Rafa Cake and Bakery, introduce what products are

Aan Evian Nanda 2 Jun 19, 2022
A great looking and easy-to-use photo-management-system you can run on your server, to manage and share photos.

Lychee A great looking and easy-to-use photo-management-system. Since the 1st of April 2018 this project has moved to it's own Organisation (https://g

Tobias Reich 6.2k Jan 5, 2023
TinyFileManager is web based file manager and it is a simple, fast and small file manager with a single file, multi-language ready web application

TinyFileManager is web based file manager and it is a simple, fast and small file manager with a single file, multi-language ready web application for storing, uploading, editing and managing files and folders online via web browser. The Application runs on PHP 5.5+, It allows the creation of multiple users and each user can have its own directory and a build-in support for managing text files with cloud9 IDE and it supports syntax highlighting for over 150+ languages and over 35+ themes.

Prasath Mani 3.5k Jan 7, 2023
Open source ERP software. Built on modern PHP and bootstrap 4. Easy and powerful.

FacturaScripts Open source ERP software. Built on modern PHP and bootstrap 4. Easy and powerful. Install Clone and deploy with composer and npm (compo

Carlos Garcia 313 Jan 4, 2023
OpenEMR is a Free and Open Source electronic health records and medical practice management application

OpenEMR is a Free and Open Source electronic health records and medical practice management application. It features fully integrated electronic health records, practice management, scheduling, electronic billing, internationalization, free support, a vibrant community, and a whole lot more. It runs on Windows, Linux, Mac OS X, and many other platforms.

OpenEMR 2.1k Jan 9, 2023
This is a Task Manager system for managing your task. You can categorize your tasks and upload music to the project And a whole host of other features

taskManager Login and register Each user can have their own task Categorize tasks by creating folders Edit and Delete Folders Search for Tasks Show nu

masoudharooni 11 May 22, 2022
A free and open-source Laravel 5.5 and VueJS (SPA) Ticket system

Ticket-conductor A Laravel 5.5 and VueJS (SPA) Ticket system app (This project was mostly for myself to learn Vue Js a bit better, and will not be mai

Casper Bottelet 51 Dec 17, 2022
Vote based Question & Answer site built using Laravel 5.4, material design, x-editable and jQuery Upvote with email and database notifications.

About Vote based Question & Answer site built using Laravel 5.4, material design, x-editable, jQuery Upvote and email/database notifications. Register

Jorge A. Gonzalez 116 Nov 2, 2022
Vote based Question & Answer site built using Laravel 5.4, material design, x-editable and jQuery Upvote with email and database notifications.

About Vote based Question & Answer site built using Laravel 5.4, material design, x-editable, jQuery Upvote and email/database notifications. Register

Jorge A. Gonzalez 116 Nov 2, 2022