Skip to content

Commit 8a64fd4

Browse files
committed
Merge pull request docker-archive-public#2528 from jhoos/vmwarefusion-umask
Explicitly set umask before invoking vmrun in vmwarefusion
2 parents 95bd94d + d5ff6b2 commit 8a64fd4

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

drivers/vmwarefusion/vmrun.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import (
1212
"os/exec"
1313
"path/filepath"
1414
"strings"
15+
"syscall"
1516

1617
"github.com/docker/machine/libmachine/log"
1718
)
@@ -36,6 +37,9 @@ func setVmwareCmd(cmd string) string {
3637
}
3738

3839
func vmrun(args ...string) (string, string, error) {
40+
// vmrun with nogui on VMware Fusion through at least 8.0.1 doesn't work right
41+
// if the umask is set to not allow world-readable permissions
42+
_ = syscall.Umask(022)
3943
cmd := exec.Command(vmrunbin, args...)
4044
if os.Getenv("MACHINE_DEBUG") != "" {
4145
cmd.Stdout = os.Stdout

0 commit comments

Comments
 (0)