早上起来后,Chrome在尝试连接各种{subdomain}.localhost域名的网页时,响应错误为ERR_CONNECTION_REFUSED。Firefox和Safari正常连接。我正在使用运行Debian和Apache的Vagrant/Virtualbox。Chrome可以连接未在域名中使用localhost的本地域。不知道Chrome是否发布了某种本地防火墙?但在发行说明中没有看到任何相关内容。
更新:在终端中运行curl {subdomain}.localhost会给出预期的输出(从Web服务器得到响应)。
更新2:我刚发现这个链接:https://news.ycombinator.com/item?id=9210484(Chrome团队计划阻止浏览器对localhost wss的所有访问),但我没有看到是否已经实施。
更新:在终端中运行curl {subdomain}.localhost会给出预期的输出(从Web服务器得到响应)。
更新2:我刚发现这个链接:https://news.ycombinator.com/item?id=9210484(Chrome团队计划阻止浏览器对localhost wss的所有访问),但我没有看到是否已经实施。