chatgpt-web docker部署

cooolr 于 2023-04-07 发布

项目地址: chatgpt-web

  1. 下拉镜像
docker pull chenzhaoyu94/chatgpt-web:latest
  1. OpenAI后台 获取api_key 或者 ChatGPT 获取accessToken
  2. 运行镜像
    1. api_key方式,收费,要指定翻墙代理,速度快,可以同时多人使用

       docker run -d --name chatgpt-web \
                  -it \
                  -p 3002:3002 \
                  -e OPENAI_API_KEY=xxxxxxxxxx \
                  -e AUTH_SECRET_KEY='password' \
                  -e VITE_GLOB_OPEN_LONG_REPLY=true \
       chenzhaoyu94/chatgpt-web:latest
      
    2. accessToken方式,免费,不需要指定翻墙代理,速度慢,同时只能发送一条消息

       docker run -d --name chatgpt-web \
                  -it \
                  -p 3002:3002 \
                  -e OPENAI_ACCESS_TOKEN=xxxxxxxxxx 
                  -e AUTH_SECRET_KEY='password' 
                  -e VITE_GLOB_OPEN_LONG_REPLY=true \
       chenzhaoyu94/chatgpt-web:latest
      
    3. 页面访问: http://0.0.0.0:3002