Hi,
I have deployed gitlab on docker and I want to use a local smarthost (postfix).
I have configured sendmail on the docker host with /etc/mail/sendmail.mc
define(`SMART_HOST', `[192.168.192.50]')dnl use this host for relaying emails
define(`RELAY_MAILER_ARGS', `TCP $h 25')dnl use smtp port 25
MASQUERADE_AS(mydomain.com)dnl use this domain for the sender
FEATURE(masquerade_envelope)dnl
FEATURE(masquerade_entire_domain)dnl
MASQUERADE_DOMAIN(host.mydomain.com)dnl
then testing from the docker host with “sendmail admin@mydomain.com” works correctly.
but it’s not working from the gitlab container.
I have changed configuration in /etc/gitlab/gitlab.rb
and ran gitlab-ctl reconfigure
gitlab_rails['gitlab_email_enabled'] = true
gitlab_rails['smtp_enable'] = true
gitlab_rails['smtp_address'] = "192.168.192.50"
gitlab_rails['smtp_port'] = 25
gitlab_rails['smtp_domain'] = "mydomain.com"
The smarthost is running postfix.
Has anyone tried to configure gitlab with a postfix smarthost ? (on docker, if this changes anything ?)
I have replaced my real domain name by mydomain.com in this post.
Thank you for any help.