Nginx upstream timed out 10060

Nginx 大约 453 字

错误信息

upstream timed out (10060: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond) while connecting to upstream, client: 127.0.0.1, server: localhost

错误原因

在配置文件中配置了localhost

location /api/ {
    proxy_pass http://localhost:8080/;
}

解决办法

localhost改为127.0.0.1

location /api/ {
    proxy_pass http://127.0.0.1:8080/;
}
阅读 285 · 发布于 2020-12-08

————        END        ————

扫描下方二维码关注公众号和小程序↓↓↓

扫描二维码关注我
昵称:
随便看看 换一批