Log loader errors during resource accumulation

This commit is contained in:
Richard Marshall
2019-08-15 07:59:55 -07:00
parent 54f1952195
commit fe8ba8e44b

View File

@@ -9,6 +9,7 @@ import (
"bytes"
"encoding/json"
"fmt"
"log"
"strings"
"github.com/pkg/errors"
@@ -329,9 +330,11 @@ func (kt *KustTarget) accumulateResources(
return err
}
} else {
err = kt.accumulateFile(ra, path)
if err != nil {
return err
err2 := kt.accumulateFile(ra, path)
if err2 != nil {
// Log ldr.New() error to highlight git failures.
log.Print(err.Error())
return err2
}
}
}