Revert "Remove redutant vars/ folder"
This reverts commit a78108cfd53931236d3ee2b32c6e48d4d8eb5c88.
Change-Id: Ibc42fdc12b942b72cb0538cfcef6b933fdaec51a
diff --git a/vars/buildCalicoContainers.txt b/vars/buildCalicoContainers.txt
new file mode 100644
index 0000000..ce54270
--- /dev/null
+++ b/vars/buildCalicoContainers.txt
@@ -0,0 +1,30 @@
+// Usage example
+// List of parameters with the default values
+ def dockerRepo = config.dockerRepo ?: "mcp-k8s-ci.docker.mirantis.net"
+ def artifactoryUrl = config.artifactoryURL ?: "https://artifactory.mcp.mirantis.net/artifactory/projectcalico"
+ def nodeImage = config.nodeImage ?: "calico/node"
+ def nodeImageTag = config.nodeImageTag ?: "v1.0.0-beta"
+ def ctlImage = config.ctlImage ?: "calico/ctl"
+ def ctlImageTag = config.ctlImageTag ?: "v1.0.0-beta"
+ def buildImage = config.buildImage ?: "${artifactoryURL}/mcp/libcalico/lastbuild".toURL().text.trim()
+ def felixImage = config.felixImage ?: "${artifactoryURL}/mcp/felix/lastbuild".toURL().text.trim()
+ def confdBuildId = config.confdBuildId ?: "${artifactoryURL}/mcp/confd/lastbuild".toURL().text.trim()
+ def confdUrl = config.confdUrl ?: "${artifactoryURL}/mcp/confd/confd-${confdBuildId}"
+ def birdBuildId = config.birdBuildId ?: "${artifactoryURL}/mcp/calico-bird/lastbuild".toURL().text.trim()
+ def birdUrl = config.birdUrl ?: "${artifactoryURL}/mcp/calico-bird/bird-${birdBuildId}"
+ def bird6Url = config.bird6Url ?: "${artifactoryURL}/mcp/calico-bird/bird6-${birdBuildId}"
+ def birdclUrl = config.birdclUrl ?: "${artifactoryURL}/mcp/calico-bird/birdcl-${birdBuildId}"
+ def build = "${config.containersBuildId}-${gitCommit}"
+
+// *** Examples 1:
+// we still use old schema and want to publish to GERRIT_CHANGE_NUMBER
+def buildId = ${GERRIT_CHANGE_NUMBER}
+// we want to store in artifacts from gate then
+def buildId = "mcp"
+node {
+ buildCalicoContainers {
+ dockerRepo = "mcp-k8s-ci.docker.mirantis.net"
+ artifactoryURL = "https://artifactory.mcp.mirantis.net/artifactory/sandbox"
+ containersBuildId = buildId
+ }
+}