Do not use WORKSPACE variable in buildCalicoContainers
We can checkout calico-containers to any directory, so we shouldn't
rely on WORKSPACE variable, instead build step should run in the
directory where calico-containers code was check-outed
Change-Id: I3f5f22f48dcbd49e0305663b5b5684db4bbaee91
diff --git a/vars/buildCalicoContainers.groovy b/vars/buildCalicoContainers.groovy
index c404bac..5cf959f 100644
--- a/vars/buildCalicoContainers.groovy
+++ b/vars/buildCalicoContainers.groovy
@@ -30,7 +30,7 @@
def bird6Url = config.bird6Url ?: "${artifactoryUrl}/mcp/calico-bird/bird6-${birdBuildId}"
def birdclUrl = config.birdclUrl ?: "${artifactoryUrl}/mcp/calico-bird/birdcl-${birdBuildId}"
- def gitCommit = sh(returnStdout: true, script: "git -C ${WORKSPACE} rev-parse --short HEAD").trim()
+ def gitCommit = sh(returnStdout: true, script: "git rev-parse --short HEAD").trim()
def build = "${config.containersBuildId}-${gitCommit}"