准备工具如下
- 申请Chat GPT 的key
https://github.com/chatanywhere/GPT_API_free - 开源Chat GPT 网页
https://github.com/Yidadaa/ChatGPT-Next-Web - 云服务器
https://idc.langlangy.com/server/purchase
申请key


开通linux服务器

安装docker
# 安装依赖
yum install -y yum-utils device-mapper-persistent-data lvm2
# 安装docker
yum install docker-ce docker-ce-clicontainerd.io

启动Docker并开机启动
systemctl start docker
systemctl enable docker.service

拉取镜像
docker pull yidadaa/chatgpt-next-web

部署容器
docker run -d -p 3000:3000 \
-e OPENAI_API_KEY="sk-你的key" \
-e BASE_URL=https://api.chatanywhere.com.cn \
yidadaa/chatgpt-next-web

关闭防火墙
systemctl stop firewalld.service
systemctl disable firewalld.service
在服务器添加端口转发


浏览器访问

去掉端口访问
换1块钱购买一台虚拟主机

你的域名绑定这个ip

这是腾讯云绑定的
添加域名
在云服务器里找到这个nat ip

在虚拟主机里添加反向代理

浏览器访问




