问题描述
配置文件
server {listen 8899;server_name tc.com;location / { root html; index index.html index.htm; } }
浏览器访问tc.com:8899没用,但是使用localhost:8899有用,这是为什么?
问题解答
回答1:我怀疑你不知道 DNS 和 域名 还有 server_name 是什么区别
回答2:忘改hosts了

问题描述
配置文件
server {listen 8899;server_name tc.com;location / { root html; index index.html index.htm; } }
浏览器访问tc.com:8899没用,但是使用localhost:8899有用,这是为什么?
问题解答
回答1:我怀疑你不知道 DNS 和 域名 还有 server_name 是什么区别
回答2:忘改hosts了
相关文章:
网公网安备:皖ICP备2020019022号-8 Copyright ¢ 2020-2025 Powered by V1.8 All Rights Reserved 技术支持:乐呵呵网
声明:本站所有资源以学习为主