mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-11-27 04:11:03 +00:00
improve gin logging
This commit is contained in:
parent
1fb47612c0
commit
3235990584
2 changed files with 5 additions and 1 deletions
2
drone.go
2
drone.go
|
@ -33,6 +33,8 @@ func main() {
|
|||
// debug level if requested by user
|
||||
if *debug {
|
||||
logrus.SetLevel(logrus.DebugLevel)
|
||||
} else {
|
||||
logrus.SetLevel(logrus.WarnLevel)
|
||||
}
|
||||
|
||||
// Load the configuration from env file
|
||||
|
|
|
@ -17,7 +17,9 @@ import (
|
|||
)
|
||||
|
||||
func Load(middleware ...gin.HandlerFunc) http.Handler {
|
||||
e := gin.Default()
|
||||
e := gin.New()
|
||||
e.Use(gin.Recovery())
|
||||
|
||||
e.SetHTMLTemplate(template.Load())
|
||||
e.StaticFS("/static", static.FileSystem())
|
||||
|
||||
|
|
Loading…
Reference in a new issue