Updated per-patch validation and software upgrade jobs to use latest voltctl version

Change-Id: I704e0aad4e5794ff3eaa3c503841150de35f9b94
diff --git a/jjb/pipeline/voltha/master/software-upgrades.groovy b/jjb/pipeline/voltha/master/software-upgrades.groovy
index 1735ba8..fd078d0 100644
--- a/jjb/pipeline/voltha/master/software-upgrades.groovy
+++ b/jjb/pipeline/voltha/master/software-upgrades.groovy
@@ -188,6 +188,21 @@
         helmTeardown(['infra', 'voltha'])
       }
     }
+    stage('Install latest voltctl') {
+      steps {
+        sh """
+          # install voltctl
+          HOSTOS="\$(uname -s | tr "[:upper:]" "[:lower:"])"
+          HOSTARCH="\$(uname -m | tr "[:upper:]" "[:lower:"])"
+          if [ "\$HOSTARCH" == "x86_64" ]; then
+              HOSTARCH="amd64"
+          fi
+          VC_VERSION="\$(curl --fail -sSL https://api.github.com/repos/opencord/voltctl/releases/latest | jq -r .tag_name | sed -e 's/^v//g')"
+          curl -Lo $WORKSPACE/bin/voltctl https://github.com/opencord/voltctl/releases/download/v\$VC_VERSION/voltctl-\$VC_VERSION-\$HOSTOS-\$HOSTARCH
+          chmod +x $WORKSPACE/bin/voltctl
+        """
+      }
+    }
     stage('Run Test') {
       steps {
         test_software_upgrade("onos-app-upgrade")
diff --git a/jjb/software-upgrades.yaml b/jjb/software-upgrades.yaml
index ccae596..b06a377 100644
--- a/jjb/software-upgrades.yaml
+++ b/jjb/software-upgrades.yaml
@@ -26,9 +26,9 @@
           mcast-oar-url: 'https://oss.sonatype.org/content/groups/public/org/opencord/mcast-app/2.2.0-SNAPSHOT/mcast-app-2.2.0-20210316.083454-5.oar'
           kafka-version: '2.6.0.SNAPSHOT'
           kafka-oar-url: 'https://oss.sonatype.org/content/groups/public/org/opencord/kafka/2.6.0-SNAPSHOT/kafka-2.6.0-20210311.093145-2.oar'
-          adapter-open-olt-image: 'voltha/voltha-openolt-adapter:3.1.6'
+          adapter-open-olt-image: 'voltha/voltha-openolt-adapter:3.2.0'
           adapter-open-onu-image: 'voltha/voltha-openonu-adapter-go:1.2.6'
-          rw-core-image: 'voltha/voltha-rw-core:2.6.3'
+          rw-core-image: 'voltha/voltha-rw-core:2.7.0'
           ofagent-image: 'voltha/voltha-ofagent-go:1.5.2'
           onu-image-name: 'software-image.img'
           onu-image-url: 'http://bbsim0:50074/images'
diff --git a/vars/createKubernetesCluster.groovy b/vars/createKubernetesCluster.groovy
index f640b16..48a0bea 100644
--- a/vars/createKubernetesCluster.groovy
+++ b/vars/createKubernetesCluster.groovy
@@ -41,7 +41,8 @@
       if [ "\$HOSTARCH" == "x86_64" ]; then
           HOSTARCH="amd64"
       fi
-      curl -Lo $WORKSPACE/bin/voltctl https://github.com/opencord/voltctl/releases/download/v1.3.1/voltctl-1.3.1-\$HOSTOS-\$HOSTARCH
+      VC_VERSION="\$(curl --fail -sSL https://api.github.com/repos/opencord/voltctl/releases/latest | jq -r .tag_name | sed -e 's/^v//g')"
+      curl -Lo $WORKSPACE/bin/voltctl https://github.com/opencord/voltctl/releases/download/v\$VC_VERSION/voltctl-\$VC_VERSION-\$HOSTOS-\$HOSTARCH
       chmod +x $WORKSPACE/bin/voltctl
 
       # start the kind cluster