Cloudflare setup:修订间差异
跳到导航
跳到搜索
(创建页面,内容为“ === 内网穿透 === Zero Trust -> Access -> Tunnels ==== HTTP ==== Create a tunnel # Name your tunnel TEST # Choose your environment # Install and run a connector https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-x86_64.rpm yum localinstall cloudflared.rpm cloudflared service install eyJhIjoiODNiYzVmMTQ2YzhmZGIyNmQ4ZDlkNTJlM2E1YjFmNWEiLCJ0IjoiM2IxMjAwMWEtYjk1My00MDRjLThkYjMtZDQ5ZTEwMDVhYmU1IiwicyI6Ik1EUm1OMlEyTW1ZdFlUVXh…”) |
无编辑摘要 |
||
第3行: | 第3行: | ||
Zero Trust -> Access -> Tunnels | Zero Trust -> Access -> Tunnels | ||
==== | ====Create a tunnel==== | ||
* Name your tunnel TEST | |||
* Choose your environment | |||
* Install and run a connector | |||
# 内网主机 | |||
https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-x86_64.rpm | https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-x86_64.rpm | ||
yum localinstall cloudflared.rpm | yum localinstall cloudflared.rpm | ||
cloudflared service install eyJhIjoiODNiYzVmMTQ2YzhmZGIyNmQ4ZDlkNTJlM2E1YjFmNWEiLCJ0IjoiM2IxMjAwMWEtYjk1My00MDRjLThkYjMtZDQ5ZTEwMDVhYmU1IiwicyI6Ik1EUm1OMlEyTW1ZdFlUVXhaUzAwTm1JMUxUa3hZMlV0TmpJME1tVmxaV0ptWkdZeiJ9 | cloudflared service install eyJhIjoiODNiYzVmMTQ2YzhmZGIyNmQ4ZDlkNTJlM2E1YjFmNWEiLCJ0IjoiM2IxMjAwMWEtYjk1My00MDRjLThkYjMtZDQ5ZTEwMDVhYmU1IiwicyI6Ik1EUm1OMlEyTW1ZdFlUVXhaUzAwTm1JMUxUa3hZMlV0TmpJME1tVmxaV0ptWkdZeiJ9 | ||
Public hostnames | ==== Public hostnames ==== | ||
===== HTTP ===== | |||
Add public hostname for <nowiki>http://localhost:8088</nowiki> | |||
p88.server.com --> <nowiki>http://127.0.0.1:8088</nowiki> | |||
===== SSH ===== | |||
* Add public hostname for localhost:22 | |||
ssh.server.com --> ssh://127.0.0.1:22 | |||
* Client | |||
# /usr/local/bin/cloudflared | |||
.ssh/config | |||
Host ssh.server.com | |||
ProxyCommand /usr/local/bin/cloudflared access ssh --hostname %h | |||
ssh ssh.server.com |
2023年12月26日 (二) 14:21的版本
内网穿透
Zero Trust -> Access -> Tunnels
Create a tunnel
- Name your tunnel TEST
- Choose your environment
- Install and run a connector
# 内网主机 https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-x86_64.rpm yum localinstall cloudflared.rpm cloudflared service install eyJhIjoiODNiYzVmMTQ2YzhmZGIyNmQ4ZDlkNTJlM2E1YjFmNWEiLCJ0IjoiM2IxMjAwMWEtYjk1My00MDRjLThkYjMtZDQ5ZTEwMDVhYmU1IiwicyI6Ik1EUm1OMlEyTW1ZdFlUVXhaUzAwTm1JMUxUa3hZMlV0TmpJME1tVmxaV0ptWkdZeiJ9
Public hostnames
HTTP
Add public hostname for http://localhost:8088
p88.server.com --> http://127.0.0.1:8088
SSH
- Add public hostname for localhost:22
ssh.server.com --> ssh://127.0.0.1:22
- Client
# /usr/local/bin/cloudflared .ssh/config Host ssh.server.com ProxyCommand /usr/local/bin/cloudflared access ssh --hostname %h ssh ssh.server.com