Merge pull request #389 from nan-yu/release-3.x

Grant read access for the error file to all users
This commit is contained in:
Kubernetes Prow Robot 2021-05-26 14:47:39 -07:00 committed by GitHub
commit 0ae9a0a8c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -240,6 +240,9 @@ func (l *customLogger) writeContent(content []byte) {
l.Logger.Error(err, "can't rename to error-file", "temp-file", tmpFile.Name(), "error-file", errorFile)
return
}
if err := os.Chmod(errorFile, 0644) ; err != nil {
l.Logger.Error(err, "can't change the mod of the error-file", "error-file", errorFile)
}
}
// deleteErrorFile deletes the error file.