白嫖服务器搭链式代理,顺治AI降智 | Free VPS + WARP? My GPT is suddenly not dumb
想让流媒体秒开、GPT 不犯迷糊,其实就是给自己的网络请了个"私人跑腿"——3X-UI 在服务器上开门面,Hysteria2 装成正经 HTTPS 一路飙车,Karing 在你设备上当调度员:国内的走近路、国外的抄小道、该加密的绝不裸奔。免费云服务器省下奶茶钱,隐私也不用交给陌生人。唯一的小脾气:办服务器要刷张卡验明正身(不扣钱,走个过场),偶尔还得哄它别"闹容量"。搭好一次,从此告别转圈圈。
Making Streaming load instantly and keeping GPT from acting dazed is really just hiring a personal courier for your packets—3X-UI runs the shopfront on your server, Hysteria2 dresses up as polite HTTPS and floors it, and Karing plays dispatcher on your device: local traffic takes the shortcut, overseas traffic the scenic route, nothing rides naked. A free cloud server saves your boba money and keeps privacy out of strangers' hands. Its one quirk: the server wants a card to prove you're real (no charge, just a formality) and occasionally sulks about "capacity." Set it up once, and wave goodbye to the spinning wheel.
操作步骤
1. 开免费服务器:注册 Oracle Cloud Always Free,创建一台 Ubuntu 实例(ARM Ampere A1 或 x86 E2 Micro 都行),澳洲区 ARM 可用性较好。放行安全组入站 UDP/TCP 443。/ Sign up for Oracle Cloud Always Free, spin up an Ubuntu instance (ARM Ampere A1 or x86 E2 Micro both work; ARM availability is better in the Australia region). Allow inbound UDP/TCP 443 in the security list.
2. 装 3X-UI:SSH 上去跑官方一键脚本
`bash <(curl -Ls https://raw.githubusercontent.com/mhsanaei/3x-ui/master/install.sh)`
装完浏览器打开 `http://服务器IP:面板端口` 登录。/ SSH into your VPS and run the official one‑liner:
bash <(curl -Ls https://raw.githubusercontent.com/mhsanaei/3x-ui/master/install.sh)
After installation, open http://<your‑server‑IP>:<panel‑port> in your browser to log in.
3. 建 Hysteria2 入站:面板"入站"→新增 Hysteria2,端口 443、设强密码、伪装(masquerade)域名填 `www.bing.com` 一类正常站;没有域名就用自签证书(客户端那边勾"跳过证书验证")。/ In the panel, go to "Inbounds" → add a new Hysteria2 inbound. Set port 443, a strong password, and a masquerade domain (e.g., www.bing.com). If you don't have a domain, use a self‑signed certificate (just tick "skip certificate verification" on the client side).
4. 配链式代理(免费第二跳):面板"出站"里加一个 WARP 出站,再在"路由"里把 `openai / chatgpt` 域名指到 WARP 出站——这样 GPT 走干净 IP 不降智;其余流量直接从 VPS 出。这一步就把"链式代理/中继 + 服务端分流"都覆盖了。/ Add a WARP outbound in the panel's "Outbounds" section, then in "Routing" point openai / chatgpt domains to that WARP outbound – this gives GPT a clean IP so it stops acting dumb. All other traffic exits directly from your VPS. This one step covers both "chained proxy / relay" and server‑side routing.
5. 拿分享链接:面板给该客户端生成 `hysteria2://` 分享链接或二维码。/ Let the panel generate a hysteria2:// share link or QR code for this client.
6. Karing 导入 + 客户端分流:手机/电脑装 Karing → 导入上面的节点 → 打开"分流规则",设为 `国内直连 + 国外代理`,并把 YouTube、OpenAI 归到代理组。开启后 YouTube 秒开、GPT 不降智。/ Install Karing on your phone/PC → import the node above → open "Routing Rules" and set it to Direct for domestic + Proxy for foreign, then assign YouTube and OpenAI to the proxy group. Once enabled, YouTube loads instantly and GPT stays sharp.
7. Python 收尾验证(见下)/ See python code below:
```python
# proxy_kit.py — 生成节点导入二维码 + 验证代理是否真的通
# 安装依赖(走公司内部 registry,不走公网 pypi):
# pip install requests qrcode pillow --index-url https://nexus.apps.origin.com.au/repository/shared-pypi-proxy/simple
import time, requests, qrcode
# ==== 填你在 3X-UI 里拿到的 Hysteria2 节点信息 ====
CFG = {
"server": "your.vps.ip.or.domain",
"port": 443,
"password": "your-strong-password",
"sni": "www.bing.com", # 3X-UI 里设置的伪装域名/SNI
"name": "MyHysteria2",
}
def build_uri(c):
return (f"hysteria2://{c['password']}@{c['server']}:{c['port']}"
f"/?sni={c['sni']}&insecure=0#{c['name']}")
def make_qr(uri, path="node.png"):
qrcode.make(uri).save(path)
print(f"[✓] 二维码已保存:{path}(手机 Karing 扫码即可导入)")
def check(label, url):
try:
t = time.time()
r = requests.get(url, timeout=8)
print(f"[✓] {label} 可达,状态 {r.status_code},耗时 {int((time.time()-t)*1000)}ms")
except Exception as e:
print(f"[×] {label} 不可达:{e}")
if __name__ == "__main__":
uri = build_uri(CFG)
print("分享链接:", uri)
make_qr(uri)
print("\n--- 连接测试(请先在 Karing 里连上,TUN 模式会让本脚本也走代理)---")
try:
ip = requests.get("https://api.ipify.org?format=json", timeout=8).json()["ip"]
print(f"[✓] 当前出口 IP:{ip}(应是服务器/WARP 的 IP,不是你家宽带 IP)")
except Exception as e:
print(f"[×] 取出口 IP 失败:{e}")
check("YouTube", "https://www.youtube.com")
check("OpenAI", "https://chat.openai.com")
```
相关链接(Related Links):
https://github.com/MHSanaei/3x-ui
https://karing.app
https://github.com/KaringX/karing
https://github.com/apernet/hysteria
https://v2.hysteria.network
https://github.com/SagerNet/sing-box
https://github.com/KaringX/karing-ruleset
https://www.oracle.com/cloud/free/
https://developers.cloudflare.com/warp-client/
评论
发表评论