Content
You are here:
GMail Configuration
Added by Christian Wetzel over 10 years ago
Hello,
I installed OP3.0 on CentOS 6.5 as in the tutorial, except using a MySQL-Server. It seems everything works fine, except Email notifications.
My configuration.yml is as following
production: email_delivery_method: smtp smtp_enable_starttls_auto: true smtp_authentication: plain smtp_address: smtp.gmail.com smtp_port: 587 smtp_domain: smtp.gmail.com smtp_user_name: MYMAIL@gmail.com smtp_password: MYPASSWORD
The Test-Mail in the Administration Panel returns a “An error occurred while sending mail (execution expired)”-Message but has no meaningful log entry:
Started GET "/admin/test_email" for [MYSERVERNAME] at 2014-03-11 15:33:10 +0100 Processing by AdminController#test_email as HTML Rendered user_mailer/test_mail.html.erb within layouts/user_mailer (0.1ms) Rendered user_mailer/test_mail.text.erb within layouts/user_mailer (0.0ms) Sent mail to MYMAIL@gmail.com (30010.0ms) Redirected to http://[MYSERVERNAME]/settings/edit?tab=notifications Completed 302 Found in 30033.3ms (ActiveRecord: 2.3ms) Started GET "/settings/edit?tab=notifications" for [MYSERVERNAME] at 2014-03-11 15:33:40 +0100 Processing by SettingsController#edit as HTML Parameters: {"tab"=>"notifications"} Rendered settings/_general.html.erb (6.8ms) Rendered settings/_display.html.erb (29.5ms) Rendered settings/_authentication.html.erb (6.4ms) Rendered settings/_users.html.erb (1.3ms) Rendered settings/_projects.html.erb (5.4ms) Rendered settings/_work_packages.html.erb (17.0ms) Rendered settings/_notifications.html.erb (6.2ms) Rendered settings/_mail_handler.html.erb (1.7ms) Rendered settings/_repositories.html.erb (7.5ms) Rendered common/_tabs.html.erb (88.9ms) Rendered settings/edit.html.erb within layouts/admin (89.5ms) Rendered admin/_menu.html.erb (5.8ms) Rendered search/_mini_form.html.erb (0.6ms) Rendered layouts/_action_menu.html.erb (0.0ms) Rendered layouts/base.html.erb (11.9ms) Completed 200 OK in 117.5ms (Views: 108.6ms | ActiveRecord: 3.5ms)
Updating an User account with checked send new password gives an internal Server Error:
Started PUT "/users/3" for [MYSERVERNAME] at 2014-03-11 15:26:05 +0100 Processing by UsersController#update as HTML Parameters: {"utf8"=>"✓", "authenticity_token"=>"ZP9gs0cFYy6j+P+jXjB+tkk/RRx6pDG6BPYtpVsI4zU=", "user"=>{"login"=>"[MYLOGIN]", "firstname"=>"Christian", "lastname"=>"Wetzel", "mail"=>"[MY_EMAILADDRESS]", "language"=>"en", "admin"=>"0", "assign_random_password"=>"[FILTERED]", "force_password_change"=>"[FILTERED]", "mail_notification"=>"only_my_events"}, "pref"=>{"impaired"=>"0", "hide_mail"=>"1", "time_zone"=>"", "comments_sorting"=>"asc", "warn_on_leaving_unsaved"=>"1", "theme"=>"default"}, "send_information"=>"1", "commit"=>"Save", "id"=>"3"} Rendered user_mailer/account_information.html.erb within layouts/user_mailer (3.6ms) Rendered user_mailer/account_information.text.erb within layouts/user_mailer (2.4ms) Sent mail to [MY_EMAILADDRESS] (30009.7ms) Completed 500 Internal Server Error in 30163.0ms Net::OpenTimeout (execution expired): app/controllers/users_controller.rb:188:in `update'
Has anybody an idea or at least a tip how to get more detailed log-files?
Replies (13)
Here’s my configuration but we’re on google apps. It should work for gmail too.
As far as I can see are in my configuration only the order of statements, the quotations and colon different. That should not make any difference, but I will try it.
I found the
config.action_mailer.raise_delivery_errors
variable in the production.rb - but it also does not change the log for my problem.I think your smtp_domain is incorrect too.
The domain without smtp. does not solve the problem. Can anybody confirm that ist works with an normal gmail account?
The configuration is correct as it is. The problem was the infrastructure configuration that blocked mails to gmail.com. With another SMTP server everything works. Thank you for your help.
hi
I config mail,but i can’t use mail, how to config that,please help me :S
development: #main level
email_delivery_method: :smtp #main level, will not work
default: #main level
email_delivery_method: :smtp #setting for default
smtp_address: smtp.gmail.com #setting for default
smtp_port: 587
smtp_domain: smtp.gmail.com
smtp_user_name: celltechproject@gmail.com
smtp_password: xxxx
smtp_enable_starttls_auto: true
smtp_authentication: plain
Is your server configured to communicate to gmail.com? Are there any error messages in the UI or in the log-file?
Dear
the log when I create user then push notify to my gmail quyen89ss@gmail.com
I running Centos on Virtual Box with mode Bridge,connect to internet OK.
View log
Sent mail to quyen89ss@gmal.com (4325.5ms)
Redirected to http://192.168.1.41/users/4
Completed 302 Found in 4747.6ms (ActiveRecord: 123.3ms)
Started GET “/users/4” for 192.168.1.20 at 2014-03-13 21:46:57 –0400
Processing by UsersController#show as HTML
Parameters: {“id”=>“4”}
Rendered layouts/_action_menu_base.html.erb (0.1ms)
Rendered layouts/_action_menu_specific.html.erb (0.4ms)
Rendered users/show.html.erb within layouts/base (10.2ms)
Rendered search/_mini_form.html.erb (0.7ms)
Rendered layouts/_action_menu.html.erb (0.1ms)
Completed 200 OK in 234.6ms (Views: 32.7ms | ActiveRecord: 142.4ms)
Can you test the connection via
telnet smtp.gmail.com 587
, please?Can you test the connection via
telnet smtp.gmail.com 587
, please?Thanks Christian.I can send mail
regard!
I just installed my server open the project and would like to know how to change the time with which it sends the notifications by email as it sends mail every 5 minutes and I need them to be sent every minute.
I would greatly appreciate your help.
Greetings Jovanny
I just installed my server open the project and would like to know how to change the time with which it sends the notifications by email as it sends mail every 5 minutes and I need them to be sent every minute.
I would greatly appreciate your help.
Greetings Jovanny