gmail and email.yml

Added by Martin Hall over 12 years ago

I am running 0.8 build 2170

I have looked and I have not found a working email.yml (for me). It says that it works but nothing gets sent.

Anything obvious with this setup?

  1. Outgoing email settings

production:
delivery_method: :smtp
smtp_settings:
address: smtp.gmail.com
port: 587
domain: gmail.com
authentication: :plain
user_name: xxx
password: xxx
tls: true

Replies (38)

RE: gmail and email.yml - Added by frank van tol over 12 years ago

For sending the test email, port 25 works fine, liek so

production:
    delivery_method: :smtp
    smtp_settings:
        address: ASPMX.gmail.com
        port: 25

but no other email gets send when i update issues. Not even a line in trhe logfile.

RE: gmail and email.yml - Added by Sergi de Pablos over 12 years ago

Frank, try following David advice.

RE: gmail and email.yml - Added by alex x over 12 years ago

Hi all, my problem here is that the RM doesn't start, in the console it says that a version 2.1.2 of actionmailer is already being activated.

I followed all the steps posted by David, except the last one because my version is already the 2.1.2.
Anyone has the same problem ?
these are the versions that i'm runnig if it helps:
ruby 1.8.6
rm 0.8.1

RE: gmail and email.yml - Added by Y G over 12 years ago

Hey alex, I just did the same thing as you to get redmine running again just delete the vender/plugins/action_mailer_optional_tls folder and lib/smtp_tls.rb, then try starting redmine.

as for getting smtp to work, I have a postfix server running... with PHP you can just use the mail() method and set the from address as part of the method. why is it so hard to get mail working in rails.. If my server is sending mail why not send it directly to the recipient.. I don't see how using gmail's smtp servers is at all a good solution. does anyone know how to setup redmine to use my local mail server?

up till now installing and configuring rails/redmine has been extremely touch and go, and nobody seems to know how it works. It's upsetting that the redmine developers decided to build with such an immature technology, that consumes such a lot of resources. frustrating.

RE: gmail and email.yml - Added by Ryan Macaluso over 12 years ago

Use these settings in email.yml to use your local SMTP server:

production:
delivery_method: :smtp
smtp_settings:
address: [MACHINE NAME].[DOMAIN NAME]
port: 25
domain: [MACHINE NAME].[DOMAIN NAME]

I eventually found that solution by searching the website, but it wasn't easy to get to that point. I originally wanted to use the gmail server but I couldn't get it to work following the steps above. Using a local server definitely seems to be the cleanest solution. It's just not documented well that this is how you use a local SMTP server.

RE: gmail and email.yml - Added by Y G over 12 years ago

Thanks Ryan! worked great

RE: gmail and email.yml - Added by alex x over 12 years ago

Thanks Yoav, i delete the folder and the RM is up again now.
I guess all the steps above it doesn't work well for me. i'm stuck with the "version 2.1.2 of actionmailer is already being activated" error. Guess i'm going to take a look at the mail method you mention.

RE: gmail and email.yml - Added by Greg Barendt over 12 years ago

Even after following all of the above, I'm still unable to send emails. I'm running Redmine 0.8.2 with WEBrick and trying to send out with my Google Apps account. I've installed the action mailer plugin from above, copied smtp_tls.rb and have the email.yml below:

production:  delivery_method: :smtp
  smtp_settings:    
    address: smtp.gmail.com
    port: 587
    domain: domain.com
    authentication: :login
    user_name: name@domain.com
    password: password
    tls: true

The "lost password" utility reports the it has sent an email and I'm not seeing anything in production.log to make me think it failed, but the email never arrives. I've checked spam folders and tried different recipient addresses, but it just doesn't seem to be working. Does anyone have advice? Thanks in advance.

RE: gmail and email.yml - Added by Dan Cameron over 12 years ago

Check this out. I have an apps account too.

RE: gmail and email.yml - Added by Greg Barendt over 12 years ago

I followed all of those steps, even tried starting with a fresh Redmine install, but it still doesn't seem to be working. I can do actions like using the lost password tool or creating a new user account without any visible error, but emails aren't actually being sent.

Is there a way to turn on more logging so I can get a better idea of where things might be going wrong?

RE: gmail and email.yml - Added by Scott Ruthfield over 12 years ago

I'm having problems with this as well. I've followed both sets of instructions above - Dan Cameron, Martin Hall, David Bronke - but when I try to send the test mail, I get

An error occurred while sending mail (530 5.7.0 Must issue a STARTTLS command first. 5sm3990637ywl.38 )

(the last part changes each time)

I haven't been able to sort my way through this. Anybody have any luck with this problem?

RE: gmail and email.yml - Added by Scott Ruthfield over 12 years ago

BTW, after another hour of trying to get this to work, I realized that my ISP (speakeasy) enables outgoing mail with a u/p (even though my redmine installation isn't installed on speakeasy servers). I was able to get that working with my GApps account in <5min, and with the small amount of mail and the known recipients, I'm not worried about spam blockers. This kind of solution might make sense for others.

RE: gmail and email.yml - Added by Eric Davis over 12 years ago

I did some testing with this and was able to configure Redmine to use GMail. Here's the steps I took:

http://redmineblog.com/articles/setup-redmine-to-send-email-using-gmail

Eric

1 2 (26-38/38)