X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=jjb%2Fintegration%2Finclude-raw-integration-deploy-controller-run-test.sh;h=78bdec2fed423388c2bc16e9e6f3f43e51b043a7;hb=d2298c706207323ed74d211ef6f3999692527612;hp=1eb50f14df939996e7b05cc8524220c30130c751;hpb=54b2e6bfca3303768e8c748f68a94c1c5aa4576f;p=releng%2Fbuilder.git diff --git a/jjb/integration/include-raw-integration-deploy-controller-run-test.sh b/jjb/integration/include-raw-integration-deploy-controller-run-test.sh index 1eb50f14d..78bdec2fe 100644 --- a/jjb/integration/include-raw-integration-deploy-controller-run-test.sh +++ b/jjb/integration/include-raw-integration-deploy-controller-run-test.sh @@ -42,10 +42,16 @@ unzip -q ${BUNDLE} echo "Configuring the startup features..." FEATURESCONF=/tmp/${BUNDLEFOLDER}/etc/org.apache.karaf.features.cfg +CUSTOMPROP=/tmp/${BUNDLEFOLDER}/etc/custom.properties sed -ie "s/featuresBoot=.*/featuresBoot=config,standard,region,package,kar,ssh,management,${ACTUALFEATURES}/g" \${FEATURESCONF} sed -ie "s%mvn:org.opendaylight.integration/features-integration-index/${BUNDLEVERSION}/xml/features%mvn:org.opendaylight.integration/features-integration-index/${BUNDLEVERSION}/xml/features,mvn:org.opendaylight.integration/features-integration-test/${BUNDLEVERSION}/xml/features%g" \${FEATURESCONF} cat \${FEATURESCONF} +if [ "${ODL_ENABLE_L3_FWD}" == "yes" ]; then + echo "ovsdb.l3.fwd.enabled=yes" >> \${CUSTOMPROP} +fi +cat \${CUSTOMPROP} + echo "Configuring the log..." LOGCONF=/tmp/${BUNDLEFOLDER}/etc/org.ops4j.pax.logging.cfg sed -ie 's/log4j.appender.out.maxBackupIndex=10/log4j.appender.out.maxBackupIndex=1/g' \${LOGCONF} @@ -53,31 +59,26 @@ sed -ie 's/log4j.appender.out.maxBackupIndex=10/log4j.appender.out.maxBackupInde sed -ie 's/log4j.appender.out.maxFileSize=1MB/log4j.appender.out.maxFileSize=100GB/g' \${LOGCONF} cat \${LOGCONF} -echo "Configure max memory..." +echo "Configure java home and max memory..." MEMCONF=/tmp/${BUNDLEFOLDER}/bin/setenv +sed -ie 's%^# export JAVA_HOME%export JAVA_HOME="\${JAVA_HOME:-${JAVA_HOME}}"%g' \${MEMCONF} sed -ie 's/JAVA_MAX_MEM="2048m"/JAVA_MAX_MEM="${CONTROLLERMEM}"/g' \${MEMCONF} cat \${MEMCONF} echo "Listing all open ports on controller system..." netstat -natu -if [ ${JDKVERSION} == 'openjdk8' ]; then - echo "Setting the JRE Version to 8" - # dynamic_verify does not allow sudo, JAVA_HOME should be enough for karaf start. - # sudo /usr/sbin/alternatives --set java /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.60-2.b27.el7_1.x86_64/jre/bin/java - export JAVA_HOME=/usr/lib/jvm/java-1.8.0 -elif [ ${JDKVERSION} == 'openjdk7' ]; then - echo "Setting the JRE Version to 7" - # dynamic_verify does not allow sudo, JAVA_HOME should be enough for karaf start. - # sudo /usr/sbin/alternatives --set java /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.85-2.6.1.2.el7_1.x86_64/jre/bin/java - export JAVA_HOME=/usr/lib/jvm/java-1.7.0 -fi -echo "JAVA_HOME is \${JAVA_HOME}" +echo "Set Java version" +sudo /usr/sbin/alternatives --install /usr/bin/java java ${JAVA_HOME}/bin/java 1 +sudo /usr/sbin/alternatives --set java ${JAVA_HOME}/bin/java +echo "JDK default version ..." +java -version + +echo "Set JAVA_HOME" +export JAVA_HOME="$JAVA_HOME" # Did you know that in HERE documents, single quote is an ordinary character, but backticks are still executing? JAVA_RESOLVED=\`readlink -e "\${JAVA_HOME}/bin/java"\` echo "Java binary pointed at by JAVA_HOME: \${JAVA_RESOLVED}" -echo "JDK default version ..." -java -version echo "Starting controller..." /tmp/${BUNDLEFOLDER}/bin/start @@ -132,6 +133,11 @@ EOF scp ${WORKSPACE}/controller-script.sh ${ODL_SYSTEM_IP}:/tmp ssh ${ODL_SYSTEM_IP} 'bash /tmp/controller-script.sh' +if [ ${NUM_OPENSTACK_SYSTEM} -gt 0 ]; then + echo "Exiting without running tests to deploy openstack for testing" + exit +fi + echo "Locating test plan to use..." testplan_filepath="${WORKSPACE}/test/csit/testplans/${STREAMTESTPLAN}" if [ ! -f "${testplan_filepath}" ]; then @@ -141,12 +147,11 @@ fi echo "Changing the testplan path..." cat "${testplan_filepath}" | sed "s:integration:${WORKSPACE}:" > testplan.txt cat testplan.txt - SUITES=$( egrep -v '(^[[:space:]]*#|^[[:space:]]*$)' testplan.txt | tr '\012' ' ' ) echo "Starting Robot test suites ${SUITES} ..." pybot -N ${TESTPLAN} -c critical -e exclude -v BUNDLEFOLDER:${BUNDLEFOLDER} -v WORKSPACE:/tmp \ --v BUNDLE_URL:${ACTUALBUNDLEURL} -v NEXUSURL_PREFIX:${NEXUSURL_PREFIX} \ +-v JAVA_HOME:${JAVA_HOME} -v BUNDLE_URL:${ACTUALBUNDLEURL} -v NEXUSURL_PREFIX:${NEXUSURL_PREFIX} \ -v CONTROLLER:${ODL_SYSTEM_IP} -v ODL_SYSTEM_IP:${ODL_SYSTEM_IP} -v CONTROLLER_USER:${USER} -v ODL_SYSTEM_USER:${USER} \ -v TOOLS_SYSTEM_IP:${TOOLS_SYSTEM_IP} -v TOOLS_SYSTEM_2_IP:${TOOLS_SYSTEM_2_IP} -v TOOLS_SYSTEM_3_IP:${TOOLS_SYSTEM_3_IP} \ -v TOOLS_SYSTEM_4_IP:${TOOLS_SYSTEM_4_IP} -v TOOLS_SYSTEM_5_IP:${TOOLS_SYSTEM_5_IP} -v TOOLS_SYSTEM_6_IP:${TOOLS_SYSTEM_6_IP} \