ngrok的使用
2016-03-20 14:13
423 查看
windows的ngrok配置:
步骤一:下载ngrok http://pan.baidu.com/s/1jH0s8o2
步骤二:如果你的国外网址没被墙就直接使用cmd命令行使用。
国内ngrok配置:
在ngrok.cc网址注册,然后获得token
然后配置文件在ngrok.exe目录配置ngrok.cfg
server_addr: "server.ngrok.cc:4443"
auth_token: "" #授权token,在www.ngrok.cc平台注册账号获取
tunnels:
wenbo:
subdomain: "" #定义服务器分配域名前缀,跟平台上的要一样
proto:
http: 80 #映射端口,不加ip默认本机
https: 80
web:
subdomain: "web" #定义服务器分配域名前缀
proto:
http: 192.168.1.100:80 #映射端口,可以通过加ip为内网任意一台映射
https: 192.168.1.100:80
web1:
hostname: "www.sunnyos.com"
proto:
http: 80
web2:
hostname: "sunnyos.com"
proto:
http: 80
ssh:
remote_port: 50001 #服务器分配tcp转发端口,如果不填写此项则又服务器分配
proto:
tcp: 22 #映射本地的22端口
ssh1: #将由服务器分配端口
proto:
tcp: 21
然后使用ngrok -config ngrok.cfg start 你的在ngrok注册的前缀
ok,快来试试吧。
步骤一:下载ngrok http://pan.baidu.com/s/1jH0s8o2
步骤二:如果你的国外网址没被墙就直接使用cmd命令行使用。
国内ngrok配置:
在ngrok.cc网址注册,然后获得token
然后配置文件在ngrok.exe目录配置ngrok.cfg
server_addr: "server.ngrok.cc:4443"
auth_token: "" #授权token,在www.ngrok.cc平台注册账号获取
tunnels:
wenbo:
subdomain: "" #定义服务器分配域名前缀,跟平台上的要一样
proto:
http: 80 #映射端口,不加ip默认本机
https: 80
web:
subdomain: "web" #定义服务器分配域名前缀
proto:
http: 192.168.1.100:80 #映射端口,可以通过加ip为内网任意一台映射
https: 192.168.1.100:80
web1:
hostname: "www.sunnyos.com"
proto:
http: 80
web2:
hostname: "sunnyos.com"
proto:
http: 80
ssh:
remote_port: 50001 #服务器分配tcp转发端口,如果不填写此项则又服务器分配
proto:
tcp: 22 #映射本地的22端口
ssh1: #将由服务器分配端口
proto:
tcp: 21
然后使用ngrok -config ngrok.cfg start 你的在ngrok注册的前缀
ok,快来试试吧。
相关文章推荐
- 鼠标在窗口中的坐标转换到 canvas 中的坐标
- 简单的基于Socket的TCP编程实例
- Linux笔记(61)——mysql源码包安装
- RAID 图解
- codeforces_632F. Magic Matrix(bitset)
- linux 工作队列workqueue
- Blackjack - Intro
- CROC 2016 - Elimination Round (Rated Unofficial Edition) A. Amity Assessment 水题
- Maven 工程下 Spring MVC 站点配置 (二) Mybatis数据操作
- 利用Hadoop Streaming处理二进制格式文件
- Java基础之十三:Java集合框架
- Qt利用样式表实现三态按钮
- Win7 64位 VS2015环境编译cegui-0.8.5
- Something wrong with FTK OCR
- lintcode-medium-Fast Power
- 悬浮导航栏的实现以及导航跳转
- Objective-C中不同方式实现锁
- 工作八个月感想
- Hadoop Streaming编程实例
- Linux审计