[英]js fetch fails with net::ERR_SSL_PROTOCOL_ERROR when accessing different ports
If I load a page using localhost:85 and try to fetch()
a resource from localhost:8083 it gives me a ERR_SSL_PROTOCOL_ERROR
error.如果我使用localhost:85加载页面并尝试从localhost:8083
fetch()
资源,它会给我一个ERR_SSL_PROTOCOL_ERROR
错误。
I do not have SSL enabled on either side.我没有在任一侧启用 SSL。 Clearly this is all in a development environment, how do I work around it?
显然这一切都在开发环境中,我该如何解决呢?
So far, the only reasonable solution I've had was to edit both of the sites to operate out of the same port, but just have Nginx redirect the location.到目前为止,我唯一合理的解决方案是编辑两个站点以在同一个端口外运行,但只需让 Nginx 重定向该位置。 In other words:
换句话说:
localhost:85 => localhost:85本地主机:85 => 本地主机:85
localhost:85/site2 => localhost:8083本地主机:85/site2 => 本地主机:8083
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.