chore(release): 升级版本至 4.8.0
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# Docker Compose 一键安装中间件 MySQL、Redis、MinIO、Xxl-Job
|
||||
# Docker Compose 一键安装中间件 MySQL、Redis、RustFS、Xxl-Job
|
||||
#
|
||||
# 安装:docker compose up -d
|
||||
# 卸载:docker compose down(加 -v 同时删除数据卷)
|
||||
@@ -8,6 +8,7 @@
|
||||
# - MySQL 首次启动时自动执行 ./sql 下初始化脚本(仅首次,数据卷已存在时跳过)
|
||||
# - 中间件配置全部内联于 command 参数,无需外部配置文件
|
||||
# - 数据持久化使用命名卷(docker volume 统一管理),不污染项目目录
|
||||
# - RustFS 兼容 MinIO 磁盘格式与 S3 协议(MinIO 社区版已于 2026 年停止维护)
|
||||
|
||||
name: youlai-boot
|
||||
|
||||
@@ -41,18 +42,17 @@ services:
|
||||
ports:
|
||||
- 6379:6379
|
||||
|
||||
minio:
|
||||
image: minio/minio:RELEASE.2024-07-16T23-46-41Z
|
||||
container_name: minio
|
||||
rustfs:
|
||||
image: rustfs/rustfs:latest
|
||||
container_name: rustfs
|
||||
restart: unless-stopped
|
||||
command: server /data --console-address ":9001"
|
||||
environment:
|
||||
- TZ=Asia/Shanghai
|
||||
- LANG=en_US.UTF-8
|
||||
- MINIO_ROOT_USER=minioadmin
|
||||
- MINIO_ROOT_PASSWORD=minioadmin
|
||||
- RUSTFS_ACCESS_KEY=rustfs-admin
|
||||
- RUSTFS_SECRET_KEY=rustfs-admin
|
||||
volumes:
|
||||
- youlai-minio-data:/data
|
||||
- youlai-rustfs-data:/data
|
||||
ports:
|
||||
- 9000:9000
|
||||
- 9001:9001
|
||||
@@ -71,5 +71,5 @@ services:
|
||||
volumes:
|
||||
youlai-mysql-data:
|
||||
youlai-redis-data:
|
||||
youlai-minio-data:
|
||||
youlai-rustfs-data:
|
||||
youlai-xxljob-logs:
|
||||
|
||||
5
pom.xml
5
pom.xml
@@ -6,7 +6,7 @@
|
||||
|
||||
<groupId>com.youlai</groupId>
|
||||
<artifactId>youlai-boot</artifactId>
|
||||
<version>4.7.0</version>
|
||||
<version>4.8.0</version>
|
||||
<description>基于 Java 17 + SpringBoot 4 + Spring Security 构建的权限管理系统。</description>
|
||||
|
||||
<parent>
|
||||
@@ -39,6 +39,7 @@
|
||||
|
||||
<!-- 对象存储 -->
|
||||
<okhttp3.version>4.12.0</okhttp3.version>
|
||||
<aws-sdk-s3.version>2.54.2</aws-sdk-s3.version>
|
||||
|
||||
<aliyun-sdk-oss.version>3.16.3</aliyun-sdk-oss.version>
|
||||
|
||||
@@ -217,7 +218,7 @@
|
||||
<dependency>
|
||||
<groupId>software.amazon.awssdk</groupId>
|
||||
<artifactId>s3</artifactId>
|
||||
<version>2.54.2</version>
|
||||
<version>${aws-sdk-s3.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!-- 阿里云 OSS 对象存储 -->
|
||||
|
||||
@@ -10,28 +10,44 @@ import java.util.Set;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 文件存储顶层配置:存储类型与上传限制。
|
||||
* 文件存储配置。
|
||||
* <p>
|
||||
* rustfs / aliyun / local 子树由各自 {@code FileService} 实现类绑定,
|
||||
* 此处仅承载 {@code type} 与 {@code upload}。
|
||||
* 绑定前缀 {@code file-storage},承载存储类型与上传限制;
|
||||
* rustfs / aliyun / local 子配置由各自的 {@code FileService} 实现类绑定。
|
||||
*
|
||||
* @author youlai.tech
|
||||
*/
|
||||
@Data
|
||||
@Component
|
||||
@ConfigurationProperties(prefix = "file-storage")
|
||||
public class FileStorageProperties {
|
||||
|
||||
/** 存储类型:rustfs | aliyun | local */
|
||||
/**
|
||||
* 存储类型,决定激活哪个 FileService 实现。
|
||||
* <p>
|
||||
* 可选值:rustfs、aliyun、local。
|
||||
*/
|
||||
private String type;
|
||||
|
||||
/** 上传限制 */
|
||||
private Upload upload = new Upload();
|
||||
|
||||
/**
|
||||
* 上传限制,绑定前缀 {@code file-storage.upload}。
|
||||
*/
|
||||
@Data
|
||||
public static class Upload {
|
||||
|
||||
/** 单文件大小上限,如 50MB;同时作为 spring.servlet.multipart 的上限 */
|
||||
/**
|
||||
* 单文件大小上限,如 50MB。
|
||||
* <p>
|
||||
* 同时作为 spring.servlet.multipart 的上限,单一来源。
|
||||
*/
|
||||
private String maxFileSize;
|
||||
|
||||
/** 允许的文件扩展名白名单(置空表示不限制) */
|
||||
/**
|
||||
* 允许的文件扩展名白名单,置空表示不限制。
|
||||
*/
|
||||
private List<String> allowedExtensions;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user