mirror of
https://github.com/DayuanJiang/next-ai-draw-io.git
synced 2026-01-03 06:42:27 +08:00
* docs: reorganize docs into en/cn/ja folders - Move documentation files into language-specific folders (en, cn, ja) - Add Chinese and Japanese translations for all docs - Extract Docker section from README to separate doc file - Update README to link to new doc locations * docs: fix links to new docs folder structure * docs: update README and provider docs * docs: fix broken import statements in cloudflare deploy guides * docs: sync CN/JA READMEs with EN structure and fix all paths
30 lines
923 B
Markdown
30 lines
923 B
Markdown
# 使用 Docker 运行
|
||
|
||
如果您只是想在本地运行,最好的方式是使用 Docker。
|
||
|
||
首先,如果您尚未安装 Docker,请先安装:[获取 Docker](https://docs.docker.com/get-docker/)
|
||
|
||
然后运行:
|
||
|
||
```bash
|
||
docker run -d -p 3000:3000 \
|
||
-e AI_PROVIDER=openai \
|
||
-e AI_MODEL=gpt-4o \
|
||
-e OPENAI_API_KEY=your_api_key \
|
||
ghcr.io/dayuanjiang/next-ai-draw-io:latest
|
||
```
|
||
|
||
或者使用环境变量文件:
|
||
|
||
```bash
|
||
cp env.example .env
|
||
# 编辑 .env 文件并填入您的配置
|
||
docker run -d -p 3000:3000 --env-file .env ghcr.io/dayuanjiang/next-ai-draw-io:latest
|
||
```
|
||
|
||
在浏览器中打开 [http://localhost:3000](http://localhost:3000)。
|
||
|
||
请将环境变量替换为您首选的 AI 提供商配置。查看 [AI 提供商](./ai-providers.md) 了解可用选项。
|
||
|
||
> **离线部署:** 如果无法访问 `embed.diagrams.net`,请参阅 [离线部署](./offline-deployment.md) 了解配置选项。
|