Remove os.Umask from overlay.BuildOverlayIndir
Adds tests to ensure that the overlay image contains the correct permissions. Signed-off-by: Jonathon Anderson <janderson@ciq.com>
This commit is contained in:
@@ -10,7 +10,6 @@ import (
|
||||
"path/filepath"
|
||||
"regexp"
|
||||
"strings"
|
||||
"syscall"
|
||||
"text/template"
|
||||
|
||||
"github.com/Masterminds/sprig/v3"
|
||||
@@ -251,9 +250,6 @@ func BuildOverlayIndir(nodeData node.Node, overlayNames []string, outputDir stri
|
||||
return fmt.Errorf("overlay names contains illegal characters: %v", overlayNames)
|
||||
}
|
||||
|
||||
// Temporarily set umask to 0000, so directories in the overlay retain permissions
|
||||
defer syscall.Umask(syscall.Umask(0))
|
||||
|
||||
wwlog.Verbose("Processing node/overlays: %s/%s", nodeData.Id(), strings.Join(overlayNames, ","))
|
||||
for _, overlayName := range overlayNames {
|
||||
wwlog.Verbose("Building overlay %s for node %s in %s", overlayName, nodeData.Id(), outputDir)
|
||||
|
||||
Reference in New Issue
Block a user