Merge "Static code analysis for ric-plt-streaming-protobufs"
diff --git a/global-jjb b/global-jjb
index 59faa99..33f5bf5 160000
--- a/global-jjb
+++ b/global-jjb
@@ -1 +1 @@
-Subproject commit 59faa9977d726858902dcf513999616aaf6de7a5
+Subproject commit 33f5bf5ae760a7c815e39092a216f42ffcc42fbb
diff --git a/jenkins-config/clouds/openstack/cattle/centos7-builder-1c-1g.cfg b/jenkins-config/clouds/openstack/cattle/centos7-builder-1c-1g.cfg
index 3021ff5..92ec847 100644
--- a/jenkins-config/clouds/openstack/cattle/centos7-builder-1c-1g.cfg
+++ b/jenkins-config/clouds/openstack/cattle/centos7-builder-1c-1g.cfg
@@ -1,3 +1,4 @@
+LABELS=centos7-builder-1c-1g
IMAGE_NAME=ZZCI - CentOS 7 - builder - x86_64 - 20200317-165605.039
-VOLUME_SIZE=20
HARDWARE_ID=v2-highcpu-1
+VOLUME_SIZE=20
diff --git a/jenkins-config/clouds/openstack/cattle/centos7-docker-2c-8g-200g.cfg b/jenkins-config/clouds/openstack/cattle/centos7-docker-2c-8g-200g.cfg
index 62407da..5f4ed86 100644
--- a/jenkins-config/clouds/openstack/cattle/centos7-docker-2c-8g-200g.cfg
+++ b/jenkins-config/clouds/openstack/cattle/centos7-docker-2c-8g-200g.cfg
@@ -1,3 +1,4 @@
+LABELS=centos7-docker-2c-8g-200g
IMAGE_NAME=ZZCI - CentOS 7 - docker - x86_64 - 20200317-104237.628
HARDWARE_ID=v2-standard-2
VOLUME_SIZE=200
diff --git a/jenkins-config/clouds/openstack/cattle/centos7-docker-2c-8g.cfg b/jenkins-config/clouds/openstack/cattle/centos7-docker-2c-8g.cfg
index 00cb8b3..a1a39a1 100644
--- a/jenkins-config/clouds/openstack/cattle/centos7-docker-2c-8g.cfg
+++ b/jenkins-config/clouds/openstack/cattle/centos7-docker-2c-8g.cfg
@@ -1,3 +1,4 @@
+LABELS=centos7-docker-2c-8g
IMAGE_NAME=ZZCI - CentOS 7 - docker - x86_64 - 20200317-104237.628
HARDWARE_ID=v2-standard-2
VOLUME_SIZE=20
diff --git a/jenkins-config/clouds/openstack/cattle/centos8-builder-1c-1g.cfg b/jenkins-config/clouds/openstack/cattle/centos8-builder-1c-1g.cfg
index 1e1fddc..16cb749 100644
--- a/jenkins-config/clouds/openstack/cattle/centos8-builder-1c-1g.cfg
+++ b/jenkins-config/clouds/openstack/cattle/centos8-builder-1c-1g.cfg
@@ -1,3 +1,4 @@
+LABELS=centos8-builder-1c-1g
IMAGE_NAME=ZZCI - CentOS 8 - builder - x86_64 - 20200403-151332.560
VOLUME_SIZE=20
HARDWARE_ID=v2-highcpu-1
diff --git a/jenkins-config/clouds/openstack/cattle/ubuntu1804-builder-2c-2g.cfg b/jenkins-config/clouds/openstack/cattle/ubuntu1804-builder-2c-2g.cfg
index 1cf4672..c6edac7 100644
--- a/jenkins-config/clouds/openstack/cattle/ubuntu1804-builder-2c-2g.cfg
+++ b/jenkins-config/clouds/openstack/cattle/ubuntu1804-builder-2c-2g.cfg
@@ -1,4 +1,4 @@
-IMAGE_NAME=ZZCI - Ubuntu 18.04 - builder - x86_64 - 20200317-165726.675
LABELS=ubuntu1804-builder-2c-2g
+IMAGE_NAME=ZZCI - Ubuntu 18.04 - builder - x86_64 - 20200317-165726.675
HARDWARE_ID=v2-highcpu-2
VOLUME_SIZE=20
diff --git a/jenkins-config/clouds/openstack/cattle/ubuntu1804-builder-4c-4g.cfg b/jenkins-config/clouds/openstack/cattle/ubuntu1804-builder-4c-4g.cfg
index 1c6f38a..d331089 100644
--- a/jenkins-config/clouds/openstack/cattle/ubuntu1804-builder-4c-4g.cfg
+++ b/jenkins-config/clouds/openstack/cattle/ubuntu1804-builder-4c-4g.cfg
@@ -1,4 +1,4 @@
-IMAGE_NAME=ZZCI - Ubuntu 18.04 - builder - x86_64 - 20200317-165726.675
LABELS=ubuntu1804-builder-4c-4g
+IMAGE_NAME=ZZCI - Ubuntu 18.04 - builder - x86_64 - 20200317-165726.675
HARDWARE_ID=v2-highcpu-4
VOLUME_SIZE=20
diff --git a/jenkins-config/clouds/openstack/cattle/ubuntu1804-docker-4c-4g.cfg b/jenkins-config/clouds/openstack/cattle/ubuntu1804-docker-4c-4g.cfg
index 3df02e5..fbaf72b 100644
--- a/jenkins-config/clouds/openstack/cattle/ubuntu1804-docker-4c-4g.cfg
+++ b/jenkins-config/clouds/openstack/cattle/ubuntu1804-docker-4c-4g.cfg
@@ -1,4 +1,4 @@
-IMAGE_NAME=ZZCI - Ubuntu 18.04 - docker - x86_64 - 20200317-104132.496
LABELS=ubuntu1804-docker-4c-4g
+IMAGE_NAME=ZZCI - Ubuntu 18.04 - docker - x86_64 - 20200317-104132.496
HARDWARE_ID=v2-highcpu-4
VOLUME_SIZE=20
diff --git a/jjb/com-log/com-log.yaml b/jjb/com-log/com-log.yaml
index 658bca0..266ebaa 100644
--- a/jjb/com-log/com-log.yaml
+++ b/jjb/com-log/com-log.yaml
@@ -102,6 +102,8 @@
<<: *com_log_common
# these templates ignore the pre-build script
name: com-log-release
+ # release uses sigul which requires centos
+ build-node: centos7-builder-1c-1g
jobs:
- gerrit-packagecloud-release-verify
- gerrit-packagecloud-release-merge
diff --git a/jjb/com-pylog/com-pylog.yaml b/jjb/com-pylog/com-pylog.yaml
index 83f2a3b..45a391f 100644
--- a/jjb/com-pylog/com-pylog.yaml
+++ b/jjb/com-pylog/com-pylog.yaml
@@ -30,6 +30,15 @@
name: pylog-pypi
# the code is in a subdirectory
tox-dir: mdclogpy
+ gerrit_trigger_file_paths:
+ - compare-type: REG_EXP
+ pattern: 'mdclogpy/.*'
+ stream:
+ - master:
+ branch: master
+ jobs:
+ - gerrit-pypi-verify
+ - gerrit-pypi-stage
- project:
<<: *pylog_common
@@ -43,15 +52,6 @@
build-node: centos7-docker-2c-8g
# do not trigger on changes in docs, releases
- gerrit_trigger_file_paths:
- - compare-type: REG_EXP
- pattern: 'mdclogpy/.*'
- stream:
- - master:
- branch: master
- jobs:
- - gerrit-pypi-verify
- - gerrit-pypi-stage
- pylog_python: &pylog_python
# settings for python builds
diff --git a/jjb/nonrtric/nonrtric.yaml b/jjb/nonrtric/nonrtric.yaml
index 4d85643..827dbdb 100644
--- a/jjb/nonrtric/nonrtric.yaml
+++ b/jjb/nonrtric/nonrtric.yaml
@@ -28,8 +28,7 @@
<<: *nonrtric_jdk_common
mvn-params: -Dbuild.number=${{BUILD_NUMBER}}
jobs:
- - gerrit-maven-docker-verify:
- mvn-opts: -Dexec.skip=false
+ - gerrit-maven-docker-verify
- gerrit-maven-docker-merge
- gerrit-maven-docker-stage
stream:
@@ -44,7 +43,7 @@
<<: *nonrtric_jdk_common
name: nonrtric-policy-agent
project-name: '{name}'
- mvn-opts: '-Ddocker.skip=true -Dexec.skip=true'
+ mvn-opts: '-Ddocker.skip=true'
mvn-params: '-f policy-agent'
gerrit_trigger_file_paths:
- compare-type: REG_EXP
@@ -67,7 +66,7 @@
<<: *nonrtric_jdk_common
name: nonrtric-sdnc-a1-controller
project-name: '{name}'
- mvn-opts: '-Ddocker.skip=true -Dexec.skip=true'
+ mvn-opts: '-Ddocker.skip=true'
mvn-params: '-f sdnc-a1-controller/northbound'
gerrit_trigger_file_paths:
- compare-type: REG_EXP
@@ -97,7 +96,7 @@
<<: *nonrtric_jdk_common
name: nonrtric-sonar
# template goal install builds docker image unnecessarily
- mvn-params: '-Ddocker.skip=true -Dexec.skip=true'
+ mvn-params: '-Ddocker.skip=true'
sonarcloud: true
sonarcloud-api-token: '{sonarcloud_api_token}'
sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
diff --git a/jjb/ric-app-hw-go/ric-app-hw-go.yaml b/jjb/ric-app-hw-go/ric-app-hw-go.yaml
new file mode 100644
index 0000000..37386ff
--- /dev/null
+++ b/jjb/ric-app-hw-go/ric-app-hw-go.yaml
@@ -0,0 +1,24 @@
+---
+- project:
+ name: ric-app-hw-go-project-view
+ project-name: ric-app-hw-go
+ views:
+ - project-view
+
+- hw-go_common: &hw-go_common
+ # values apply to all projects
+ name: hw-go-common
+ # git repo
+ project: ric-app/hw-go
+ # jenkins prefix
+ project-name: ric-app-hw-go
+ # maven settings file has docker credentials
+ mvn-settings: ric-app-hw-go-settings
+
+# verify INFO.yaml changes
+- project:
+ <<: *hw-go_common
+ name: ric-app-hw-go-info
+ build-node: centos7-builder-1c-1g
+ jobs:
+ - gerrit-info-yaml-verify
diff --git a/jjb/ric-app-hw-python/ric-app-hw-python.yaml b/jjb/ric-app-hw-python/ric-app-hw-python.yaml
new file mode 100644
index 0000000..67549cf
--- /dev/null
+++ b/jjb/ric-app-hw-python/ric-app-hw-python.yaml
@@ -0,0 +1,24 @@
+---
+- project:
+ name: ric-app-hw-python-project-view
+ project-name: ric-app-hw-python
+ views:
+ - project-view
+
+- hw-python_common: &hw-python_common
+ # values apply to all projects
+ name: hw-python-common
+ # git repo
+ project: ric-app/hw-python
+ # jenkins prefix
+ project-name: ric-app-hw-python
+ # maven settings file has docker credentials
+ mvn-settings: ric-app-hw-python-settings
+
+# verify INFO.yaml changes
+- project:
+ <<: *hw-python_common
+ name: ric-app-hw-python-info
+ build-node: centos7-builder-1c-1g
+ jobs:
+ - gerrit-info-yaml-verify
diff --git a/jjb/ric-plt-dbaas/ric-plt-dbaas.yaml b/jjb/ric-plt-dbaas/ric-plt-dbaas.yaml
index cc525c4..6b49119 100644
--- a/jjb/ric-plt-dbaas/ric-plt-dbaas.yaml
+++ b/jjb/ric-plt-dbaas/ric-plt-dbaas.yaml
@@ -13,36 +13,91 @@
jobs:
- gerrit-info-yaml-verify
-- dbaas_docker_common: &dbaas_docker_common
- # values apply to all dbaas docker projects
- name: dbaas-docker-common
+- dbaas_common: &dbaas_common
+ # values apply to all ric-plt/dbaas projects
+ name: dbaas-common
# git repo
project: ric-plt/dbaas
# jenkins job name prefix
project-name: ric-plt-dbaas
- # maven settings file has docker credentials
+ # maven settings file has credentials
mvn-settings: ric-plt-dbaas-settings
+# compile code and run tests
- project:
- <<: *dbaas_docker_common
- name: ric-plt-dbaas
- # image name
- docker-name: 'o-ran-sc/{name}'
- # Specify docker file and host network
- docker-build-args: '--network=host -f docker/Dockerfile.redis'
- # source of docker tag
- container-tag-method: yaml-file
+ <<: *dbaas_common
+ name: ric-plt-dbaas-lib
+ pre-build: !include-raw-escape: setup-dbaas-build-deb.sh
+ build-node: ubuntu1804-builder-2c-2g
+ make-opts: -j 2 test
jobs:
- - '{project-name}-gerrit-docker-jobs'
+ - gerrit-autotools-verify
stream:
- master:
branch: master
-- project:
- <<: *dbaas_docker_common
- name: ric-plt-dbaas-release
- # maven release requires sigul which requires centos
- # container release requires docker
- build-node: centos7-docker-2c-8g
+# common settings for building DEB and RPM packages
+- dbaas_pkg_common: &dbaas_pkg_common
+ name: ric-plt-pkg-cmn
+ pre-build: !include-raw-escape: setup-dbaas-build-deb.sh
+ # directory with package files
+ build-dir: pkg
+ # docker image has the package_cloud gem
+ build-node: ubuntu1804-docker-4c-4g
jobs:
- - '{project-name}-gerrit-release-jobs'
+ - gerrit-autotools-packagecloud-stage
+ stream:
+ - master:
+ branch: master
+
+# build DEB package files
+- project:
+ <<: *dbaas_common
+ <<: *dbaas_pkg_common
+ name: ric-plt-dbaas-deb
+ project-name: '{name}'
+ configure-opts: --with-deb-dir={build-dir}
+ make-opts: -j4 deb-pkg
+
+# build RPM package files
+- project:
+ <<: *dbaas_common
+ <<: *dbaas_pkg_common
+ name: ric-plt-dbaas-rpm
+ project-name: '{name}'
+ configure-opts: --with-rpm-dir={build-dir}
+ # parallel jobs (option -j) fail on rpm build
+ # https://bugzilla.redhat.com/show_bug.cgi?id=1398405
+ make-opts: rpm-pkg
+
+# analyze C code and test coverage
+- project:
+ <<: *dbaas_common
+ name: ric-plt-lib-dbaas-sonarqube
+ pre-build: !include-raw-escape: setup-dbaas-build-deb.sh
+ build-node: ubuntu1804-docker-4c-4g
+ # set appropriate CXXFLAGS
+ configure-opts: --build=i686-pc-linux-gnu
+ # use all cores
+ make-opts: -j4 all
+ sonar-project-file: ""
+ sonar-properties: |
+ sonar.login={sonarcloud_api_token}
+ sonar.projectKey={sonarcloud_project_organization}_{project-name}
+ sonar.projectName={project-name}
+ sonar.organization={sonarcloud_project_organization}
+ sonar.build.sourceEncoding=UTF-8
+ sonar.sources=src
+ sonar.cfamily.build-wrapper-output=$WORKSPACE/bw-output
+ sonar.cfamily.cache.enabled=false
+ sonar.cfamily.gcov.reportsPath=gcov_report
+ sonar.cfamily.threads=4
+ jobs:
+ - gerrit-autotools-sonarqube
+
+- project:
+ <<: *dbaas_common
+ name: ric-plt-dbaas-release
+ jobs:
+ - gerrit-packagecloud-release-verify
+ - gerrit-packagecloud-release-merge
diff --git a/jjb/ric-plt-dbaas/setup-dbaas-build-deb.sh b/jjb/ric-plt-dbaas/setup-dbaas-build-deb.sh
new file mode 100644
index 0000000..6b89a09
--- /dev/null
+++ b/jjb/ric-plt-dbaas/setup-dbaas-build-deb.sh
@@ -0,0 +1,41 @@
+#!/bin/bash
+##############################################################################
+#
+# Copyright (c) 2020 HCL Technology.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+##############################################################################
+
+# Installs prerequisites needed to compile & test SDL code
+# and build RPM/DEB packages on a Debian/Ubuntu machine.
+
+echo "--> setup-sdl-build-deb.sh"
+
+# Ensure we fail the job if any steps fail.
+set -eux -o pipefail
+
+# install prereqs
+sudo apt-get update && sudo apt-get -q -y install \
+ autoconf-archive libhiredis-dev rpm valgrind \
+ libboost-filesystem-dev libboost-program-options-dev libboost-system-dev
+
+# generate configure script
+cd redismodule
+autoreconf --install
+cd ..
+curl -L https://github.com/cpputest/cpputest/releases/download/v3.8/cpputest-3.8.tar.gz | \
+ tar --strip-components=1 -xzf -
+cmake -DCMAKE_BUILD_TYPE=Debug -DBUILD_COVERAGE=ON -DMEMORY_LEAK_DETECTION=OFF .
+sudo make install
+echo "--> setup-sdl-build-deb.sh ends"
\ No newline at end of file
diff --git a/jjb/ric-plt-tracelibcpp/ric-plt-tracelibcpp.yaml b/jjb/ric-plt-tracelibcpp/ric-plt-tracelibcpp.yaml
index c9784bd..a1b306a 100644
--- a/jjb/ric-plt-tracelibcpp/ric-plt-tracelibcpp.yaml
+++ b/jjb/ric-plt-tracelibcpp/ric-plt-tracelibcpp.yaml
@@ -13,37 +13,92 @@
jobs:
- gerrit-info-yaml-verify
-- tracelibcpp_docker_common: &tracelibcpp_docker_common
- # values apply to all tracelibcpp docker projects
- name: tracelibcpp-docker-common
- # git repo
+- tracelibcpp_common: &tracelibcpp_common
+ name: tracelibcpp-common
+ # git repo
project: ric-plt/tracelibcpp
# jenkins job name prefix
project-name: ric-plt-tracelibcpp
- # maven settings file has docker credentials
+ # maven settings file has credentials to archive artifacts
mvn-settings: ric-plt-tracelibcpp-settings
+ # test scripts depend on this name
+ build-dir: $WORKSPACE/build
+ # Use ubuntu base for cmake v3
+ # Use docker variant for packagecloud ruby gem
+ build-node: ubuntu1804-docker-4c-4g
+ # pre-build scripts for CMake templates:
+ # install alien package to build RPMS
+ # install RMR per version file in repo
+ pre-build: !include-raw-escape:
+ - ../shell/install-deb-alien.sh
+ # skip install in cmake-build.sh
+ install: false
+# verify every commit
- project:
- <<: *tracelibcpp_docker_common
- name: ric-plt-tracelibcpp
- # image name, altho it is never pushed
- docker-name: '{name}'
- # use host network
- docker-build-args: '--network=host -f ci/Dockerfile'
- # image tag; use a fixed value
- container-tag-method: latest
+ <<: *tracelibcpp_common
+ name: tracelibcpp-verify
+ cmake-opts: -DDEV_PKG=1
+ make-opts: package test ARGS=-V
jobs:
- - gerrit-docker-verify
- - oran-gerrit-docker-ci-pc-merge
+ - gerrit-cmake-verify
stream:
- master:
branch: master
+# development library - package and publish
- project:
+ <<: *tracelibcpp_common
+ name: ric-plt-tracelibcpp-dev
+ project-name: '{name}'
+ cmake-opts: -DDEV_PKG=1
+ make-opts: package
+ install-prefix: /usr/local
+ jobs:
+ - gerrit-cmake-packagecloud-stage
+ stream:
+ - master:
+ branch: master
+
+# runtime library - package and publish
+- project:
+ <<: *tracelibcpp_common
+ name: ric-plt-tracelibcpp-rt
+ project-name: '{name}'
+ cmake-opts: -DDEV_PKG=0
+ make-opts: package
+ install-prefix: /usr/local
+ jobs:
+ - gerrit-cmake-packagecloud-stage
+ stream:
+ - master:
+ branch: master
+
+# promote deb/rpm from staging to release at PackageCloud.io
+- project:
+ <<: *tracelibcpp_common
name: ric-plt-tracelibcpp-release
- project: ric-plt/tracelibcpp
- project-name: ric-plt-tracelibcpp
+ # release uses sigul which requires centos
build-node: centos7-builder-1c-1g
jobs:
- gerrit-packagecloud-release-verify
- gerrit-packagecloud-release-merge
+
+# analyze C code and test coverage
+- project:
+ name: tracelibcpp-sonarqube
+ <<: *tracelibcpp_common
+ make-opts: -j8 all
+ sonar-project-file: ""
+ sonar-properties: |
+ sonar.login={sonarcloud_api_token}
+ sonar.projectKey={sonarcloud_project_organization}_{project-name}
+ sonar.projectName={project-name}
+ sonar.organization={sonarcloud_project_organization}
+ sonar.scanner.force-deprecated-java-version=true
+ sonar.build.sourceEncoding=UTF-8
+ sonar.sources=src
+ sonar.cfamily.build-wrapper-output=$WORKSPACE/bw-output
+ sonar.cfamily.gcov.reportsPath=test
+ jobs:
+ - gerrit-cmake-sonarqube
diff --git a/jjb/ric-plt-utils/Dockerfile.build b/jjb/ric-plt-utils/Dockerfile.build
new file mode 100644
index 0000000..387bef3
--- /dev/null
+++ b/jjb/ric-plt-utils/Dockerfile.build
@@ -0,0 +1,83 @@
+# vi: ts=4 sw=4 noet:
+
+#==================================================================================
+# Copyright (c) 2020 AT&T Intellectual Property.
+# Copyright (c) 2020 Nokia
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#==================================================================================
+
+# Build the munchkin container assuming that the current working directory is the
+# top of the munchkin portion of the shared repo.
+
+# ---- these are global and must be set before the first from directive
+#
+# package versions and locations for easier maintenance
+ARG RMR_VER=4.1.4
+ARG LOG_VER=0.0.4
+ARG FRAME_VER=2.2.0
+
+ARG PROD_URL_BASE=https://packagecloud.io/o-ran-sc/release/packages/debian/stretch/
+ARG BETA_URL_BASE=https://packagecloud.io/o-ran-sc/staging/packages/debian/stretch/
+
+ARG LOG_BASE=${PROD_URL_BASE}
+ARG RMR_BASE=${BETA_URL_BASE}
+ARG FRAME_BASE=${BETA_URL_BASE}
+
+
+# -----------------------------------------------------------------------------------------------------
+FROM ubuntu:18.04
+
+RUN apt-get update \
+ && apt-get install -y git cmake make g++ wget curl libcurl4-gnutls-dev libcurlpp-dev libcurlpp0
+
+
+# sadly they need to be 'touched' to pull them into each stage
+ARG RMR_VER
+ARG LOG_VER
+ARG FRAME_VER
+ARG FRAME_BASE
+ARG RMR_BASE
+ARG LOG_BASE
+
+WORKDIR /playpen/down
+
+RUN wget --content-disposition ${LOG_BASE}/mdclog_${LOG_VER}-1_amd64.deb/download.deb \
+ && wget --content-disposition ${LOG_BASE}/mdclog-dev_${LOG_VER}-1_amd64.deb/download.deb \
+ && wget --content-disposition ${RMR_BASE}/rmr-dev_${RMR_VER}_amd64.deb/download.deb \
+ && wget --content-disposition ${RMR_BASE}/rmr_${RMR_VER}_amd64.deb/download.deb \
+ && wget --content-disposition ${FRAME_BASE}/ricxfcpp_${FRAME_VER}_amd64.deb/download.deb \
+ && wget --content-disposition ${FRAME_BASE}/ricxfcpp-dev_${FRAME_VER}_amd64.deb/download.deb \
+ && dpkg -i *deb
+
+
+
+WORKDIR /playpen/build
+COPY ./ ./
+
+# build the utility; installs into /usr/local/bin
+#
+RUN rm -fr .build \
+ && mkdir .build \
+ && cd .build \
+ && cmake .. \
+ && make install \
+ && make test ARGS="-V"
+
+
+
+#RUN mkdir /var/mgxapp
+#COPY xapp_config.json /var/mgxapp/config.json
+
+#WORKDIR /playpen
+#CMD [ "munchkin", "-c", "/var/mgxapp/config.json" ]
\ No newline at end of file
diff --git a/jjb/ric-plt-utils/cmake-sonarqube.sh b/jjb/ric-plt-utils/cmake-sonarqube.sh
new file mode 100644
index 0000000..891f1c3
--- /dev/null
+++ b/jjb/ric-plt-utils/cmake-sonarqube.sh
@@ -0,0 +1,17 @@
+#!/bin/bash
+# SPDX-License-Identifier: EPL-1.0
+##############################################################################
+# Copyright (c) 2020 HCL Technologies and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Eclipse Public License v1.0
+# which accompanies this distribution, and is available at
+# http://www.eclipse.org/legal/epl-v10.html
+##############################################################################
+echo "---> cmake-sonarqube.sh"
+cd mgxapp
+docker build -t ric-plt-utils -f Dockerfile.build .
+docker create --name ric-plt-utils ric-plt-utils
+docker cp ric-plt-utils:/playpen/build/test/ .
+docker rm ric-plt-utils
+echo "---> cmake-sonarqube.sh ends"
\ No newline at end of file
diff --git a/jjb/ric-plt-utils/ric-plt-utils.yaml b/jjb/ric-plt-utils/ric-plt-utils.yaml
index 276db49..3735fc6 100644
--- a/jjb/ric-plt-utils/ric-plt-utils.yaml
+++ b/jjb/ric-plt-utils/ric-plt-utils.yaml
@@ -7,8 +7,104 @@
- project:
name: ric-plt-utils-info
- project: ric-plt/utils
+ project: ric-plt-utils
project-name: ric-plt-utils
build-node: centos7-builder-1c-1g
jobs:
- gerrit-info-yaml-verify
+
+- utils_common: &utils_common
+ name: utils-common
+ # git repo
+ project: ric-plt/utils
+ # jenkins job name prefix
+ project-name: ric-plt-utils
+ # maven settings file has credentials to archive artifacts
+ mvn-settings: ric-plt-utils-settings
+ # test scripts depend on this name
+ build-dir: $WORKSPACE/mgxapp/build
+ # Use ubuntu base for cmake v3
+ # Use docker variant for packagecloud ruby gem
+ build-node: ubuntu1804-docker-4c-4g
+ # pre-build scripts for CMake templates:
+ # install alien package to build RPMS
+ # install RMR per version file in repo
+ pre-build: !include-raw-escape:
+ - ../shell/install-deb-alien.sh
+ - ./cmake-sonarqube.sh
+ # skip install in cmake-build.sh
+ install: false
+
+# verify every commit
+- project:
+ <<: *utils_common
+ name: utils-verify
+ cmake-opts: -DDEV_PKG=1
+ make-opts: package test ARGS=-V
+ jobs:
+ - gerrit-cmake-verify
+ stream:
+ - master:
+ branch: master
+
+# development library - package and publish
+- project:
+ <<: *utils_common
+ name: ric-plt-utils-dev
+ project-name: '{name}'
+ cmake-opts: -DDEV_PKG=1
+ make-opts: package
+ install-prefix: /usr/local
+ jobs:
+ - gerrit-cmake-packagecloud-stage
+ stream:
+ - master:
+ branch: master
+
+# runtime library - package and publish
+- project:
+ <<: *utils_common
+ name: ric-plt-utils-rt
+ project-name: '{name}'
+ cmake-opts: -DDEV_PKG=0
+ make-opts: package
+ install-prefix: /usr/local
+ jobs:
+ - gerrit-cmake-packagecloud-stage
+ stream:
+ - master:
+ branch: master
+
+# promote deb/rpm from staging to release at PackageCloud.io
+- project:
+ <<: *utils_common
+ name: ric-plt-utils-release
+ # release uses sigul which requires centos
+ build-node: centos7-builder-1c-1g
+ jobs:
+ - gerrit-packagecloud-release-verify
+ - gerrit-packagecloud-release-merge
+
+# analyze C code and test coverage
+- project:
+ name: utils-sonarqube
+ <<: *utils_common
+ make-opts: test ARGS=-V
+ sonar-project-file: ""
+ sonar-properties: |
+ sonar.login={sonarcloud_api_token}
+ sonar.projectKey={sonarcloud_project_organization}_{project-name}
+ sonar.projectName={project-name}
+ sonar.organization={sonarcloud_project_organization}
+ sonar.scanner.force-deprecated-java-version=true
+ sonar.build.sourceEncoding=UTF-8
+ sonar.sources=mgxapp/src
+ sonar.cfamily.threads=4
+ sonar.cfamily.cache.enabled=false
+ sonar.cfamily.build-wrapper-output=$WORKSPACE/bw-output
+ sonar.cfamily.gcov.reportsPath=test
+ sonar.c.file.suffixes=-
+ sonar.cpp.file.suffixes=-
+ sonar.objc.file.suffixes=-
+ jobs:
+ - gerrit-cmake-sonarqube
diff --git a/jjb/sim-o1-interface/sim-o1-interface.yaml b/jjb/sim-o1-interface/sim-o1-interface.yaml
index 16c15e7..42bc3bf 100644
--- a/jjb/sim-o1-interface/sim-o1-interface.yaml
+++ b/jjb/sim-o1-interface/sim-o1-interface.yaml
@@ -24,7 +24,7 @@
mvn-settings: sim-o1-interface-settings
# source of docker tag
container-tag-method: yaml-file
- docker-root: ntsimulator
+ # if no container-tag-yaml-dir is defined, container-tag.yml is taken from the docker-root
build-node: ubuntu1804-docker-4c-4g
jobs:
- '{project-name}-gerrit-docker-jobs'
@@ -34,67 +34,63 @@
- project:
<<: *sim_o1_interface_docker
- name: sim-o1-interface-ntsim-manager
+ name: sim-o1-interface-ntsim-ng-base
# jenkins job name prefix
project-name: '{name}'
# image name
- docker-name: 'o-ran-sc/ntsim-manager'
+ docker-name: 'o-ran-sc/nts-ng-base'
# dockerfile is in subdir
- docker-build-args: '--network=host -f deploy/nts-manager/Dockerfile'
- # tag file is in subdir
- container-tag-yaml-dir: ntsimulator/deploy/nts-manager
+ docker-build-args: '--network=host -f deploy/base/ubuntu.Dockerfile'
+ # tag file latest, since it is base for others
+ container-tag-method: latest
+ docker-root: ntsimulator
+ gerrit_trigger_file_paths:
+ - compare-type: REG_EXP
+ pattern: 'ntsimulator/ntsim-ng/.*'
+ - compare-type: REG_EXP
+ pattern: 'ntsimulator/deploy/base/.*'
+
+- project:
+ <<: *sim_o1_interface_docker
+ name: sim-o1-interface-ntsim-ng-manager
+ # jenkins job name prefix
+ project-name: '{name}'
+ # image name
+ docker-name: 'o-ran-sc/ntsim-ng-manager'
+ # dockerfile is in subdir
+ docker-build-args: '--network=host -f ubuntu.Dockerfile'
+ docker-root: ntsimulator/deploy/nts-manager
gerrit_trigger_file_paths:
- compare-type: REG_EXP
pattern: 'ntsimulator/deploy/nts-manager/.*'
- - compare-type: REG_EXP
- pattern: 'ntsimulator/src/ntsimulator-manager/.*'
- - compare-type: REG_EXP
- pattern: 'ntsimulator/yang/nts-manager/.*'
- project:
<<: *sim_o1_interface_docker
- name: sim-o1-interface-o-ran-ru-fh
+ name: sim-o1-interface-ntsim-ng-o-ran-fh
# jenkins job name prefix
project-name: '{name}'
# image name
- docker-name: 'o-ran-sc/ntsim-o-ran-ru-fh'
+ docker-name: ' o-ran-sc/nts-ng-o-ran-fh'
# dockerfile is in subdir
- docker-build-args: '--network=host -f deploy/o-ran/ru-fh/Dockerfile'
- # tag file is in subdir
- container-tag-yaml-dir: ntsimulator/deploy/o-ran/ru-fh
+ docker-build-args: '--network=host -f ubuntu.Dockerfile'
+ docker-root: ntsimulator/deploy/o-ran
gerrit_trigger_file_paths:
- compare-type: REG_EXP
- pattern: 'ntsimulator/.*'
+ pattern: 'ntsimulator/deploy/o-ran/.*'
- project:
<<: *sim_o1_interface_docker
- name: sim-o1-interface-o-ran-ru
+ name: sim-o1-interface-ntsim-ng-x-ran
# jenkins job name prefix
project-name: '{name}'
# image name
- docker-name: 'o-ran-sc/ntsim-o-ran-ru'
+ docker-name: 'o-ran-sc/nts-ng-x-ran'
# dockerfile is in subdir
- docker-build-args: '--network=host -f deploy/o-ran-sc/o-ran-ru/Dockerfile'
- # tag file is in subdir
- container-tag-yaml-dir: ntsimulator/deploy/o-ran-sc/o-ran-ru
+ docker-build-args: '--network=host -f ubuntu.Dockerfile'
+ docker-root: ntsimulator/deploy/x-ran
gerrit_trigger_file_paths:
- compare-type: REG_EXP
- pattern: 'ntsimulator/.*'
-
-- project:
- <<: *sim_o1_interface_docker
- name: sim-o1-interface-x-ran
- # jenkins job name prefix
- project-name: '{name}'
- # image name
- docker-name: 'o-ran-sc/ntsim-x-ran'
- # dockerfile is in subdir
- docker-build-args: '--network=host -f deploy/x-ran/Dockerfile'
- # tag file is in subdir
- container-tag-yaml-dir: ntsimulator/deploy/x-ran
- gerrit_trigger_file_paths:
- - compare-type: REG_EXP
- pattern: 'ntsimulator/.*'
+ pattern: 'ntsimulator/deploy/x-ran/.*'
- project:
<<: *sim_o1_interface_docker
diff --git a/jjb/smo-a1/smo-a1.yaml b/jjb/smo-a1/smo-a1.yaml
new file mode 100644
index 0000000..afb51f5
--- /dev/null
+++ b/jjb/smo-a1/smo-a1.yaml
@@ -0,0 +1,14 @@
+---
+- project:
+ name: smo-a1-project-view
+ project-name: smo-a1
+ views:
+ - project-view
+
+- project:
+ name: smo-a1-info
+ project: smo/a1
+ project-name: smo-a1
+ build-node: centos7-builder-1c-1g
+ jobs:
+ - gerrit-info-yaml-verify
diff --git a/jjb/smo-o1/smo-o1.yaml b/jjb/smo-o1/smo-o1.yaml
new file mode 100644
index 0000000..66031fe
--- /dev/null
+++ b/jjb/smo-o1/smo-o1.yaml
@@ -0,0 +1,14 @@
+---
+- project:
+ name: smo-o1-project-view
+ project-name: smo-o1
+ views:
+ - project-view
+
+- project:
+ name: smo-o1-info
+ project: smo/o1
+ project-name: smo-o1
+ build-node: centos7-builder-1c-1g
+ jobs:
+ - gerrit-info-yaml-verify
diff --git a/jjb/smo-ves/smo-ves.yaml b/jjb/smo-ves/smo-ves.yaml
new file mode 100644
index 0000000..d1dd651
--- /dev/null
+++ b/jjb/smo-ves/smo-ves.yaml
@@ -0,0 +1,14 @@
+---
+- project:
+ name: smo-ves-project-view
+ project-name: smo-ves
+ views:
+ - project-view
+
+- project:
+ name: smo-ves-info
+ project: smo/ves
+ project-name: smo-ves
+ build-node: centos7-builder-1c-1g
+ jobs:
+ - gerrit-info-yaml-verify