diff --git a/first-class-pipeline/src/com/freeleaps/devops/CommitMessageLinter.groovy b/first-class-pipeline/src/com/freeleaps/devops/CommitMessageLinter.groovy index a8d80db1..21176eb7 100644 --- a/first-class-pipeline/src/com/freeleaps/devops/CommitMessageLinter.groovy +++ b/first-class-pipeline/src/com/freeleaps/devops/CommitMessageLinter.groovy @@ -27,7 +27,7 @@ class CommitMessageLinter { steps.dir(steps.env.workspace) { // commit lint cli requires a git repository to lint commit messages, so we need make sure the workspace is a trusted git repository - steps.sh "git config --global --add safe.directory ${steps.env.WORKSPACE}/${steps.env.workspace}" + steps.sh "git config --global --add safe.directory ${steps.env.workspace}" steps.sh "commitlint --verbose -g ${rules} -f HEAD^" } } diff --git a/first-class-pipeline/src/com/freeleaps/devops/SourceFetcher.groovy b/first-class-pipeline/src/com/freeleaps/devops/SourceFetcher.groovy index 7f6495da..89a6bfec 100644 --- a/first-class-pipeline/src/com/freeleaps/devops/SourceFetcher.groovy +++ b/first-class-pipeline/src/com/freeleaps/devops/SourceFetcher.groovy @@ -16,7 +16,7 @@ class SourceFetcher { steps.error("serviceGitBranch is required") } - steps.env.workspace = "workspace" + steps.env.workspace = "${steps.env.WORKSPACE}/devops-workspace/${configurations.serviceName}" steps.dir(steps.env.workspace) { steps.git branch: configurations.serviceGitBranch, credentialsId: 'git-bot-credentials', url: configurations.serviceGitRepo