Merge pull request #9243 from ninjadq/change_file_permission_of_joblog

change the permission of job log file
This commit is contained in:
Wenkai Yin(尹文开) 2019-09-25 17:45:21 +08:00 committed by GitHub
commit ac17afac1f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -16,7 +16,7 @@ type FileLogger struct {
// NewFileLogger crates a new file logger
// nil might be returned
func NewFileLogger(level string, logPath string, depth int) (*FileLogger, error) {
f, err := os.OpenFile(logPath, os.O_CREATE|os.O_WRONLY, 0644)
f, err := os.OpenFile(logPath, os.O_CREATE|os.O_WRONLY, 0600)
if err != nil {
return nil, err
}