add log config and gorm config

This commit is contained in:
landaiqing
2024-08-03 22:09:19 +08:00
parent 908a9d10f2
commit 3dac34d307
10 changed files with 232 additions and 31 deletions

14
global/global.go Normal file
View File

@@ -0,0 +1,14 @@
package global
import (
"github.com/sirupsen/logrus"
"gorm.io/gorm"
"schisandra-cloud-album/config"
)
// Config 全局配置文件
var (
CONFIG *config.Config
DB *gorm.DB
LOG *logrus.Logger
)