Skip to main content
LibreChat is joining ClickHouse to power the open-source Agentic Data Stack 🎉 Learn more
LibreChat

ngrok

使用 Ngrok 将您的本地服务器隧道映射到互联网。

若要使用 ngrok 将本地服务器隧道映射到互联网,请按照以下步骤操作:

注册

  1. 前往 https://ngrok.com/ 并注册一个账户。

Docker 安装

  1. 从以下地址复制您的 auth token:https://dashboard.ngrok.com/get-started/your-authtoken
  2. 打开终端并运行以下命令:docker run -d -it -e NGROK_AUTHTOKEN=<your token> ngrok/ngrok http 80

Windows 安装

  1. 从以下地址下载 ZIP 文件:https://ngrok.com/download
  2. 使用 7zip 或 WinRar 解压 ZIP 文件的内容。
  3. 运行 ngrok.exe
  4. 从以下地址复制您的 auth token:https://dashboard.ngrok.com/get-started/your-authtoken
  5. ngrok.exe 终端中,运行以下命令:ngrok config add-authtoken <your token>
  6. 如果您尚未执行此操作,请正常启动 LibreChat。
  7. ngrok.exe 终端中,运行以下命令:ngrok http 3080

您将看到一个可用于访问 LibreChat 的链接。 ngrok-1

Linux 安装

  1. https://ngrok.com/download 复制命令,并选择正确的架构。
  2. 在终端中运行该命令
  3. 从以下地址复制您的 auth token:https://dashboard.ngrok.com/get-started/your-authtoken
  4. 运行以下命令:ngrok config add-authtoken <your token>
  5. 如果您尚未执行此操作,请正常启动 LibreChat。
  6. 运行以下命令:ngrok http 3080

Mac 安装

  1. 从以下地址下载 ZIP 文件:https://ngrok.com/download
  2. 使用合适的 Mac 应用程序(如 Unarchiver)解压 ZIP 文件内容。
  3. 打开终端。
  4. 使用 cd 命令导航到你解压 ngrok 的目录。
  5. 通过输入 ./ngrok 来运行 ngrok。
  6. 从以下地址复制您的 auth token:https://dashboard.ngrok.com/get-started/your-authtoken
  7. 在运行 ngrok 的终端中,输入以下命令:ngrok authtoken <your token>
  8. 如果您尚未执行此操作,请正常启动 LibreChat。
  9. 在运行 ngrok 的终端中,输入以下命令:./ngrok http 3080

这篇指南怎么样?