Content
You are here:
[Resolved] Email issue, Ruby error?
Added by Ed Ol over 10 years ago
Hello,
I believe I configured my email settings correctly, but I keep having this issue:
An error occurred while sending mail (Failure in opening uri #<URI::Generic:0x0000000a62e3c8 URL:/home/openproject/openproject/tmp/letter_opener/1405003506_e3fc9e1/rich.html> with options {}: Can't convert URI::Generic into String.)
I’ve tried with “smtp_enable_starttls_auto” set to true or false, but still nothing.. Tried smtp_authentification with plain and login and tried smtp_openssl_verify_mode true/false too
Thanks for your help.
Ed
Replies (3)
Hi Ed,
how are you running OpenProject?
The error seems to be produced by
letter_opener
which should only ever run in development mode (your server should run in production mode).To start OpenProject in production mode, start the server with a prepended “
RAILS_ENV=production
” (as inRAILS_ENV=production bundle exec rails server
) or, even better, use a proper rails server like passenger or unicorn.I hope this solves your issue.
cheers,
tessi
Hello Tessi,
I was running it with Thin (
bundle exec thin start
) but I switched to Unicorn now and it’s still not working.Maybe I have another problem because I can’t seem to run it in production, it keeps giving me errors
reaped #<Process:Status: pid 15644 exit 1>
. But that’s another topic though I’ll have to search for answers. I can’t even precompile assets, I only get a bunch of errors.Ed
Hello,
Just wanted to thank you for your reply, that was the problem. I can now send emails!
Burt for my curiosity, why
letter_opener
can’t run in production mode?