If you are planning to send application emails via gmail SMTP server
Open GitLab config file in an editor
sudo vim /etc/gitlab/gitlab.rb
Add the following line in the config file
gitlab_rails['smtp_enable'] = true
gitlab_rails['smtp_address'] = "smtp.gmail.com"
gitlab_rails['smtp_port'] = 587
gitlab_rails['smtp_user_name'] = "my.email@gmail.com"
gitlab_rails['smtp_password'] = "my-gmail-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'
Change “my.email@gmail.com” with your email address and “my-
If you are using gsuite and planning to use your gsuite email address, change the shtp domain to your domain name.
Save the file and reconfigure GitLab for the changes to take effect.
sudo gitlab-ctl reconfigure
Your GitLab server must be able to send emails now!!