fix: 168 include error message from docker SDK

This commit is contained in:
Casey Lee 2020-04-22 23:04:28 -07:00
parent b95fdb896f
commit 6c4e7b9fde
No known key found for this signature in database
GPG Key ID: 1899120ECD0A1784
1 changed files with 2 additions and 1 deletions

View File

@ -8,6 +8,7 @@ import (
"github.com/docker/docker/api/types"
"github.com/docker/docker/client"
"github.com/nektos/act/pkg/common"
"github.com/pkg/errors"
log "github.com/sirupsen/logrus"
)
@ -32,7 +33,7 @@ func NewDockerPullExecutor(input NewDockerPullExecutorInput) common.Executor {
imageExists, err := ImageExistsLocally(ctx, input.Image)
log.Debugf("Image exists? %v", imageExists)
if err != nil {
return fmt.Errorf("unable to determine if image already exists for image %q", input.Image)
return errors.WithMessagef(err, "unable to determine if image already exists for image %q", input.Image)
}
if !imageExists {