[VOL-3780] Upgrading per-patchset validation to use the new charts
Change-Id: I1858f22032dd7b00215f3af0b2ffb038d1615cc2
diff --git a/vars/buildVolthaComponent.groovy b/vars/buildVolthaComponent.groovy
new file mode 100644
index 0000000..c0e4163
--- /dev/null
+++ b/vars/buildVolthaComponent.groovy
@@ -0,0 +1,15 @@
+def call(String project) {
+ // project is the gerrit project name
+
+ if (project != 'voltha-system-tests' &&
+ project != 'voltha-helm-charts' &&
+ project != '') {
+
+ sh """
+ make -C $WORKSPACE/${project} DOCKER_REPOSITORY=voltha/ DOCKER_TAG=citest docker-build
+ """
+ } else {
+ println "The project ${project} does not require to be built."
+ }
+
+}