VPP: forcing removal of old dpdk packages
[ci-management.git] / jjb / scripts / setup_vpp_ubuntu_docker_test.sh
index d7a2ee1..1fca782 100644 (file)
@@ -30,8 +30,14 @@ elif [ "${OS_ID}" == "opensuse" ]; then
     pip list || true
 fi
 
-if [ "x${IS_CSIT_VPP_JOB}" == "xTrue" ]; then
-       (cd dpdk ; apt-get download vpp-dpdk-dkms > /dev/null 2>&1) || true
-    ls -l dpdk/*.deb || true
-    echo "csit vpp-dpdk-dkms package download"
-fi
\ No newline at end of file
+##This will remove any previously installed dpdk for old branch builds
+
+if [ "${GERRIT_BRANCH}" != "master" ]; then
+    if [ "${OS_ID}" == "ubuntu" ]; then
+        apt-get -y remove vpp-dpdk-dev || true
+        apt-get -y remove vpp-dpdk-dkms || true
+    elif [ "${OS_ID}" == "centos" ]; then
+        yum -y erase vpp-dpdk-devel || true
+        yum clean all || true
+    fi
+fi