で実行されるサービス(dockerレジストリ)がありport 5000、http要求をから8080にリダイレクトするnginxをインストールしました5000。カールを作成するlocalhost:5000と機能しますが、カールを作成localhost:8080するとBad gatewayエラーが発生します。
nginx構成ファイル:
upstream docker-registry {
 server localhost:5000;
}
server {
 listen 8080;
 server_name registry.mydomain.com;
 proxy_set_header Host       $http_host; 
 proxy_set_header X-Real-IP  $remote_addr; 
 client_max_body_size 0; 
 chunked_transfer_encoding on;
 location / {
     proxy_pass http://docker-registry;
 }
 location /_ping {
     auth_basic off;
     proxy_pass http://docker-registry;
 }
 location /v1/_ping {
     auth_basic off;
     proxy_pass http://docker-registry;
 }
}
で/var/log/nginx/error.log、私があります。
[crit] 15595#0: *1 connect() to [::1]:5000 failed (13: Permission denied) while connecting to upstream, client: 127.0.0.1, server: registry.mydomain.com, request: "GET / HTTP/1.1", upstream: "http://[::1]:5000/", host: "localhost:8080"
何か案が?
                  私の場合、プロキシを使用していたサービスは、使用中に死亡しました(そして、私はそれを認識していませんでした)。1秒でアクセスし、次の1秒で悪いゲートウェイになりました。サービスを再起動する必要がありました。
                
                
                  
                    —
                    マイケルプラウツ