mirror of
https://gitcode.com/ageerle/ruoyi-ai.git
synced 2026-11-11 21:40:41 +00:00
docs: improve Windows Docker deployment instructions
This commit is contained in:
36
README.md
36
README.md
@@ -75,9 +75,12 @@ This project provides two Docker deployment methods:
|
||||
### Method 1: One-click Start All Services (Recommended)
|
||||
|
||||
Use `docker-compose-all.yaml` to start all services at once (including backend, admin panel, user frontend, and dependencies):
|
||||
#### Requirements
|
||||
- Docker Engine(Linux/macOS)或 Docker Desktop(Windows)
|
||||
- Docker Compose V2
|
||||
|
||||
#### Linux / macOS
|
||||
```bash
|
||||
# Requirements: Docker Engine and Docker Compose V2
|
||||
|
||||
# Clone the v3.1.0 release
|
||||
git clone --depth 1 --branch v3.1.0 https://github.com/ageerle/ruoyi-ai.git
|
||||
@@ -103,6 +106,37 @@ docker compose --env-file docs/docker/ruoyi-ai/.env \
|
||||
# Backend API: http://SERVER_IP:26039
|
||||
```
|
||||
|
||||
#### Windows PowerShell
|
||||
If you are using Windows with Docker Desktop, you can use PowerShell to execute the following commands:
|
||||
|
||||
```PowerShell
|
||||
|
||||
# Clone the v3.1.0 release
|
||||
git clone --depth 1 --branch v3.1.0 https://github.com/ageerle/ruoyi-ai.git
|
||||
cd ruoyi-ai
|
||||
|
||||
# Create the environment configuration file
|
||||
Copy-Item docs\docker\ruoyi-ai\.env.example docs\docker\ruoyi-ai\.env
|
||||
|
||||
# Pin the image version
|
||||
(Get-Content docs\docker\ruoyi-ai\.env) `
|
||||
-replace '^RUIYI_VERSION=.*', 'RUIYI_VERSION=v3.1.0' |
|
||||
Set-Content docs\docker\ruoyi-ai\.env
|
||||
|
||||
# Check the environment configuration
|
||||
Get-Content docs\docker\ruoyi-ai\.env
|
||||
|
||||
# Pull pre-built images from GHCR and start all services
|
||||
docker compose --env-file docs\docker\ruoyi-ai\.env `
|
||||
-f docs\docker\ruoyi-ai\docker-compose-all.yaml pull
|
||||
docker compose --env-file docs\docker\ruoyi-ai\.env `
|
||||
-f docs\docker\ruoyi-ai\docker-compose-all.yaml up -d
|
||||
|
||||
# Check service status
|
||||
docker compose --env-file docs\docker\ruoyi-ai\.env `
|
||||
-f docs\docker\ruoyi-ai\docker-compose-all.yaml ps
|
||||
```
|
||||
|
||||
The default Compose file also publishes MySQL (`23306`), Redis (`26379`),
|
||||
Weaviate (`28080`), and MinIO (`29000`/`29090`). For production deployments,
|
||||
change the default MySQL and MinIO passwords and expose only the application
|
||||
|
||||
36
README_ZH.md
36
README_ZH.md
@@ -76,10 +76,13 @@
|
||||
### 方式一:一键启动所有服务(推荐)
|
||||
|
||||
使用 `docker-compose-all.yaml` 可以一键启动所有服务(包括后端、管理端、用户端及依赖服务):
|
||||
#### 环境要求
|
||||
|
||||
- Docker Engine(Linux/macOS)或 Docker Desktop(Windows)
|
||||
- Docker Compose V2
|
||||
|
||||
#### Linux / macOS
|
||||
```bash
|
||||
# 环境要求:Docker Engine 和 Docker Compose V2
|
||||
|
||||
# 克隆 v3.1.0 版本
|
||||
git clone --depth 1 --branch v3.1.0 https://github.com/ageerle/ruoyi-ai.git
|
||||
cd ruoyi-ai
|
||||
@@ -104,6 +107,35 @@ docker compose --env-file docs/docker/ruoyi-ai/.env \
|
||||
# 后端API: http://SERVER_IP:26039
|
||||
```
|
||||
|
||||
#### Windows PowerShell
|
||||
如果您使用 Windows + Docker Desktop,可以使用 PowerShell 执行以下命令:
|
||||
```PowerShell
|
||||
# 克隆 v3.1.0 版本
|
||||
git clone --depth 1 --branch v3.1.0 https://github.com/ageerle/ruoyi-ai.git
|
||||
cd ruoyi-ai
|
||||
|
||||
# 创建环境配置文件
|
||||
Copy-Item docs\docker\ruoyi-ai\.env.example docs\docker\ruoyi-ai\.env
|
||||
|
||||
# 固定镜像版本
|
||||
(Get-Content docs\docker\ruoyi-ai\.env) `
|
||||
-replace '^RUIYI_VERSION=.*', 'RUIYI_VERSION=v3.1.0' |
|
||||
Set-Content docs\docker\ruoyi-ai\.env
|
||||
|
||||
# 查看环境配置
|
||||
Get-Content docs\docker\ruoyi-ai\.env
|
||||
|
||||
# 从 GHCR 拉取预构建镜像并启动全部服务
|
||||
docker compose --env-file docs\docker\ruoyi-ai\.env `
|
||||
-f docs\docker\ruoyi-ai\docker-compose-all.yaml pull
|
||||
docker compose --env-file docs\docker\ruoyi-ai\.env `
|
||||
-f docs\docker\ruoyi-ai\docker-compose-all.yaml up -d
|
||||
|
||||
# 查看服务状态
|
||||
docker compose --env-file docs\docker\ruoyi-ai\.env `
|
||||
-f docs\docker\ruoyi-ai\docker-compose-all.yaml ps
|
||||
```
|
||||
|
||||
默认 Compose 还会发布 MySQL(`23306`)、Redis(`26379`)、Weaviate(`28080`)和
|
||||
MinIO(`29000`/`29090`)端口。生产环境请修改 MySQL 和 MinIO 默认密码,并通过防火墙或反向代理只开放应用端口。
|
||||
|
||||
|
||||
Reference in New Issue
Block a user