mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-04-06 04:15:46 +08:00
change log file mode
This commit is contained in:
parent
4529047349
commit
988824f3f1
@ -35,7 +35,8 @@ func loggerInit(moduleName string) *Logger {
|
|||||||
//All logs will be printed
|
//All logs will be printed
|
||||||
logger.SetLevel(logrus.Level(config.Config.Log.RemainLogLevel))
|
logger.SetLevel(logrus.Level(config.Config.Log.RemainLogLevel))
|
||||||
//Close std console output
|
//Close std console output
|
||||||
src, err := os.OpenFile(os.DevNull, os.O_APPEND|os.O_WRONLY, os.ModeAppend)
|
//os.O_WRONLY | os.O_CREATE | os.O_APPEND
|
||||||
|
src, err := os.OpenFile(os.DevNull, os.O_APPEND|os.O_RDWR|os.O_CREATE, os.ModeAppend)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err.Error())
|
panic(err.Error())
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user