[SOLVED] Docker Registry error remote loging

Hi, this is my env:
Debian 10
GitLab Community Edition 13.11.3
Docker 20.10.6

This in partial gitlab.rb:
nginx
nginx[‘enable’] = true
nginx[‘redirect_http_to_https’] = true
registry_nginx[‘redirect_http_to_https’] = true
letsencrypt[‘enable’] = false
nginx[‘ssl_certificate’] = “/etc/ssl/certs/gitlab-selfsigned.crt”
nginx[‘ssl_certificate_key’] = “/etc/ssl/private/gitlab-selfsigned.key”
nginx[‘log_directory’] = “/var/log/gitlab/nginx”

registry
gitlab_rails[‘registry_enabled’] = true
gitlab_rails[‘registry_api_url’] = ‘http://localhost:5000
registry_external_url ‘https://gitlab.cdlmvenezia.intranet:5050
registry_nginx[‘ssl_certificate’] = “/etc/ssl/certs/gitlab-selfsigned.crt”
registry_nginx[‘ssl_certificate_key’] = “/etc/ssl/private/gitlab-selfsigned.key”

I’m trynt lo login to registry from remote vm, thi is error:
Error response from daemon: Get https://gitlab.domain.intranet:5050/v2/: received unexpected HTTP status: 502 Bad Gateway

nmap -T4 -A -v -Pn gitlab.domain.intranet:
5050/tcp open ssl/http nginx
Why?
How can I fix it?

Solved stopping gitlab, restarting docker registry BEFORE gitlab