Feat: send remote uploading callback

This commit is contained in:
HFO4
2019-12-29 17:04:08 +08:00
parent 5b9de0e097
commit 64342fa88d
11 changed files with 405 additions and 13 deletions

View File

@@ -22,7 +22,13 @@ type system struct {
Listen string `validate:"required"`
Debug bool
SessionSecret string
SlaveSecret string `validate:"omitempty,gte=64"`
}
// slave 作为slave存储端配置
type slave struct {
Secret string `validate:"omitempty,gte=64"`
CallbackTimeout int `validate:"omitempty,gte=1"`
SignatureTTL int `validate:"omitempty,gte=1"`
}
// captcha 验证码配置
@@ -82,6 +88,7 @@ func Init(path string) {
"Redis": RedisConfig,
"Thumbnail": ThumbConfig,
"CORS": CORSConfig,
"Slave": SlaveConfig,
}
for sectionName, sectionStruct := range sections {
err = mapSection(sectionName, sectionStruct)