Hey, I have a GitLab Docker Container up and running but I have a problem when I try to connect to my mail server. When configuring the SMTP connection in the docker-compose file, GitLab is unable to send any mails. But when I edit the gitlab.rb file with the exact same config, it’s sending the mails.
Hopefully someone can help me figure out what I’m doing wrong.
docker-compose:
web:
image: 'gitlab/gitlab-ee:latest'
restart: always
hostname: '<gitlab_domain>'
environment:
GITLAB_OMNIBUS_CONFIG: |
external_url '<gitlab_domain>'
gitlab_rails['gitlab_shell_ssh_port'] = 2224
gitlab_rails['smtp_enable'] = true
gitlab_rails['smtp_address'] = '<smtp_host>'
gitlab_rails['smtp_port'] = 587
gitlab_rails['smtp_user_name'] = 'gitlab@<domain>'
gitlab_rails['smtp_password'] = 'super_secret_password'
gitlab_rails['smtp_authentication'] = 'login'
gitlab_rails['smtp_enable_starttls_auto'] = true
gitlab_rails['gitlab_email_from'] = 'gitlab@<domain>'
letsencrypt['enabled'] = false
nginx['redirect_http_to_https'] = false
nginx['listen_port'] = 80
nginx['listen_https'] = false
ports:
- '9080:80'
- '9443:443'
- '2224:22'
volumes:
- '/srv/gitlab/config:/etc/gitlab'
- '/srv/gitlab/logs:/var/log/gitlab'
- '/srv/gitlab/data:/var/opt/gitlab'