Skip to content

Ngrok #49

@Dream4ever

Description

@Dream4ever

需求描述

这个程序可以把本机指定端口上运行的 Web 应用映射到公网 IP 上,很方便。

应用过程

  1. 程序安装运行
    去官网下载后,在cmd中用ngrok http 13437启动,访问映射到外网的地址,提示
**Bad Request - Invalid Hostname**
HTTP Error 400. The request hostname is invalid.
  1. 问题解决

用完整的错误文字搜索,第一个方案就解决了:Exposing localhost to the internet via tunneling (using ngrok): HTTP error 400: bad request; invalid hostname

就是用下面的方式调用即可:

ngrok http 13437 -host-header="localhost:13437"

要点总结

Metadata

Metadata

Assignees

No one assigned

    Labels

    SoftwareAbout installation ande usage

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions