the smtp setting does not work in gitlab.rb after run gitlab-ctl reconfigure
- /etc/gitlab/gitlab.rb
Add the below lines
##configure smtp gitlab_rails['smtp_enable'] = true gitlab_rails['smtp_address'] = "mail.xxx.com" gitlab_rails['smtp_port'] = 456 gitlab_rails['smtp_user_name'] = "git@xxx.com" gitlab_rails['smtp_password'] = "xxx" gitlab_rails['smtp_domain'] = "xxx.com" gitlab_rails['smtp_authentication'] = "login" gitlab_rails['smtp_enable_starttls_auto'] = true
-
run gitlab-ctl reconfigure
-
cat gitlab.yml there is nothing about smtp configuration.
-
test email function, it also does not work. project -- setting --service --Emails on push -- test setting.
question:
-
how to configure smtp server and related info via gitlab.rb?
-
how to configure the value of below keys in gitlab.yml via gitlab.rb?
Email settings
# Email address used in the "From" field in mails sent by GitLab
email_from: gitlab@xxx
# Email address of your support contact (default: same as email_from)
support_email: support@localhost