feat(obs): 支持华为云obs存储

This commit is contained in:
Li Xianggang
2026-05-18 18:54:57 +08:00
committed by lyingbug
parent 5cee0d0921
commit b3dbf86bf5
21 changed files with 626 additions and 30 deletions
+1 -1
View File
@@ -117,7 +117,7 @@ export interface KBModelConfigRequest {
multimodal: {
enabled: boolean
}
/** 存储引擎选择:"local" | "minio" | "cos",影响文档上传与文档内图片存储 */
/** 存储引擎选择:"local" | "minio" | "cos" | "obs" 等,影响文档上传与文档内图片存储 */
storageProvider?: string
nodeExtract: {
enabled: boolean
+11 -2
View File
@@ -118,7 +118,7 @@ export function reconnectDocReader(addr: string): Promise<ParserEnginesResponse
// ---- 存储引擎配置(租户级,供文档/图片存储与 docreader 使用) ----
export interface StorageEngineConfig {
default_provider: string // "local" | "minio" | "cos" | "tos" | "s3" | "oss" | "ks3"
default_provider: string // "local" | "minio" | "cos" | "tos" | "s3" | "oss" | "ks3" | "obs"
local: { path_prefix: string }
minio: { mode: string; endpoint: string; access_key_id: string; secret_access_key: string; bucket_name: string; use_ssl: boolean; path_prefix: string }
cos: {
@@ -164,6 +164,14 @@ export interface StorageEngineConfig {
bucket_name: string
path_prefix: string
}
obs: {
endpoint: string
region: string
access_key: string
secret_key: string
bucket_name: string
path_prefix: string
}
}
export interface StorageEngineStatusItem {
@@ -192,13 +200,14 @@ export function getStorageEngineStatus(): Promise<{ data: GetStorageEngineStatus
}
export interface StorageCheckRequest {
provider: string // "minio" | "cos" | "tos" | "s3" | "oss" | "ks3"
provider: string // "minio" | "cos" | "tos" | "s3" | "oss" | "ks3" | "obs"
minio?: StorageEngineConfig['minio']
cos?: StorageEngineConfig['cos']
tos?: StorageEngineConfig['tos']
s3?: StorageEngineConfig['s3']
oss?: StorageEngineConfig['oss']
ks3?: StorageEngineConfig['ks3']
obs?: StorageEngineConfig['obs']
}
export interface StorageCheckResponse {