首页
学习
活动
专区
工具
TVP
发布
社区首页 >问答首页 >(新人)如何通过公网连接nginx的静态默认页面?

(新人)如何通过公网连接nginx的静态默认页面?

提问于 2023-02-17 16:13:43
回答 0关注 0查看 76

我在尝试用Docker跑Nginx,但是没办法通过公网访问 Nginx 的初始页面,能用 curl 访问到 localhost,说明 Nginx 已经跑起来了。搜了一堆相关问题,都说要配置安全组,点了一键放通,还是没办法访问 http://43.136.89.155/8000。我哪里弄错了么?

能用 curl 正常访问到 Localhost

代码语言:js
复制

[root@VM-0-14-tlinux ~]# curl http://localhost:8000
<!DOCTYPE html>
<html>
<head>
<title>Welcome to nginx!</title>
<style>
html { color-scheme: light dark; }
body { width: 35em; margin: 0 auto;
font-family: Tahoma, Verdana, Arial, sans-serif; }
</style>
</head>
<body>
<h1>Welcome to nginx!</h1>
<p>If you see this page, the nginx web server is successfully installed and
working. Further configuration is required.</p>

<p>For online documentation and support please refer to
<a href="http://nginx.org/">nginx.org</a>.<br/>
Commercial support is available at
<a href="http://nginx.com/">nginx.com</a>.</p>

<p><em>Thank you for using nginx.</em></p>
</body>
</html>
172.17.0.1 - - [17/Feb/2023:07:49:42 +0000] "GET / HTTP/1.1" 200 615 "-" "curl/7.29.0" "-"

回答

和开发者交流更多问题细节吧,去?写回答
相关文章

相似问题

相关问答用户
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档
http://www.vxiaotou.com