Merge "Use shorter commit hash in OMEC repo docker tags."
diff --git a/jjb/pipeline/bbsim-scale.groovy b/jjb/pipeline/bbsim-scale.groovy
index 1d92c19..5af7063 100644
--- a/jjb/pipeline/bbsim-scale.groovy
+++ b/jjb/pipeline/bbsim-scale.groovy
@@ -27,7 +27,7 @@
     stage('Create K8s Cluster') {
       steps {
         sh """
-           git clone https://github.com/ciena/kind-voltha.git
+           git clone https:/gerrit.opencord.org/kind-voltha
            cd kind-voltha/
            DEPLOY_K8S=y JUST_K8S=y ./voltha up
            """
@@ -51,8 +51,8 @@
         always {
           sh '''
              WAIT_ON_DOWN=y ./voltha down
-	 cd $WORKSPACE/
-	 rm -rf kind-voltha/ voltha/ || true
+             cd $WORKSPACE/
+             rm -rf kind-voltha/ voltha/ || true
              '''
         }
         failure {
diff --git a/jjb/pipeline/voltha-bbsim-tests.groovy b/jjb/pipeline/voltha-bbsim-tests.groovy
index ca289ab..83ab621 100644
--- a/jjb/pipeline/voltha-bbsim-tests.groovy
+++ b/jjb/pipeline/voltha-bbsim-tests.groovy
@@ -28,7 +28,7 @@
   environment {
     KUBECONFIG="$HOME/.kube/kind-config-voltha-minimal"
     VOLTCONFIG="$HOME/.volt/config-minimal"
-    PATH="$WORKSPACE/kind-voltha/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
+    PATH="$WORKSPACE/voltha/kind-voltha/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
     TYPE="minimal"
     FANCY=0
     WITH_SIM_ADAPTERS="n"
@@ -77,18 +77,16 @@
     stage('Create K8s Cluster') {
       steps {
         sh """
-           git clone https://github.com/ciena/kind-voltha.git
-
            if [ "${branch}" != "master" ]; then
              echo "on branch: ${branch}, sourcing kind-voltha/releases/${branch}"
-             source "kind-voltha/releases/${branch}"
+             source "$WORKSPACE/voltha/kind-voltha/releases/${branch}"
            else
              echo "on master, using default settings for kind-voltha"
            fi
 
-           cd kind-voltha/
+           cd $WORKSPACE/voltha/kind-voltha/
            JUST_K8S=y ./voltha up
-           bash <( curl -sfL https://raw.githubusercontent.com/boz/kail/master/godownloader.sh) -b "$WORKSPACE/kind-voltha/bin"
+           bash <( curl -sfL https://raw.githubusercontent.com/boz/kail/master/godownloader.sh) -b "$WORKSPACE/voltha/kind-voltha/bin"
            """
       }
     }
@@ -120,7 +118,7 @@
              export GOPATH=\${GOPATH:-$WORKSPACE/go}
              export PATH=\$PATH:/usr/lib/go-1.12/bin:/usr/local/go/bin:\$GOPATH/bin
              make -C $WORKSPACE/voltha/voltctl/ build
-           elif ! [[ "${gerritProject}" =~ ^(voltha-helm-charts|voltha-system-tests)\$ ]]; then
+           elif ! [[ "${gerritProject}" =~ ^(voltha-helm-charts|voltha-system-tests|kind-voltha)\$ ]]; then
              make-local ${gerritProject}
            fi
            """
@@ -132,12 +130,12 @@
         sh '''
            if [ "${branch}" != "master" ]; then
              echo "on branch: ${branch}, sourcing kind-voltha/releases/${branch}"
-             source "kind-voltha/releases/${branch}"
+             source "$WORKSPACE/voltha/kind-voltha/releases/${branch}"
            else
              echo "on master, using default settings for kind-voltha"
            fi
 
-           if ! [[ "${gerritProject}" =~ ^(voltha-helm-charts|voltha-system-tests|voltctl)\$ ]]; then
+           if ! [[ "${gerritProject}" =~ ^(voltha-helm-charts|voltha-system-tests|voltctl|kind-voltha)\$ ]]; then
              export GOROOT=/usr/local/go
              export GOPATH=\$(pwd)
              docker images | grep citest
@@ -151,7 +149,7 @@
         sh '''
            if [ "${branch}" != "master" ]; then
              echo "on branch: ${branch}, sourcing kind-voltha/releases/${branch}"
-             source "kind-voltha/releases/${branch}"
+             source "$WORKSPACE/voltha/kind-voltha/releases/${branch}"
            else
              echo "on master, using default settings for kind-voltha"
            fi
@@ -203,11 +201,11 @@
 
            if [ "${gerritProject}" = "voltctl" ]; then
              export VOLTCTL_VERSION=$(cat $WORKSPACE/voltha/voltctl/VERSION)
-             cp $WORKSPACE/voltha/voltctl/voltctl $WORKSPACE/kind-voltha/bin/voltctl
-             md5sum $WORKSPACE/kind-voltha/bin/voltctl
+             cp $WORKSPACE/voltha/voltctl/voltctl $WORKSPACE/voltha/kind-voltha/bin/voltctl
+             md5sum $WORKSPACE/voltha/kind-voltha/bin/voltctl
            fi
 
-           cd $WORKSPACE/kind-voltha/
+           cd $WORKSPACE/voltha/kind-voltha/
            echo \$EXTRA_HELM_FLAGS
            kail -n voltha -n default > $WORKSPACE/onos-voltha-combined.log &
            ./voltha up
@@ -242,7 +240,7 @@
     always {
       sh '''
          set +e
-         cp $WORKSPACE/kind-voltha/install-minimal.log $WORKSPACE/
+         cp $WORKSPACE/voltha/kind-voltha/install-minimal.log $WORKSPACE/
          kubectl get pods --all-namespaces -o jsonpath="{range .items[*].status.containerStatuses[*]}{.image}{'\\t'}{.imageID}{'\\n'}" | sort | uniq -c
          kubectl get nodes -o wide
          kubectl get pods -o wide
@@ -250,7 +248,7 @@
 
          sync
          pkill kail || true
-         md5sum $WORKSPACE/kind-voltha/bin/voltctl
+         md5sum $WORKSPACE/voltha/kind-voltha/bin/voltctl
 
          ## Pull out errors from log files
          extract_errors_go() {
@@ -278,12 +276,12 @@
          ## shut down kind-voltha
          if [ "${branch}" != "master" ]; then
            echo "on branch: ${branch}, sourcing kind-voltha/releases/${branch}"
-           source "kind-voltha/releases/${branch}"
+           source "$WORKSPACE/voltha/kind-voltha/releases/${branch}"
          else
            echo "on master, using default settings for kind-voltha"
          fi
 
-         cd $WORKSPACE/kind-voltha
+         cd $WORKSPACE/voltha/kind-voltha
 	       WAIT_ON_DOWN=y ./voltha down
          '''
          step([$class: 'RobotPublisher',
diff --git a/jjb/pipeline/voltha-dt-physical-functional-tests.groovy b/jjb/pipeline/voltha-dt-physical-functional-tests.groovy
index 4ef0450..455566a 100644
--- a/jjb/pipeline/voltha-dt-physical-functional-tests.groovy
+++ b/jjb/pipeline/voltha-dt-physical-functional-tests.groovy
@@ -40,7 +40,7 @@
         script {
            deployment_config = readYaml file: "${configBaseDir}/${configDeploymentDir}/${configFileName}-DT.yaml"
         }
-        // This checkout is just so that we can show changes in Jenkins
+        // This checkout allows us to show changes in Jenkins
         checkout(changelog: true,
           poll: false,
           scm: [$class: 'RepoScm',
@@ -60,7 +60,6 @@
         mkdir -p $WORKSPACE/bin
         bash <( curl -sfL https://raw.githubusercontent.com/boz/kail/master/godownloader.sh) -b "$WORKSPACE/bin"
         cd $WORKSPACE
-        git clone https://github.com/ciena/kind-voltha.git
 
         VC_VERSION=\$(curl -sSL https://api.github.com/repos/opencord/voltctl/releases/latest | jq -r .tag_name | sed -e 's/^v//g')
         HOSTOS=\$(uname -s | tr "[:upper:]" "[:lower:"])
@@ -83,7 +82,7 @@
       }
       steps {
         sh """
-        cd $WORKSPACE/kind-voltha/scripts
+        cd $WORKSPACE/voltha/kind-voltha/scripts
         ./log-collector.sh > /dev/null &
         ./log-combine.sh > /dev/null &
 
@@ -111,14 +110,14 @@
       extract_errors_go() {
         echo
         echo "Error summary for $1:"
-        grep '"level":"error"' $WORKSPACE/kind-voltha/scripts/logger/combined/$1*
+        grep '"level":"error"' $WORKSPACE/voltha/kind-voltha/scripts/logger/combined/$1*
         echo
       }
 
       extract_errors_python() {
         echo
         echo "Error summary for $1:"
-        grep 'ERROR' $WORKSPACE/kind-voltha/scripts/logger/combined/$1*
+        grep 'ERROR' $WORKSPACE/voltha/kind-voltha/scripts/logger/combined/$1*
         echo
       }
 
@@ -128,7 +127,7 @@
       extract_errors_python voltha-ofagent >> $WORKSPACE/error-report.log
       extract_errors_python onos >> $WORKSPACE/error-report.log
 
-      cd $WORKSPACE/kind-voltha/scripts/logger/combined/
+      cd $WORKSPACE/voltha/kind-voltha/scripts/logger/combined/
       tar czf $WORKSPACE/container-logs.tgz *
 
       cd $WORKSPACE
diff --git a/jjb/pipeline/voltha-go-multi-tests.groovy b/jjb/pipeline/voltha-go-multi-tests.groovy
index 437b120..f820809 100644
--- a/jjb/pipeline/voltha-go-multi-tests.groovy
+++ b/jjb/pipeline/voltha-go-multi-tests.groovy
@@ -28,7 +28,7 @@
   environment {
     KUBECONFIG="$HOME/.kube/kind-config-voltha-minimal"
     VOLTCONFIG="$HOME/.volt/config-minimal"
-    PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:$HOME/kind-voltha/bin"
+    PATH="$HOME/kind-voltha/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
     TYPE="minimal"
     FANCY=0
     WITH_SIM_ADAPTERS="n"
@@ -64,7 +64,7 @@
       steps {
         sh """
            cd $HOME
-           [ -d kind-voltha ] || git clone https://github.com/ciena/kind-voltha.git
+           [ -d kind-voltha ] || git clone https://gerrit.opencord.org/kind-voltha
            rm -rf $HOME/kind-voltha/scripts/logger
            cd $HOME/kind-voltha
            git pull
diff --git a/jjb/pipeline/voltha-go-tests.groovy b/jjb/pipeline/voltha-go-tests.groovy
index c0fc8b9..e6ed2e8 100644
--- a/jjb/pipeline/voltha-go-tests.groovy
+++ b/jjb/pipeline/voltha-go-tests.groovy
@@ -28,7 +28,7 @@
   environment {
     KUBECONFIG="$HOME/.kube/kind-config-voltha-minimal"
     VOLTCONFIG="$HOME/.volt/config-minimal"
-    PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:$HOME/kind-voltha/bin"
+    PATH="$HOME/kind-voltha/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
     TYPE="minimal"
     FANCY=0
     WITH_SIM_ADAPTERS="no"
@@ -64,7 +64,7 @@
       steps {
         sh """
            cd $HOME
-           [ -d kind-voltha ] || git clone https://github.com/ciena/kind-voltha.git
+           [ -d kind-voltha ] || git clone https://gerrit.opencord.org/kind-voltha
            rm -rf $HOME/kind-voltha/scripts/logger
            cd $HOME/kind-voltha
            git pull
diff --git a/jjb/pipeline/voltha-physical-build-and-tests.groovy b/jjb/pipeline/voltha-physical-build-and-tests.groovy
index 66e09e7..cd045c7 100644
--- a/jjb/pipeline/voltha-physical-build-and-tests.groovy
+++ b/jjb/pipeline/voltha-physical-build-and-tests.groovy
@@ -43,7 +43,7 @@
   environment {
     KUBECONFIG="$HOME/.kube/kind-config-voltha-minimal"
     VOLTCONFIG="$HOME/.volt/config-minimal"
-    PATH="$WORKSPACE/kind-voltha/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
+    PATH="$WORKSPACE/voltha/kind-voltha/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
     TYPE="minimal"
     FANCY=0
     //VOL-2194 ONOS SSH and REST ports hardcoded to 30115/30120 in tests
@@ -55,7 +55,7 @@
     stage ('Initialize') {
       steps {
         sh returnStdout: false, script: """
-        test -e $WORKSPACE/kind-voltha/voltha && cd $WORKSPACE/kind-voltha && ./voltha down
+        test -e $WORKSPACE/voltha/kind-voltha/voltha && cd $WORKSPACE/voltha/kind-voltha && ./voltha down
         cd $WORKSPACE
         rm -rf $WORKSPACE/*
         """
@@ -121,16 +121,14 @@
     stage('Create KinD Cluster') {
       steps {
         sh returnStdout: false, script: """
-        git clone https://github.com/ciena/kind-voltha.git
-
         if [ "${branch}" != "master" ]; then
           echo "on branch: ${branch}, sourcing kind-voltha/releases/${branch}"
-          source "kind-voltha/releases/${branch}"
+          source "$WORKSPACE/voltha/kind-voltha/releases/${branch}"
         else
           echo "on master, using default settings for kind-voltha"
         fi
 
-        cd kind-voltha/
+        cd $WORKSPACE/voltha/kind-voltha/
         JUST_K8S=y ./voltha up
         """
       }
@@ -145,7 +143,7 @@
 
         if [ "${branch}" != "master" ]; then
           echo "on branch: ${branch}, sourcing kind-voltha/releases/${branch}"
-          source "kind-voltha/releases/${branch}"
+          source "$WORKSPACE/voltha/kind-voltha/releases/${branch}"
         else
           echo "on master, using default settings for kind-voltha"
         fi
@@ -176,7 +174,7 @@
           sh returnStdout: false, script: """
           if [ "${branch}" != "master" ]; then
             echo "on branch: ${branch}, sourcing kind-voltha/releases/${branch}"
-            source "kind-voltha/releases/${branch}"
+            source "$WORKSPACE/voltha/kind-voltha/releases/${branch}"
           else
             echo "on master, using default settings for kind-voltha"
           fi
@@ -205,7 +203,7 @@
               EXTRA_HELM_FLAGS+="--set images.\$I.tag=citest,images.\$I.pullPolicy=Never "
           done
 
-          cd $WORKSPACE/kind-voltha/
+          cd $WORKSPACE/voltha/kind-voltha/
           echo \$EXTRA_HELM_FLAGS
           kail -n voltha -n default > $WORKSPACE/onos-voltha-combined.log &
           ./voltha up
@@ -340,7 +338,7 @@
     always {
       sh returnStdout: false, script: '''
       set +e
-      cp kind-voltha/install-minimal.log $WORKSPACE/
+      cp $WORKSPACE/voltha/kind-voltha/install-minimal.log $WORKSPACE/
       kubectl get pods --all-namespaces -o jsonpath="{range .items[*].status.containerStatuses[*]}{.image}{'\\t'}{.imageID}{'\\n'}" | sort | uniq -c
       kubectl get nodes -o wide
       kubectl get pods -o wide
diff --git a/jjb/pipeline/voltha-physical-functional-tests.groovy b/jjb/pipeline/voltha-physical-functional-tests.groovy
index 038d89c..6b39bc7 100644
--- a/jjb/pipeline/voltha-physical-functional-tests.groovy
+++ b/jjb/pipeline/voltha-physical-functional-tests.groovy
@@ -40,7 +40,7 @@
         script {
           deployment_config = readYaml file: "${configBaseDir}/${configDeploymentDir}/${configFileName}.yaml"
         }
-        // This checkout is just so that we can show changes in Jenkins
+        // This checkout allows us to show changes in Jenkins
         checkout(changelog: true,
           poll: false,
           scm: [$class: 'RepoScm',
@@ -60,7 +60,6 @@
         mkdir -p $WORKSPACE/bin
         bash <( curl -sfL https://raw.githubusercontent.com/boz/kail/master/godownloader.sh) -b "$WORKSPACE/bin"
         cd $WORKSPACE
-        git clone https://github.com/ciena/kind-voltha.git
 
         VC_VERSION=\$(curl -sSL https://api.github.com/repos/opencord/voltctl/releases/latest | jq -r .tag_name | sed -e 's/^v//g')
         HOSTOS=\$(uname -s | tr "[:upper:]" "[:lower:"])
@@ -83,7 +82,7 @@
       }
       steps {
         sh """
-        cd $WORKSPACE/kind-voltha/scripts
+        cd $WORKSPACE/voltha/kind-voltha/scripts
         ./log-collector.sh > /dev/null &
         ./log-combine.sh > /dev/null &
 
@@ -145,14 +144,14 @@
       extract_errors_go() {
         echo
         echo "Error summary for $1:"
-        grep '"level":"error"' $WORKSPACE/kind-voltha/scripts/logger/combined/$1*
+        grep '"level":"error"' $WORKSPACE/voltha/kind-voltha/scripts/logger/combined/$1*
         echo
       }
 
       extract_errors_python() {
         echo
         echo "Error summary for $1:"
-        grep 'ERROR' $WORKSPACE/kind-voltha/scripts/logger/combined/$1*
+        grep 'ERROR' $WORKSPACE/voltha/kind-voltha/scripts/logger/combined/$1*
         echo
       }
 
@@ -162,7 +161,7 @@
       extract_errors_python voltha-ofagent >> $WORKSPACE/error-report.log
       extract_errors_python onos >> $WORKSPACE/error-report.log
 
-      cd $WORKSPACE/kind-voltha/scripts/logger/combined/
+      cd $WORKSPACE/voltha/kind-voltha/scripts/logger/combined/
       tar czf $WORKSPACE/container-logs.tgz *
 
       cd $WORKSPACE
diff --git a/jjb/pipeline/voltha-system-test-bbsim.groovy b/jjb/pipeline/voltha-system-test-bbsim.groovy
index 2d89c03..fcea75a 100644
--- a/jjb/pipeline/voltha-system-test-bbsim.groovy
+++ b/jjb/pipeline/voltha-system-test-bbsim.groovy
@@ -45,7 +45,7 @@
     stage('Create Kubernetes Cluster') {
       steps {
         sh """
-           git clone https://github.com/ciena/kind-voltha.git
+           git clone https://gerrit.opencord.org/kind-voltha
            pushd kind-voltha/
            JUST_K8S=y ./voltha up
            popd
diff --git a/jjb/verify/kind-voltha.yaml b/jjb/verify/kind-voltha.yaml
new file mode 100644
index 0000000..155728a
--- /dev/null
+++ b/jjb/verify/kind-voltha.yaml
@@ -0,0 +1,20 @@
+---
+# verification jobs for 'kind-voltha' repo
+
+- project:
+    name: kind-voltha
+    project: '{name}'
+
+    jobs:
+      - 'verify-kind-voltha-jobs':
+          branch-regexp: '{all-branches-regexp}'
+
+- job-group:
+    name: 'verify-kind-voltha-jobs'
+    jobs:
+      - 'voltha-patch-test':
+          pipeline-script: 'voltha-bbsim-tests.groovy'
+      - 'voltha-patch-test':
+          pipeline-script: 'voltha-bbsim-tests.groovy'
+          name-extension: '-2.3'
+          override-branch: 'voltha-2.3'
diff --git a/jjb/voltha-e2e.yaml b/jjb/voltha-e2e.yaml
index 439c794..e25d4be 100644
--- a/jjb/voltha-e2e.yaml
+++ b/jjb/voltha-e2e.yaml
@@ -261,6 +261,7 @@
 - job-template:
     id: 'voltha-patch-test'
     name: 'verify_{project}_sanity-test{name-extension}'
+    override-branch: '$GERRIT_BRANCH'
 
     description: |
       <!-- Managed by Jenkins Job Builder -->
@@ -290,7 +291,7 @@
 
       - string:
           name: branch
-          default: '$GERRIT_BRANCH'
+          default: '{override-branch}'
           description: 'Name of the branch to use'
 
       - string: