config

package
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 25, 2025 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type StorageConfig

type StorageConfig struct {
	// 存储类型: local, s3, oss 等
	Type string `json:"type,optional"`
	// 本地存储路径或云存储 bucket
	Bucket string `json:"bucket,optional"`
	// 访问密钥
	AccessKey string `json:"access_key,optional"`
	// 密钥
	SecretKey string `json:"secret_key,optional"`
	// 区域
	Region string `json:"region,optional"`
	// CDN域名(可选)
	CdnDomain string `json:"cdn_domain,optional"`
}

StorageConfig 存储配置

type UploadConfig

type UploadConfig struct {
	// 最大文件大小(字节)
	MaxSize int64 `json:"max_size"`
	// 允许的文件类型
	AllowedTypes []string `json:"allowed_types"`
	// 基础上传路径
	BasePath string `json:"base_path"`
}

UploadConfig 上传限制配置

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL