Files
assets/config.yml

110 lines
3.0 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
server:
address: ":3003"
name: "assets"
workerId: 1
#logPath: "resource/log/server"
logStdout: true
errorStack: true
#errorLogEnabled: true
#errorLogPattern: "error-{Ymd}.log"
#accessLogEnabled: true
#accessLogPattern: "access-{Ymd}.log"
rate:
limit: 200
burst: 300
# Database.
database:
default:
- type: "pgsql"
host: "116.204.74.41"
port: "15432"
user: "postgres"
pass: "123456"
name: "assets"
role: "master"
maxIdle: "5"
maxOpen: "20"
maxLifetime: "60s"
charset: "utf8mb4" #数据库编码
debug: true
dryRun: false #空跑
createdAt: "created_at" # (可选)自动创建时间字段名称
updatedAt: "updated_at" # (可选)自动更新时间字段名称
deletedAt: "deleted_at" # (可选)软删除时间字段名称
timeMaintainDisabled: false # (可选)是否完全关闭时间更新特性为true时CreatedAt/UpdatedAt/DeletedAt都将失效
- type: "pgsql"
host: "116.204.74.41"
port: "15432"
user: "postgres"
pass: "123456"
name: "assets"
role: "slave"
maxIdle: "5"
maxOpen: "20"
maxLifetime: "60s"
charset: "utf8mb4" #数据库编码
debug: true
dryRun: false #空跑
createdAt: "created_at" # (可选)自动创建时间字段名称
updatedAt: "updated_at" # (可选)自动更新时间字段名称
deletedAt: "deleted_at" # (可选)软删除时间字段名称
timeMaintainDisabled: false # (可选)是否完全关闭时间更新特性为true时CreatedAt/UpdatedAt/DeletedAt都将失效
tenant-1:
- type: "pgsql" # 使用自定义驱动,自动赋值创建人/修改人/租户ID
host: "116.204.74.41"
port: "15432"
user: "postgres"
pass: "123456"
name: "tenant"
role: "master"
maxIdle: "5"
maxOpen: "20"
maxLifetime: "60s"
charset: "utf8" #数据库编码
debug: true
dryRun: false #空跑
createdAt: "created_at" # (可选)自动创建时间字段名称
updatedAt: "updated_at" # (可选)自动更新时间字段名称
deletedAt: "deleted_at" # (可选)软删除时间字段名称
timeMaintainDisabled: false # (可选)是否完全关闭时间更新特性为true时CreatedAt/UpdatedAt/DeletedAt都将失效
redis:
# 集群模式配置方法
default:
address: 116.204.74.41:6379
db: 0
idleTimeout: "60s"
maxConnLifetime: "90s"
waitTimeout: "60s"
dialTimeout: "30s"
readTimeout: "30s"
writeTimeout: "30s"
maxActive: 100
test:
address: 116.204.74.41:6379
db: 1
idleTimeout: "60s"
maxConnLifetime: "90s"
waitTimeout: "60s"
dialTimeout: "30s"
readTimeout: "30s"
writeTimeout: "30s"
maxActive: 100
consul:
address: 116.204.74.41:8500
jaeger:
addr: 116.204.74.41:4318
nats:
default:
url: "nats://116.204.74.41:4222"
# 文件上传服务地址与oss模块minio中的endpoint一致
filePrefix: "116.204.74.41:9000"
cache:
localTTL: 60
redisTTL: 300