Report this

What is the reason for this report?

Do i have to install postfix on my omnibus-gitlab in order to send mails through gmail?

Posted on May 5, 2016

Hello!! I installed Gitlab CE Omnibus Package on Ubuntu 16.04 droplet. Im a newbie in all respects on mail and smtp. On the gitlab page it says that you can configure Gmail by editing the /etc/gitlab/gitlab.rb file with this:

 gitlab_rails['smtp_enable'] = true
 gitlab_rails['smtp_address'] = "smtp.gmail.com"
 gitlab_rails['smtp_port'] = 587
 gitlab_rails['smtp_user_name'] = "account@gmail.com"
 gitlab_rails['smtp_password'] = "password"
 gitlab_rails['smtp_domain'] = "smtp.gmail.com"
 gitlab_rails['smtp_authentication'] = "login"
 gitlab_rails['smtp_enable_starttls_auto'] = true
 gitlab_rails['smtp_tls'] = false
 gitlab_rails['smtp_openssl_verify_mode'] = 'peer'

I did that and then sudo gitlab-ctl reconfigure

But it’s not sending any emails. Should i have postfix or manage some sort of certs also?

Thanks in advanced.



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Do i need to have SSL on my domain enabled?

I have seen reports of gmail refusing smtp connections from some IP addresses in our ranges (along with those of other cloud providers). I would recommend checking your log files for any error messages /var/log/gitlab/gitlab-rails/production.log is a good place to start.

If you are seeing messages there indicating that gmail is refusing the connection I would recommend using a service like sendgrid to send mail from your droplet. The service is free for up to 12,000 emails per month. I use them in my own projects and have never encountered a problem.

If you are seeing a different error message indicated please share it here so we can dig into it.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.