From d6e2de9036a3e07476077533d042b405f69698e8 Mon Sep 17 00:00:00 2001 From: Bin Du Date: Mon, 20 Aug 2018 22:26:34 -0700 Subject: [PATCH] workaround the unpacking hang issue (#245) --- builder/context.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/builder/context.go b/builder/context.go index e0d9ad5d..bee79360 100644 --- a/builder/context.go +++ b/builder/context.go @@ -102,7 +102,9 @@ func (b *Builder) scrapeDependencies(ctx context.Context, volName string, stepWo scannerImageName, "scan", "-f", dockerfile, - "--destination", outputDir, + // NOTE (bindu): unpacking a tar file including .git folder can hang if --destination is a relative path + // Use the absolute path to workaround the issue. + "--destination", path.Join(normalizeWorkDir(stepWorkDir), outputDir), context, }