mirror of
https://github.com/hashicorp/packer.git
synced 2026-06-10 09:10:27 -04:00
post-processor/vagrant: check for error when tarring earlier
This commit is contained in:
parent
09f2fbf9f9
commit
857beb6167
1 changed files with 5 additions and 0 deletions
|
|
@ -40,6 +40,11 @@ func DirToBox(dst, dir string) error {
|
|||
|
||||
// This is the walk func that tars each of the files in the dir
|
||||
tarWalk := func(path string, info os.FileInfo, prevErr error) error {
|
||||
// If there was a prior error, return it
|
||||
if prevErr != nil {
|
||||
return prevErr
|
||||
}
|
||||
|
||||
// Skip directories
|
||||
if info.IsDir() {
|
||||
log.Printf("Skiping directory '%s' for box '%s'", path, dst)
|
||||
|
|
|
|||
Loading…
Reference in a new issue