502 Bad Gateway - Unraid | Cloudflare | NGINX

Generally, the external_url, should be how you want to access it, whether that is over http and port 8380 or https on port 7343 is up to you. You mention you have an nginx container/server in front of Gitlab? Did you ensure to configure the proxy headers, since nginx is working as a reverse proxy. For example:

   location / {
      proxy_set_header Host $http_host;
      proxy_set_header X-Forwarded-Host $host;
      proxy_set_header X-Forwarded-Server $host;
      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header X-Forwarded-Proto $scheme;
      proxy_pass http://unraid:7380;
   }

you may also need additional settings in gitlab.rb as per these Gitlab nginx docs: NGINX settings | GitLab but I would see how you go first when nginx is providing the headers as above from nginx to Gitlab. My example above is set to redirect nginx over http to port 7380, so change accordingly on whether your external url uses 7380 or https on 7343.

If you use external_url without the port, it will want to use 80 or 443 by default.