summaryrefslogtreecommitdiffstats
path: root/jjb
diff options
context:
space:
mode:
Diffstat (limited to 'jjb')
-rw-r--r--jjb/dcae/include-raw-apod-cdap.sh21
-rw-r--r--jjb/global-templates-java.yaml105
-rw-r--r--jjb/global-templates-script.yaml6
-rw-r--r--jjb/mso/mso-libs.yaml2
-rw-r--r--jjb/mso/mso.yaml2
-rw-r--r--jjb/ncomp/ncomp-utils.yaml3
-rw-r--r--jjb/policy/include-raw-docker.sh13
-rw-r--r--jjb/policy/policy-docker.yaml19
-rw-r--r--jjb/portal/docker-build-deploy.sh6
-rw-r--r--jjb/portal/portal-docker.yaml2
10 files changed, 173 insertions, 6 deletions
diff --git a/jjb/dcae/include-raw-apod-cdap.sh b/jjb/dcae/include-raw-apod-cdap.sh
index 29e9c4a01..d87b49ad0 100644
--- a/jjb/dcae/include-raw-apod-cdap.sh
+++ b/jjb/dcae/include-raw-apod-cdap.sh
@@ -34,7 +34,17 @@ OUTPUT_FILE="${PACKAGE_NAME_APPLICATION}_${PACKAGE_NAME_VERSION}.deb"
OUTPUT_FILE_DATE_STAMPED= \
"${PACKAGE_NAME_APPLICATION}_${PACKAGE_NAME_VERSION}-${DATE_STAMP}.deb"
-
+echo 'Package variables:'
+echo " STAGE_DIR = ${STATE_DIR}"
+echo " OUTPUT_DIR = ${OUTPUT_DIR}"
+echo " PACKAGE_BUILD_NUMBER = ${PACKAGE_BUILD_NUMBER}"
+echo " PACKAGE_NAME_APPLICATION = ${PACKAGE_NAME_APPLICATION}"
+echo " PACKAGE_NAME_VERSION = ${PACKAGE_NAME_VERSION}"
+echo " PACKAGE_GROUP_ID = ${PACKAGE_GROUP_ID}"
+echo " OUTPUT_FILE = ${OUTPUT_FILE}"
+echo " OUTPUT_FILE_DATE_STAMPED = ${OUTPUT_FILE_DATE_STAMPED}"
+
+echo 'Creating Staging and Output directories'
rm -rf ${STAGE_DIR}
rm -rf ${OUTPUT_DIR}
mkdir -p ${STAGE_DIR}/stage/opt/app/dcae-cdap-small-hadoop
@@ -46,11 +56,17 @@ cp -R ${WORKSPACE}/cdap3vm/* ${STAGE_DIR}/stage/opt/app/dcae-cdap-small-hadoop
echo 'Copying json file to stage'
cp ${WORKSPACE}/dcae-apod-buildtools/configs/package-cdap3vm.json ${STAGE_DIR}/package.json
+echo 'Contents of stage directory'
+ls -lR ${STAGE_DIR}
+
echo "Creating debian package"
${WORKSPACE}/dcae-apod-buildtools/scripts/package -b debian -d ${STAGE_DIR} \
-o ${OUTPUT_DIR} -y package.json -B ${PACKAGE_BUILD_NUMBER} -v
+echo "Contents of output directory"
+ls -lR ${OUTPUT_DIR}
+
# The controller needs the debian packaged named
# dcae-cdap-small-hadoop_17.01.0-LATEST.deb so it can find and deploy it.
# In order to have a copy of each file built a copy of
@@ -63,10 +79,13 @@ cp ${OUTPUT_DIR}/${OUTPUT_FILE_DATE_STAMPED} ${OUTPUT_DIR}/${OUTPUT_FILE}
SEND_TO= \
"${OPENECOMP_NEXUS_REPO}/org.openecomp.dcae.apod.cdap/deb-snapshots/${PACKAGE_GROUP_ID}/${OUTPUT_FILE}"
+echo "Sending ${OUTPUT_DIR}/${OUTPUT_FILE} to Nexus Repo: ${SEND_TO}"
curl -vkn --netrc-file "${NETRC}" --upload-file ${OUTPUT_DIR}/${OUTPUT_FILE} ${SEND_TO}
SEND_TO= \
"${OPENECOMP_NEXUS_REPO}/org.openecomp.dcae.apod.cdap/deb-snapshots/${PACKAGE_GROUP_ID}/${OUTPUT_FILE_DATE_STAMPED}"
+
+echo "Sending ${OUTPUT_DIR}/${OUTPUT_FILE_DATE_STAMPED} to Nexus Repo: ${SEND_TO}"
curl -vkn --netrc-file "${NETRC}" --upload-file ${OUTPUT_DIR}/${OUTPUT_FILE_DATE_STAMPED} ${SEND_TO}
echo '===================== ENDING SCRIPT TO CREATE DEBIAN FILE ======================='
diff --git a/jjb/global-templates-java.yaml b/jjb/global-templates-java.yaml
index b88567f1d..3c50fdace 100644
--- a/jjb/global-templates-java.yaml
+++ b/jjb/global-templates-java.yaml
@@ -226,6 +226,62 @@
global-settings-file: 'global-settings'
settings-file: '{mvn-settings}'
+ - maven-target:
+ maven-version: 'mvn33'
+ goals: 'clean deploy sonar:sonar -Dsonar.host.url=https://sonar.openecomp.org'
+ properties:
+ - '{maven-deploy-properties}'
+ settings: '{mvn-settings}'
+ settings-type: cfp
+ global-settings: 'global-settings'
+ global-settings-type: cfp
+
+- job-template:
+ # Job template for Java daily release jobs
+ #
+ # The purpose of this job template is to run "maven version && maven clean
+ # deploy" for projects using this template.
+ #
+ # Required Variables:
+ # branch: git branch (eg. stable/lithium or master)
+ name: '{project-name}-{stream}-release-version-java-daily'
+
+ project-type: freestyle
+ node: '{build-node}'
+ maven-deploy-properties:
+ properties:
+ - ecomp-infra-properties:
+ build-days-to-keep: '{build-days-to-keep}'
+
+ parameters:
+ - ecomp-infra-parameters:
+ project: '{project}'
+ branch: '{branch}'
+ refspec: 'refs/heads/{branch}'
+ artifacts: '{archive-artifacts}'
+
+ scm:
+ - gerrit-trigger-scm:
+ refspec: ''
+ choosing-strategy: 'default'
+
+ wrappers:
+ - ecomp-infra-wrappers:
+ build-timeout: '{build-timeout}'
+
+ triggers:
+ # 11 AM UTC
+ - timed: 'H 11 * * *'
+ - gerrit-trigger-release-manually:
+ server: '{server-name}'
+ project: '{project}'
+ branch: '{branch}'
+
+ builders:
+ - provide-maven-settings:
+ global-settings-file: 'global-settings'
+ settings-file: '{mvn-settings}'
+
- inject:
properties-file: version.properties
- maven-target:
@@ -536,3 +592,52 @@
pom: '{docker-pom}'
# use default as mvn-profile if profile is not needed
mvn-profile: '{mvn-profile}'
+
+- job-template:
+ name: '{project-name}-{stream}-docker-java-shell-daily'
+ project-type: freestyle
+ node: 'ubuntu1604-docker-8c-8g'
+
+ properties:
+ - ecomp-infra-properties:
+ build-days-to-keep: '{build-days-to-keep}'
+
+ parameters:
+ - ecomp-infra-parameters:
+ project: '{project}'
+ branch: '{branch}'
+ refspec: 'refs/heads/{branch}'
+ artifacts: '{archive-artifacts}'
+
+ scm:
+ - gerrit-trigger-scm:
+ refspec: ''
+ choosing-strategy: 'default'
+
+ wrappers:
+ - ecomp-infra-wrappers:
+ build-timeout: '{build-timeout}'
+
+ triggers:
+ # 12 AM UTC
+ - timed: 'H 12 * * *'
+ - gerrit-trigger-release-manually:
+ server: '{server-name}'
+ project: '{project}'
+ branch: '{branch}'
+
+ builders:
+
+ - provide-maven-settings:
+ global-settings-file: 'global-settings'
+ settings-file: '{mvn-settings}'
+
+ - docker-login
+
+ - maven-docker-push-daily:
+ mvn-settings: '{mvn-settings}'
+ pom: '{docker-pom}'
+ # use default as mvn-profile if profile is not needed
+ mvn-profile: '{mvn-profile}'
+
+ - shell: '{script}'
diff --git a/jjb/global-templates-script.yaml b/jjb/global-templates-script.yaml
index d43bc87c5..83593727b 100644
--- a/jjb/global-templates-script.yaml
+++ b/jjb/global-templates-script.yaml
@@ -25,6 +25,8 @@
branch: '{branch}'
refspec: 'refs/heads/{branch}'
artifacts: '{archive-artifacts}'
+ - maven-exec:
+ maven-version: 'mvn33'
scm:
- gerrit-trigger-scm:
@@ -91,6 +93,8 @@
branch: '{branch}'
refspec: 'refs/heads/{branch}'
artifacts: '{archive-artifacts}'
+ - maven-exec:
+ maven-version: 'mvn33'
scm:
- gerrit-trigger-scm:
@@ -169,6 +173,8 @@
branch: '{branch}'
refspec: 'refs/heads/{branch}'
artifacts: '{archive-artifacts}'
+ - maven-exec:
+ maven-version: 'mvn33'
scm:
- gerrit-trigger-scm:
diff --git a/jjb/mso/mso-libs.yaml b/jjb/mso/mso-libs.yaml
index 99c25d425..e44632a11 100644
--- a/jjb/mso/mso-libs.yaml
+++ b/jjb/mso/mso-libs.yaml
@@ -5,7 +5,7 @@
jobs:
- '{project-name}-{stream}-verify-java'
- '{project-name}-{stream}-merge-java'
- - '{project-name}-{stream}-release-java-daily'
+ - '{project-name}-{stream}-release-version-java-daily'
project: 'mso/libs'
stream:
diff --git a/jjb/mso/mso.yaml b/jjb/mso/mso.yaml
index 2628fecb1..ae78a4d82 100644
--- a/jjb/mso/mso.yaml
+++ b/jjb/mso/mso.yaml
@@ -6,7 +6,7 @@
jobs:
- '{project-name}-{stream}-verify-java'
- '{project-name}-{stream}-merge-java'
- - '{project-name}-{stream}-release-java-daily'
+ - '{project-name}-{stream}-release-version-java-daily'
- '{project-name}-{stream}-docker-java-daily':
docker-pom: 'pom.xml'
mvn-profile: 'docker'
diff --git a/jjb/ncomp/ncomp-utils.yaml b/jjb/ncomp/ncomp-utils.yaml
index 985c7913a..0efcb1f45 100644
--- a/jjb/ncomp/ncomp-utils.yaml
+++ b/jjb/ncomp/ncomp-utils.yaml
@@ -4,7 +4,8 @@
project-name: 'ncomp-utils'
jobs:
- '{project-name}-{stream}-verify-java'
- - '{project-name}-{stream}-merge-java'
+ - '{project-name}-{stream}-downstream-merge-java':
+ dependencies: 'ncomp-master-merge-java'
- '{project-name}-{stream}-release-java-daily'
project: 'ncomp/utils'
diff --git a/jjb/policy/include-raw-docker.sh b/jjb/policy/include-raw-docker.sh
new file mode 100644
index 000000000..642d8c23b
--- /dev/null
+++ b/jjb/policy/include-raw-docker.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+#
+echo '============== STARTING SCRIPT TO BUILD DOCKER IMAGES ================='
+
+for image in policy-os policy-nexus policy-db policy-base policy-drools policy-pe ; do
+ mkdir -p target/$image
+ cp $image/* target/$image
+ docker build --quiet --tag ${DOCKER_REPOSITORY}/policy/$image target/$image
+done
+
+for image in policy-nexus policy-db policy-drools policy-pe; do
+ docker push ${DOCKER_REPOSITORY}/policy/$image
+done
diff --git a/jjb/policy/policy-docker.yaml b/jjb/policy/policy-docker.yaml
new file mode 100644
index 000000000..e7e5f9f24
--- /dev/null
+++ b/jjb/policy/policy-docker.yaml
@@ -0,0 +1,19 @@
+---
+- project:
+ name: policy-docker
+ project-name: 'policy-docker-policy'
+ jobs:
+ - '{project-name}-{stream}-docker-java-shell-daily':
+ docker-pom: 'pom.xml'
+ mvn-profile: 'prepare-package'
+ script:
+ !include-raw-escape: 'include-raw-docker.sh'
+
+ project: 'policy/docker'
+ stream:
+ - 'master':
+ branch: 'master'
+ mvn-settings: 'policy-docker-settings'
+ files: '**'
+ archive-artifacts: ''
+ build-node: ubuntu1604-basebuild-4c-4g
diff --git a/jjb/portal/docker-build-deploy.sh b/jjb/portal/docker-build-deploy.sh
index a9b67e708..f7d1b823f 100644
--- a/jjb/portal/docker-build-deploy.sh
+++ b/jjb/portal/docker-build-deploy.sh
@@ -1,4 +1,8 @@
CURRENTDIR="$(pwd)"
echo $CURRENTDIR
-ls -ltr \ No newline at end of file
+ls -ltr
+cd deliveries
+ls -ltr
+chmod 755 *.*
+./run.sh \ No newline at end of file
diff --git a/jjb/portal/portal-docker.yaml b/jjb/portal/portal-docker.yaml
index 7cf612f2d..8f9c447c5 100644
--- a/jjb/portal/portal-docker.yaml
+++ b/jjb/portal/portal-docker.yaml
@@ -13,7 +13,7 @@
mvn-settings: 'portal-settings'
files: '**'
archive-artifacts: ''
- build-node: ubuntu1604-basebuild-4c-4g
+ build-node: ubuntu1604-docker-8c-8g
extra-project1: 'ecompsdkos'
extra-branch1: 'master'
extra-refspec1: 'refs/heads/{branch}'