setup.md.
...
environment:
GITLAB_OMNIBUS_CONFIG: |
...
registry_external_url 'https://docker.example.com/'
registry['enable'] = true
registry_nginx['listen_port'] = 81
registry_nginx['listen_https'] = false
registry_nginx['real_ip_trusted_addresses'] = [ '172.0.0.0/8' ]
registry_nginx['real_ip_header'] = 'X-Forwarded-For'
registry_nginx['request_buffering_off_path_regex'] = '.?'
...
...
labels:
traefik.enable: 'true'
traefik.gitlab.port: '80'
traefik.gitlab.frontend.rule: 'Host: gitlab.example.com'
traefik.registry.port: '81'
traefik.registry.frontend.rule: 'Host: docker.example.com'
...
/var/opt/gitlab/gitlab-rails/shared/registry/docker
If you see docker push
failing with immediate "Retrying in 5 seconds" messages, and HTTP 500 responses in the logs, then make sure that the /var/opt/gitlab/gitlab-rails/shared/registry/docker
directory is owned by UID 993
, with permissions of at least 0755
.