From f3685c999ea6957d3ef0a09a11fe01ffd900d99f Mon Sep 17 00:00:00 2001 From: "Alexander \"Arav\" Andreev" Date: Mon, 7 Feb 2022 21:50:38 +0400 Subject: [PATCH] An octal repr of permissions is supposed to be used here for working correctly. --- pkg/logging/logger.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/logging/logger.go b/pkg/logging/logger.go index c6683c4..ce7d435 100644 --- a/pkg/logging/logger.go +++ b/pkg/logging/logger.go @@ -20,7 +20,7 @@ type Logger struct { // NewLogger creates a Logger instance with given filename and // toStdout tells wether to write to Stdout as well or not. func NewLogger(path string, toStdout bool) (*Logger, error) { - f, err := os.OpenFile(path, os.O_WRONLY|os.O_APPEND|os.O_CREATE, os.ModeAppend) + f, err := os.OpenFile(path, os.O_WRONLY|os.O_APPEND|os.O_CREATE, 0660) if err != nil { return nil, errors.Wrap(err, "failed to open log file") }