Documentation
¶
Index ¶
Constants ¶
View Source
const ( VarPath string = "var" LogPath = VarPath + "/logs" TempPath = VarPath + "/tmp" )
View Source
const ( FiveMB int64 = 5 * 1024 * 1024 // 5MB TwentyMB int64 = 20 * 1024 * 1024 // 20MB HundredMB int64 = 100 * 1024 * 1024 // 100MB )
Variables ¶
View Source
var AmsFileAllow = struct { Image FileAllow Audio FileAllow Video FileAllow RewardFile FileAllow }{ Image: FileAllow{AllowMimeType: []string{"png", "jpg", "jpeg", "gif", "bmp"}, AllowCapacitySize: FiveMB}, Audio: FileAllow{AllowMimeType: []string{"mp3", "wav", "flac", "mid", "mov", "m4a"}, AllowCapacitySize: TwentyMB}, Video: FileAllow{AllowMimeType: []string{"mp4", "mpg", "avi", "wmv", "mov", "flv", "rmvb", "3gp", "m4v", "mkv"}, AllowCapacitySize: HundredMB}, RewardFile: FileAllow{AllowMimeType: []string{"xlsx", "xls"}, AllowCapacitySize: FiveMB}, }
AmsFileAllow 管理端上传限制
View Source
var AnonymousFileAllow = struct { File FileAllow }{ File: FileAllow{AllowMimeType: []string{"pdf", "doc", "docx", "ppt", "pptx", "xls", "xlsx"}, AllowCapacitySize: TwentyMB}, }
AnonymousFileAllow 匿名用户上传限制
View Source
var App *appConfig
View Source
var Cache *cache
View Source
var Database *database
View Source
var Etcd *etcd
View Source
var Filesystem *filesystem
View Source
var MessageQueue *messageQueue
View Source
var Monitor *monitor
View Source
var Redis *redis
View Source
var Server *serverConfig
View Source
var ThirdParty *thirdParty
View Source
var UserFileAllow = struct { Image FileAllow Audio FileAllow Video FileAllow }{ Image: FileAllow{AllowMimeType: []string{"png", "jpg", "jpeg", "gif"}, AllowCapacitySize: FiveMB}, Audio: FileAllow{AllowMimeType: []string{"mp3", "wav", "flac", "mid", "mov", "m4a"}, AllowCapacitySize: TwentyMB}, Video: FileAllow{AllowMimeType: []string{"mp4", "mpg", "avi", "wmv", "mov", "flv", "rmvb", "3gp", "m4v", "mkv"}, AllowCapacitySize: HundredMB}, }
UserFileAllow 终端用户上传限制
Functions ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.