可以访问Google Cloud Compute实例外部IP(启动Fedora35)
我有一个nodejs app
在其中运行vm实例
。 我创建了一个防火墙规则
打开端口TCP:5000 。 它在本地(内部VM)起作用,我能够通过
sudo wget http://localhost:5000
此验证连接状态200
确定。
当我用 vm外部IP地址替换localhost
时,我会超时。
我尝试了大多数可以在互联网上获得的东西,但是现在我很累。这是我第一次与GCP互动,所以我想这是预期的。
I have a nodejs app
running inside it a vm instance
.
I created a firewall rule
opening port tcp:5000.
It works locally (inside vm) and I am able to verify the connection via
sudo wget http://localhost:5000
this gives status 200
ok.
when I replace the localhost
with the vm external Ip address I get a connection time out.
I have tried most things I could get on the internet but now I am tired. Its my first time interacting with gcp so I guess it's expected.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
VM实例上的网络标签与您的防火墙规则
库存控制器 - 端口
不匹配。计算引擎实例具有这些网络标签http-server
,https-server
。为了解决此问题,这些是您的选择。库存-Controller-PORT
并添加这些网络标签http-server
,https-server
。有关更多信息,请检查此文档关于更新防火墙规则的文档。contectory-controller-port
上添加的其他网络标签。要了解更多信息,请检查此 documeth现有的VM。The Network tags on the VM instance do not match your firewall rule
inventory-controller-port
. The Compute Engine Instance has these network tagshttp-server
,https-server
. To resolve this issue, these are your options.inventory-controller-port
and add these network tagshttp-server
,https-server
. For more information, check this documentation about updating firewall rules.inventory-controller-port
on your existing VM. To know more check this documentation about Adding tags to an existing VM.