mirror of
https://github.com/jhillyerd/inbucket.git
synced 2025-12-21 11:37:07 +00:00
Make log level configurable
This commit is contained in:
@@ -7,6 +7,7 @@ import (
|
||||
"flag"
|
||||
"fmt"
|
||||
"github.com/jhillyerd/inbucket/config"
|
||||
"github.com/jhillyerd/inbucket/log"
|
||||
"github.com/jhillyerd/inbucket/smtpd"
|
||||
"github.com/jhillyerd/inbucket/web"
|
||||
"os"
|
||||
@@ -32,6 +33,10 @@ func main() {
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
// Configure logging
|
||||
level, _ := config.Config.String("logging", "level")
|
||||
log.SetLogLevel(level)
|
||||
|
||||
// Startup SMTP server
|
||||
server := smtpd.New()
|
||||
go server.Start()
|
||||
|
||||
Reference in New Issue
Block a user