From: Andrew Grimberg Date: Mon, 11 Apr 2016 15:26:40 +0000 (+0000) Subject: Merge "Add odlsign-bulk script" X-Git-Tag: release/beryllium-sr2~60 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=commitdiff_plain;h=7151b63f96733b70ff8c6cefe1425f7ecbe29dcd;hp=9ebbe1d12a97ac44a62a4a853515710d9d8b5c6c;p=releng%2Fbuilder.git Merge "Add odlsign-bulk script" --- diff --git a/jenkins-scripts/controller.sh b/jenkins-scripts/controller.sh index cd7cd521e..cac6a2452 100755 --- a/jenkins-scripts/controller.sh +++ b/jenkins-scripts/controller.sh @@ -7,26 +7,33 @@ yum install -y sshpass # vim: sw=2 ts=2 sts=2 et : + + +### +### Disable archive.apache.org downloads since that site is under maintenance until +### April 11th 2016. +### + # Installation of Hbase -mkdir /tmp/Hbase -cd /tmp/Hbase +#mkdir /tmp/Hbase +#cd /tmp/Hbase -wget --no-verbose https://archive.apache.org/dist/hbase/hbase-0.94.15/hbase-0.94.15.tar.gz +#wget --no-verbose https://archive.apache.org/dist/hbase/hbase-0.94.15/hbase-0.94.15.tar.gz -echo "Installing the Hbase Server..." -tar -xvf hbase*.tar.gz +#echo "Installing the Hbase Server..." +#tar -xvf hbase*.tar.gz #Installation of Cassandra -mkdir /tmp/cassandra -cd /tmp/cassandra +#mkdir /tmp/cassandra +#cd /tmp/cassandra -wget --no-verbose http://archive.apache.org/dist/cassandra/2.1.12/apache-cassandra-2.1.12-bin.tar.gz +#wget --no-verbose http://archive.apache.org/dist/cassandra/2.1.12/apache-cassandra-2.1.12-bin.tar.gz -echo "Installing the Cassandra Server..." -tar -xvf apache*.tar.gz +#echo "Installing the Cassandra Server..." +#tar -xvf apache*.tar.gz cat </etc/sudoers.d/89-jenkins-user-defaults diff --git a/jjb/cardinal/cardinal.cfg b/jjb/cardinal/cardinal.cfg new file mode 100644 index 000000000..b295c8e83 --- /dev/null +++ b/jjb/cardinal/cardinal.cfg @@ -0,0 +1,6 @@ +STREAMS: +- boron: + branch: master + jdks: openjdk8 + autorelease: true +DEPENDENCIES: controller,yangtools,odlparent,openflowplugin,iotdm,sfc diff --git a/jjb/cardinal/cardinal.yaml b/jjb/cardinal/cardinal.yaml new file mode 100644 index 000000000..eca32b540 --- /dev/null +++ b/jjb/cardinal/cardinal.yaml @@ -0,0 +1,738 @@ +# REMOVE THIS LINE IF YOU WANT TO CUSTOMIZE ANYTHING BELOW +# Otherwise this file will be automatically overwritten by the template +# autobuilder. + +# ODL Releng build templates +- project: + name: cardinal + jobs: + - 'cardinal-verify-{stream}' + - 'cardinal-merge-{stream}' + - 'cardinal-periodic-{stream}' + - 'cardinal-distribution-{stream}' + - 'cardinal-distribution-check-{stream}' + - 'cardinal-integration-{stream}' + - 'cardinal-sonar' + - 'cardinal-clm-{stream}' + - 'cardinal-validate-autorelease-{stream}' + + + # stream: release stream (eg. stable-lithium or beryllium) + # branch: git branch (eg. stable/lithium or master) + stream: + - boron: + branch: 'master' + jdk: openjdk8 + jdks: + - openjdk8 + disable_autorelease: False + disable_distribution_check: False + + project: 'cardinal' + +# For the Job templates below replace instances of: +# PROJECT_SHORTNAME with your project name (eg. circuitsw) +# PROJECT_PATH with your project name (eg. ofextensions/circuitsw) +# MAVEN_GOALS with your maven goals to build +# MAVEN_OPTS with your maven options to build + +- job-template: + name: 'cardinal-verify-{stream}' + + # Job template for ODL verify jobs + # + # The purpose of this job template is to setup a ODL verify job + # + # Required Variables: + # stream: release stream (eg. stable-lithium or beryllium) + # branch: git branch (eg. stable/lithium or master) + + project-type: matrix + node: matrix_master + concurrent: true + + axes: + - axis: + type: slave + name: nodes + values: + - dynamic_verify + - axis: + type: jdk + values: '{obj:jdks}' + + logrotate: + daysToKeep: '{build-days-to-keep}' + numToKeep: '{build-num-to-keep}' + artifactDaysToKeep: '{build-artifact-days-to-keep}' + artifactNumToKeep: '{build-artifact-num-to-keep}' + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + - gerrit-refspec-parameter: + refspec: 'refs/heads/{branch}' + + scm: + - gerrit-trigger-scm: + credentials-id: '{ssh-credentials}' + refspec: '$GERRIT_REFSPEC' + choosing-strategy: 'gerrit' + + wrappers: + - build-timeout + - ssh-agent-credentials: + users: + - '{ssh-credentials}' + + triggers: + - gerrit-trigger-patch-submitted: + name: 'cardinal' + branch: '{branch}' + + builders: + - wipe-org-opendaylight-repo + - jacoco-nojava-workaround + - provide-maven-settings: + global-settings-file: '{odl-global-settings}' + settings-file: '{cardinal-settings}' + - maven-target: + maven-version: '{mvn33}' + pom: 'pom.xml' + goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Djenkins -Dstream={stream}' + java-opts: + - '-Xmx1024m -XX:MaxPermSize=256m' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + + publishers: + - archive-artifacts: + artifacts: '**/target/surefire-reports/*-output.txt, ' + - findbugs + - email-notification: + email-prefix: '[cardinal]' + - jacoco-report + +- job-template: + name: 'cardinal-merge-{stream}' + + # Job template for ODL merge jobs + # + # The purpose of this job template is to setup a ODL merge job + # and deploy artifacts to Nexus. + # + # Required Variables: + # stream: release stream (eg. stable-lithium or beryllium) + # branch: git branch (eg. stable/lithium or master) + + project-type: maven + node: dynamic_merge + jdk: '{jdk}' + + logrotate: + daysToKeep: '14' + numToKeep: '10' + artifactDaysToKeep: '{build-artifact-days-to-keep}' + artifactNumToKeep: '{build-artifact-num-to-keep}' + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + - gerrit-refspec-parameter: + refspec: 'refs/heads/{branch}' + + scm: + - gerrit-trigger-scm: + credentials-id: '{ssh-credentials}' + refspec: '' + choosing-strategy: 'default' + + wrappers: + - build-timeout + - ssh-agent-credentials: + users: + - '{ssh-credentials}' + + triggers: + - timed: 'H H * * 0' + - gerrit-trigger-patch-merged: + name: 'cardinal' + branch: '{branch}' + + prebuilders: + - wipe-org-opendaylight-repo + - jacoco-nojava-workaround + - provide-maven-settings: + global-settings-file: '{odl-global-settings}' + settings-file: '{cardinal-settings}' + + maven: + maven-name: '{mvn33}' + root-pom: 'pom.xml' + goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Djenkins -Dmerge -Dstream={stream}' + maven-opts: '-Xmx1024m -XX:MaxPermSize=256m' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + post-step-run-condition: UNSTABLE + + postbuilders: + - conditional-step: + condition-kind: file-exists + condition-filename: deploy-site.xml + condition-basedir: workspace + + # The strategy here is intentional to run Maven site:deploy twice + # once using regular pom.xml to produce a staged-site which is + # then used by deploy-site.xml to push to Nexus. This is a + # workaround to Maven Site's default linking code which creates + # incorrect URLs for sites due to auto-detection assuming your + # project is configured in a certain way which ODL is not. + steps: + - maven-target: + maven-version: '{mvn33}' + pom: pom.xml + goals: 'site:deploy -Dstream={stream}' + java-opts: + - '-Xmx2g' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + - maven-target: + maven-version: '{mvn33}' + pom: deploy-site.xml + goals: 'site:deploy -Dstream={stream}' + java-opts: + - '-Xmx2g' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + + reporters: + - findbugs + + publishers: + - archive-artifacts: + artifacts: '**/target/surefire-reports/*-output.txt, ' + - email-notification: + email-prefix: '[cardinal]' + - maven-deploy: + id: '' + unique-version: true + deploy-unstable: false + - jacoco-report + +- job-template: + name: 'cardinal-periodic-{stream}' + disabled: false + + # Job template for periodic builders + # + # The purpose of this job template is to setup a periodic + # builder. + # + # Required Variables: + # stream: release stream (eg. stable-lithium or beryllium) + # branch: git branch (eg. stable/lithium or master) + + project-type: maven + node: dynamic_verify + jdk: '{jdk}' + + logrotate: + daysToKeep: '14' + numToKeep: '10' + artifactDaysToKeep: '{build-artifact-days-to-keep}' + artifactNumToKeep: '{build-artifact-num-to-keep}' + + parameters: + - project-parameter: + project: '{project}' + + scm: + - git-scm: + credentials-id: '{ssh-credentials}' + refspec: '' + branch: '{branch}' + + wrappers: + - build-timeout + - ssh-agent-credentials: + users: + - '{ssh-credentials}' + + triggers: + - timed: '@daily' + + prebuilders: + - wipe-org-opendaylight-repo + - jacoco-nojava-workaround + - provide-maven-settings: + global-settings-file: '{odl-global-settings}' + settings-file: '{cardinal-settings}' + + maven: + maven-name: '{mvn33}' + root-pom: 'pom.xml' + goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Djenkins' + maven-opts: '-Xmx1024m -XX:MaxPermSize=256m' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + + reporters: + - findbugs + + publishers: + - email-notification: + email-prefix: '[cardinal]' + - jacoco-report + +- job-template: + name: 'cardinal-distribution-{stream}' + + # Required variables: + # stream: release stream (eg. stable-lithium or beryllium) + # branch: git branch (eg. stable/lithium or master) + + project-type: maven + node: dynamic_merge + jdk: '{jdk}' + + logrotate: + daysToKeep: '{build-days-to-keep}' + numToKeep: '{build-num-to-keep}' + artifactDaysToKeep: '{build-artifact-days-to-keep}' + artifactNumToKeep: '{build-artifact-num-to-keep}' + + parameters: + - project-parameter: + project: 'integration/distribution' + + scm: + - git-scm: + credentials-id: '{ssh-credentials}' + refspec: '' + branch: '{branch}' + + wrappers: + - build-timeout + - ssh-agent-credentials: + users: + - '{ssh-credentials}' + + triggers: + - reverse: + jobs: '{project}-merge-{stream}' + result: 'success' + + prebuilders: + - wipe-org-opendaylight-repo + - provide-maven-settings: + global-settings-file: '{odl-global-settings}' + settings-file: '{cardinal-settings}' + + maven: + maven-name: '{mvn33}' + root-pom: 'pom.xml' + goals: 'clean install -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r' + maven-opts: '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true' + settings: '{integration-settings}' + global-settings: '{odl-global-settings}' + + publishers: + - email-notification: + email-prefix: '[{project}]' + - maven-deploy: + id: '' + unique-version: true + deploy-unstable: false + +# Template: integration-patch-distribution-{stream} +# Goal: Build a patch and make sure the distribution can deploy with this change +# Operation: This job template builds a patch, creates a distribution containing +# the patch, and triggers the distribution deploy test + +- job-template: + name: 'cardinal-distribution-check-{stream}' + disabled: '{obj:disable_distribution_check}' + + project-type: maven + node: dynamic_verify + concurrent: true + jdk: '{jdk}' + + logrotate: + daysToKeep: '14' + numToKeep: '10' + artifactDaysToKeep: '{build-artifact-days-to-keep}' + artifactNumToKeep: '{build-artifact-num-to-keep}' + + parameters: + - gerrit-project-parameter: + project: '{project}' + - gerrit-refspec-parameter: + refspec: '{branch}' + - project-parameter: + project: '{project}' + - integration-distribution-git-url + + scm: + - integration-gerrit-scm: + credentials-id: '{ssh-credentials}' + basedir: '$GERRIT_PROJECT' + refspec: '$GERRIT_REFSPEC' + branch: '{branch}' + - integration-distribution-scm: + credentials-id: '{ssh-credentials}' + branch: '{branch}' + + wrappers: + - build-timeout + - ssh-agent-credentials: + users: + - '{ssh-credentials}' + + triggers: + - gerrit: + server-name: 'OpenDaylight' + trigger-on: + - patchset-created-event: + exclude-drafts: 'true' + exclude-trivial-rebase: 'false' + exclude-no-code-change: 'true' + - draft-published-event + - comment-added-contains-event: + comment-contains-value: 'test-distribution' + - comment-added-contains-event: + comment-contains-value: 'reverify' + - comment-added-contains-event: + comment-contains-value: 'recheck' + projects: + - project-compare-type: 'ANT' + project-pattern: '{name}' + branches: + - branch-compare-type: 'ANT' + branch-pattern: '**/{branch}' + skip-vote: + successful: false + failed: false + unstable: false + notbuilt: false + + prebuilders: + - wipe-org-opendaylight-repo + - maven-target: + maven-version: '{mvn33}' + pom: '$GERRIT_PROJECT/pom.xml' + goals: 'clean install -Djenkins -DskipTests -Dcheckstyle.skip=true -Dmaven.javadoc.skip=true -Dmaven.site.skip=true -DgenerateReports=false -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dstream={stream}' + java-opts: + - '-Xmx4096m -XX:MaxPermSize=1024m -Dmaven.compile.fork=true' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + + maven: + maven-name: '{mvn33}' + root-pom: 'distribution/pom.xml' + goals: 'clean install -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r' + maven-opts: '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + ignore-upstream-changes: true + post-step-run-condition: 'SUCCESS' + + postbuilders: + - integration-distribution-check + + publishers: + - archive: + artifacts: 'karaf.log' + - archive: + artifacts: 'karaf_console.log' + - email-notification: + email-prefix: '[cardinal]' + +- job-template: + name: 'cardinal-integration-{stream}' + disabled: false + + # Job template for ODL integration verify jobs + # + # This is similar to a normal verify job, but it runs + # when a project that's a dependency of your project + # is successfully built. + # + # Required Variables: + # stream: release stream (eg. stable-lithium or beryllium) + # branch: git branch (eg. stable/lithium or master) + + project-type: maven + node: dynamic_merge + jdk: '{jdk}' + + logrotate: + daysToKeep: '{build-days-to-keep}' + numToKeep: '{build-num-to-keep}' + artifactDaysToKeep: '{build-artifact-days-to-keep}' + artifactNumToKeep: '{build-artifact-num-to-keep}' + + parameters: + - project-parameter: + project: '{project}' + + scm: + - git-scm: + credentials-id: '{ssh-credentials}' + refspec: '' + branch: '{branch}' + + wrappers: + - build-timeout + - ssh-agent-credentials: + users: + - '{ssh-credentials}' + + triggers: + - reverse: + jobs: 'controller-merge-{stream},yangtools-merge-{stream},odlparent-merge-{stream},openflowplugin-merge-{stream},iotdm-merge-{stream},sfc-merge-{stream}' + result: 'success' + + prebuilders: + - wipe-org-opendaylight-repo + - jacoco-nojava-workaround + - provide-maven-settings: + global-settings-file: '{odl-global-settings}' + settings-file: '{cardinal-settings}' + + maven: + maven-name: '{mvn33}' + root-pom: 'pom.xml' + goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Djenkins' + maven-opts: '-Xmx1024m -XX:MaxPermSize=256m' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + + reporters: + - findbugs + + publishers: + - email-notification: + email-prefix: '[cardinal] [controller] [yangtools] [odlparent] [openflowplugin] [iotdm] [sfc]' + - jacoco-report + +- job-template: + name: 'cardinal-sonar' + disabled: false + + project-type: maven + node: dynamic_verify + jdk: 'openjdk8' + + logrotate: + daysToKeep: '7' + numToKeep: '10' + artifactDaysToKeep: '1' + artifactNumToKeep: '1' + + parameters: + - project-parameter: + project: '{project}' + + scm: + - git-scm: + credentials-id: '{ssh-credentials}' + refspec: '' + branch: 'master' + + wrappers: + - build-timeout + - ssh-agent-credentials: + users: + - '{ssh-credentials}' + + triggers: + - timed: 'H H * * 6' + - gerrit-trigger-patch-sonar: + name: 'cardinal' + + prebuilders: + - wipe-org-opendaylight-repo + - jacoco-nojava-workaround + - provide-maven-settings: + global-settings-file: '{odl-global-settings}' + settings-file: '{cardinal-settings}' + + maven: + maven-name: '{mvn33}' + root-pom: 'pom.xml' + goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Djenkins -Dsonar' + maven-opts: '-Xmx1024m -XX:MaxPermSize=256m' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + + reporters: + - findbugs + + publishers: + - sonar: + language: 'java' + maven-opts: '-Xmx6144m -XX:MaxPermSize=1024m' + - email-notification: + email-prefix: '[cardinal]' + - jacoco-report + +- job-template: + name: 'cardinal-clm-{stream}' + disabled: false + + project-type: maven + node: dynamic_verify + jdk: '{jdk}' + + logrotate: + daysToKeep: '{build-days-to-keep}' + numToKeep: '{build-num-to-keep}' + artifactDaysToKeep: '{build-artifact-days-to-keep}' + artifactNumToKeep: '{build-artifact-num-to-keep}' + + parameters: + - project-parameter: + project: '{project}' + + scm: + - git-scm: + credentials-id: '{ssh-credentials}' + refspec: '' + branch: '{branch}' + + wrappers: + - build-timeout + - ssh-agent-credentials: + users: + - '{ssh-credentials}' + + triggers: + - timed: 'H H * * 6' + + prebuilders: + - wipe-org-opendaylight-repo + - provide-maven-settings: + global-settings-file: '{odl-global-settings}' + settings-file: '{cardinal-settings}' + + maven: + maven-name: '{mvn33}' + root-pom: 'pom.xml' + goals: 'clean install com.sonatype.clm:clm-maven-plugin:index -Djenkins -DskipTests=true -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r' + maven-opts: '-Xmx4096m -XX:MaxPermSize=512m' + settings: '{cardinal-settings}' + global-settings: '{odl-global-settings}' + + postbuilders: + - shell: 'find . -regex ".*karaf/target" | xargs rm -rf' + - check-clm: + application-name: cardinal + + publishers: + - email-notification: + email-prefix: '[cardinal]' + +- job-template: + name: 'cardinal-validate-autorelease-{stream}' + disabled: '{obj:disable_autorelease}' + + project-type: maven + node: dynamic_verify + concurrent: true + jdk: '{jdk}' + + logrotate: + daysToKeep: '{build-days-to-keep}' + numToKeep: '{build-num-to-keep}' + artifactDaysToKeep: '{build-artifact-days-to-keep}' + artifactNumToKeep: '{build-artifact-num-to-keep}' + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + - autorelease-release-tag: + release-tag: 'validate' + - autorelease-release-branch: + release-branch: '{branch}' + - autorelease-release-datestamp: + datestamp: true + + scm: + - git: + url: 'https://git.opendaylight.org/gerrit/releng/autorelease' + refspec: '' + branches: + - 'origin/{branch}' + skip-tag: true + submodule: + recursive: true + + wrappers: + - autorelease-build-timeout + - ssh-agent-credentials: + users: + - '{ssh-credentials}' + + triggers: + - gerrit: + server-name: 'OpenDaylight' + trigger-on: + - patchset-created-event: + exclude-drafts: 'false' + exclude-trivial-rebase: 'false' + exclude-no-code-change: 'false' + - draft-published-event + - comment-added-contains-event: + comment-contains-value: 'recheck' + - comment-added-contains-event: + comment-contains-value: 'reverify' + - comment-added-contains-event: + comment-contains-value: 'revalidate' + projects: + - project-compare-type: 'ANT' + project-pattern: 'cardinal' + branches: + - branch-compare-type: 'ANT' + branch-pattern: '**/{branch}' + file-paths: + - compare-type: ANT + pattern: '**/*.xml' + + prebuilders: + - wipe-org-opendaylight-repo + - jacoco-nojava-workaround + - autorelease-checkout-gerrit-patch + - autorelease-generate-release-patches + - maven-target: + maven-version: '{mvn33}' + pom: validate-pom.xml + goals: 'clean install -T1.5C -Djenkins -DskipTests -Dcheckstyle.skip=true -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r' + java-opts: + - '-Xmx8g' + settings: '{autorelease-settings}' + global-settings: '{odl-global-settings}' + + maven: + maven-name: '{mvn33}' + root-pom: 'pom.xml' + goals: 'clean validate -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r' + maven-opts: '-Xmx8g -XX:MaxPermSize=1024m -Dmaven.compile.fork=true' + settings: '{autorelease-settings}' + global-settings: '{odl-global-settings}' + automatic-archiving: false + post-step-run-condition: UNSTABLE + + postbuilders: + - autorelease-sys-stats + + publishers: + - email-notification: + email-prefix: '[autorelease] [cardinal]' + diff --git a/jjb/integration/include-raw-integration-configure-clustering.sh b/jjb/integration/include-raw-integration-configure-clustering.sh index d0f7af7e2..ffe71eef4 100644 --- a/jjb/integration/include-raw-integration-configure-clustering.sh +++ b/jjb/integration/include-raw-integration-configure-clustering.sh @@ -71,18 +71,8 @@ cat ${MODULESCONF} echo "Dump module-shards.conf" cat ${MODULESHARDSCONF} -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_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}" @@ -110,4 +100,3 @@ do done # vim: ts=4 sw=4 sts=4 et ft=sh : - 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..0f3d93f59 100644 --- a/jjb/integration/include-raw-integration-deploy-controller-run-test.sh +++ b/jjb/integration/include-raw-integration-deploy-controller-run-test.sh @@ -61,18 +61,8 @@ 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_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}" @@ -146,7 +136,7 @@ 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} \ diff --git a/jjb/integration/include-raw-integration-get-bundle-vars.sh b/jjb/integration/include-raw-integration-get-bundle-vars.sh index 641503eba..c2f592a7c 100644 --- a/jjb/integration/include-raw-integration-get-bundle-vars.sh +++ b/jjb/integration/include-raw-integration-get-bundle-vars.sh @@ -26,11 +26,20 @@ else BUNDLEFOLDER="distribution-karaf-${BUNDLEVERSION}" fi +if [ ${JDKVERSION} == 'openjdk8' ]; then + echo "Preparing for JRE Version 8" + JAVA_HOME="/usr/lib/jvm/java-1.8.0" +elif [ ${JDKVERSION} == 'openjdk7' ]; then + echo "Preparing for JRE Version 7" + JAVA_HOME="/usr/lib/jvm/java-1.7.0" +fi + echo "Distribution bundle URL is ${ACTUALBUNDLEURL}" echo "Distribution bundle is ${BUNDLE}" echo "Distribution bundle version is ${BUNDLEVERSION}" echo "Distribution folder is ${BUNDLEFOLDER}" echo "Nexus prefix is ${NEXUSURL_PREFIX}" +echo "Java home is ${JAVA_HOME}" cat > ${WORKSPACE}/bundle_vars.txt <