Cpolar實現內網穿透
- 業務需求
- 第一步:準備工作
- 1、關閉安全軟件
- 2、下載所需軟件
- 第二步:Nginx的配置
- 第三步:使用cpolar實現內網穿透
- 1、進入 https://dashboard.cpolar.com/get-started 注冊,登錄,完成身份證的實名認證
- 2、下載所需文件
- 3、將文件上傳到Linux中,并解壓縮
- 4、使用cpolar給的命令連接你的賬戶
- 第四步:測試
- 1、在端口80上啟動HTTP隧道
- 2、瀏覽器搜索這個網絡域名
業務需求
使用nginx建立網站
部署文檔:https://dashboard.cpolar.com/get-started
第一步:準備工作
1、關閉安全軟件
[root@master ~]# setenforce 0
[root@master ~]# systemctl stop firewalld
[root@master ~]# systemctl disable firewalld
2、下載所需軟件
[root@master ~]# yum install nginx httpd-tools -y
[root@master ~]# systemctl start nginx # 啟動httpd
[root@master ~]# systemctl enable nginx # 設置開機啟動
第二步:Nginx的配置
# 將網站利用Xftp上傳到master主機上,進行解壓縮
[root@master ~]# unzip wordpress-6.1-zh_CN.zip
[root@master ~]# vim /etc/nginx/nginx.conf #進入配置文件
[root@master ~]# systemctl restart nginx # 重啟服務
第三步:使用cpolar實現內網穿透
1、進入 https://dashboard.cpolar.com/get-started 注冊,登錄,完成身份證的實名認證
2、下載所需文件
3、將文件上傳到Linux中,并解壓縮
[root@master ~]# unzip /cpolar-stable-linux-amd64.zip
4、使用cpolar給的命令連接你的賬戶
第四步:測試
1、在端口80上啟動HTTP隧道
[root@master ~]# ./cpolar http 80