卷曲到 kuberetes returns 502 Bad Gateway 上托管的应用程序

Curl to a application hosted on kuberetes returns 502 Bad Gateway

curl -v -k https://xxxx.yyyy.zzzz.pp/
*   Trying 143.204.181.115...
* Connected to xxxx.domain.name.something (143.204.181.115) port 443 (#0)
* SSL peer handshake failed, the server most likely requires a client certificate to connect
* Closing connection 0
curl: (35) SSL peer handshake failed, the server most likely requires a client certificate to connect

它与入口控制器设置有关,它是对应用程序入口的负载平衡请求。如果入口的注释规范格式不正确,即

,则会出现此问题
    nginx.ingress.kubernetes.io/secure-backends - if the nginx ingress controller is setup using the chart https://github.com/kubernetes/ingress-nginx

    ingress.kubernetes.io/secure-backends - if the nginx ingress controller is setup using the KOPS https://github.com/kubernetes/kops/tree/master/addons/ingress-nginx

注释中的 'nginx.' 必须删除,这解决了访问应用程序时出现的 502 Bad Gateway 错误 URL。