-
Notifications
You must be signed in to change notification settings - Fork 82
Open
Description
Logger library is working as expected in Linux (Ubuntu 18.04 LTS) and in Mac os but
when I am running it in docker having alpine Linux as a base image, it is stuck at
logger.Init("foo", *verbose, true, lf)I am using its latest version by downloading it using go get github.com/google/logger
It's blocking the entire application as the func logger.Init() is not returning.
My implementation:
func mustInitLogger() *logger.Logger {
fmt.Printf("initializing x-microservice application log\n")
lf, err := os.OpenFile(logPath, os.O_CREATE|os.O_WRONLY|os.O_APPEND, 0644)
if err != nil {
panic(err)
}
fmt.Printf("log file created, initializing x-microservice logger instance\n")
logr := logger.Init("x-microservice", true, true, lf)
logger.SetFlags(log.LstdFlags)
fmt.Printf("log initialization done\n")
return logr
}Update:
When I switched to version v1.0.1, I get this error:
unix syslog delivery error
Metadata
Metadata
Assignees
Labels
No labels