mirror of https://github.com/kubernetes/kops.git
Merge pull request #4316 from justinsb/copytree_fix_dest_not_exists
VFS: Fix bug in CopyTree when dest does not exist
This commit is contained in:
commit
b48ed40551
|
@ -224,7 +224,9 @@ func CopyTree(src Path, dest Path, aclOracle ACLOracle) error {
|
|||
|
||||
destFiles, err := dest.ReadTree()
|
||||
if err != nil {
|
||||
return fmt.Errorf("error reading source directory %q: %v", src, err)
|
||||
if !os.IsNotExist(err) {
|
||||
return fmt.Errorf("error reading source directory %q: %v", src, err)
|
||||
}
|
||||
}
|
||||
|
||||
destFileMap := make(map[string]Path)
|
||||
|
|
Loading…
Reference in New Issue