mirror of
https://github.com/Buriburizaem0n/nezha_domains.git
synced 2026-02-06 21:50:05 +00:00
添加服务器 & 展示服务器
This commit is contained in:
@@ -26,7 +26,16 @@ func init() {
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
if dao.Conf.Debug {
|
||||
dao.DB = dao.DB.Debug()
|
||||
}
|
||||
dao.Cache = cache.New(5*time.Minute, 10*time.Minute)
|
||||
|
||||
initDB()
|
||||
}
|
||||
|
||||
func initDB() {
|
||||
dao.DB.AutoMigrate(model.Server{})
|
||||
}
|
||||
|
||||
func main() {
|
||||
|
||||
Reference in New Issue
Block a user