From 065688b98f19e6a15ae3120c74591aa51acb50cc Mon Sep 17 00:00:00 2001 From: Jyotsna Date: Wed, 11 Nov 2020 20:35:08 +0530 Subject: [PATCH] Fixed link to dockerfile Signed-off-by: Jyotsna --- dist/index.js | 3 ++- src/context.ts | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/dist/index.js b/dist/index.js index a945c4a..0591883 100644 --- a/dist/index.js +++ b/dist/index.js @@ -12092,7 +12092,8 @@ function getInputs(defaultContext) { userInputs.outputs.find(val => val.indexOf('type=image') > -1 || val.indexOf('type=registry') > -1))) { //Add link to dockerfile as label let dockerfilePath = userInputs.file; - userInputs.labels.push(`dockerfile-path=${defaultContext}/${dockerfilePath}`); + let repoPath = defaultContext.replace('#head', '/blob'); + userInputs.labels.push(`dockerfile-path=${repoPath}/${dockerfilePath}`); } return userInputs; }); diff --git a/src/context.ts b/src/context.ts index dcf266f..a6adfce 100644 --- a/src/context.ts +++ b/src/context.ts @@ -85,7 +85,8 @@ export async function getInputs(defaultContext: string): Promise { ) { //Add link to dockerfile as label let dockerfilePath = userInputs.file; - userInputs.labels.push(`dockerfile-path=${defaultContext}/${dockerfilePath}`); + let repoPath = defaultContext.replace('#head', '/blob'); + userInputs.labels.push(`dockerfile-path=${repoPath}/${dockerfilePath}`); } return userInputs;