ubuntu、cpolar、api开启映射之路

1.国内cpolar安装

curl -L https://www.cpolar.com/static/downloads/install-release-cpolar.sh | sudo bash

或 cpolar短链接安装方式:(国外使用)

curl -sL https://git.io/cpolar | sudo bash

2.查看版本号,正常显示即为安装成功

cpolar version

3.安装cpolar服务

cpolar service install

4.启动cpolar服务

cpolar service start

5.检查是否启动服务成功

ps -ef | grep cpolar   # 列出所有Cpolar进程

6.注册账号、拿到token
在这里插入图片描述
7.token认证

cpolar authtoken xxxxxxxxxxxxxxxxxxxxxxx

后面就是开放9200端口号,因为我这里实例是docker容器,没有防火墙设置,所有就不做操作了

8.直接映射 9200

cpolar http 9200

在这里插入图片描述

9.进入web管理界面,进一步设置相关映射
在这里插入图片描述
这里就不赘述了
附:在线隧道列表和https://dashboard.cpolar.com/status链接状态相同

至此,写了api接口,就可以进行映射,让外网进行访问了

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值