Remove Li redesign -all- test
[releng/builder.git] / jjb / integration / include-raw-integration-deploy-controller-offline.sh
1 CONTROLLERMEM="3072m"
2 ACTUALFEATURES="odl-integration-all"
3
4 echo "Downloading the distribution..."
5 wget --no-verbose  ${ACTUALBUNDLEURL}
6
7 echo "Extracting the new controller..."
8 unzip -q ${BUNDLE}
9
10 echo "Configuring the startup features..."
11 FEATURESCONF=${WORKSPACE}/${BUNDLEFOLDER}/etc/org.apache.karaf.features.cfg
12 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}
13 cat ${FEATURESCONF}
14
15 echo "Configuring the log..."
16 LOGCONF=${WORKSPACE}/${BUNDLEFOLDER}/etc/org.ops4j.pax.logging.cfg
17 sed -ie 's/log4j.appender.out.maxFileSize=1MB/log4j.appender.out.maxFileSize=20MB/g' ${LOGCONF}
18 cat ${LOGCONF}
19
20 echo "Configure the repos..."
21 REPOCONF=${WORKSPACE}/${BUNDLEFOLDER}/etc/org.ops4j.pax.url.mvn.cfg
22 sed -ie '/http/d' ${REPOCONF}
23 sed -ie '$s/...$//' ${REPOCONF}
24 cat ${REPOCONF}
25
26 echo "Configure max memory..."
27 MEMCONF=${WORKSPACE}/${BUNDLEFOLDER}/bin/setenv
28 sed -ie 's/JAVA_MAX_MEM="2048m"/JAVA_MAX_MEM="${CONTROLLERMEM}"/g' ${MEMCONF}
29 cat ${MEMCONF}
30
31 echo "Starting controller..."
32 ${WORKSPACE}/${BUNDLEFOLDER}/bin/start
33
34 echo "sleeping for 10 seconds..."
35 sleep 10
36
37 echo "Check OSGi bundles..."
38 sshpass -p karaf ${WORKSPACE}/${BUNDLEFOLDER}/bin/client -u karaf "feature:install ${ACTUALFEATURES}" || echo $? > ${WORKSPACE}/error.txt
39
40 echo "Fetching Karaf log"
41 cp ${WORKSPACE}/${BUNDLEFOLDER}/data/log/karaf.log .
42
43 echo "Exit with error"
44 if [ `cat error.txt` -ne 0 ]; then
45     echo "Failed to deploy offline"
46     exit 1
47 fi
48
49 # vim: ts=4 sw=4 sts=4 et ft=sh :
50