在域名上预先设置“需要 SSL”,以便在开发计算机 (Windows) 上访问开发站点,我编辑主机文件并将域名指向开发服务器 IP 地址。一切运行顺利。
现在大多数浏览器都要求所有域名都是 SSL,有没有类似的方法可以在我的电脑上访问开发页面?
Hostfile 仍在运行,但 Google Chrome 不再允许连接。我收到此错误。
Your connection is not private
Attackers might be trying to steal your information from yourdomain.app (for example, passwords, messages, or credit cards). Learn more
NET::ERR_CERT_COMMON_NAME_INVALID
yourdomain.app normally uses encryption to protect your information. When Google Chrome tried to connect to yourdomain.app this time, the website sent back unusual and incorrect credentials. This may happen when an attacker is trying to pretend to be yourdomain.app, or a Wi-Fi sign-in screen has interrupted the connection. Your information is still secure because Google Chrome stopped the connection before any data was exchanged.
You cannot visit yourdomain.app right now because the website uses HSTS. Network errors and attacks are usually temporary, so this page will probably work later.
有什么建议我该如何以旧方式进行开发?我不想将其放在其他子域或文件夹中,因为上线时我必须更改这些引用。与 hostfile 方法不同,一切都保持原样。
谢谢