Merge pull request #6791 from mheon/fix_service_umask

Ensure umask is set appropriately for 'system service'
This commit is contained in:
OpenShift Merge Robot 2020-06-29 04:48:44 -04:00 committed by GitHub
commit 6213488d2b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -173,6 +173,10 @@ func (s *APIServer) Serve() error {
}()
}
// Before we start serving, ensure umask is properly set for container
// creation.
_ = syscall.Umask(0022)
go func() {
err := s.Server.Serve(s.Listener)
if err != nil && err != http.ErrServerClosed {