Merge "Migrate VID to SonarCloud"
authorJessica Wagantall <jwagantall@linuxfoundation.org>
Thu, 19 Dec 2019 19:12:53 +0000 (19:12 +0000)
committerGerrit Code Review <gerrit@onap.org>
Thu, 19 Dec 2019 19:12:53 +0000 (19:12 +0000)
33 files changed:
jjb/ccsdk/apps.yaml
jjb/ccsdk/cds.yaml
jjb/ccsdk/distribution.yaml
jjb/ccsdk/features.yaml
jjb/ccsdk/parent.yaml
jjb/ccsdk/sli-adaptors.yaml
jjb/ccsdk/sli-core.yaml
jjb/ccsdk/sli-northbound.yaml
jjb/ccsdk/sli-plugins.yaml
jjb/clamp/clamp.yaml
jjb/dcaegen2/dcaegen2-platform-adapter.yaml
jjb/dcaegen2/dcaegen2-platform-mod-distributorapi.yaml
jjb/dcaegen2/dcaegen2-platform-mod-onboardingapi.yaml
jjb/dcaegen2/dcaegen2-platform-oti-eventhandler.yaml [new file with mode: 0644]
jjb/dcaegen2/dcaegen2-platform-oti-eventproc.yaml [new file with mode: 0644]
jjb/demo/demo.yaml
jjb/externalapi/externalapi-nbi.yaml
jjb/msb/msb-apigateway.yaml
jjb/msb/msb-discovery.yaml
jjb/msb/msb-java-sdk.yaml
jjb/msb/msb-swagger-sdk.yaml
jjb/multicloud/multicloud-azure-java.yaml
jjb/multicloud/multicloud-framework-java.yaml
jjb/multicloud/multicloud-openstack-vmware-java.yaml
jjb/multicloud/multicloud-openstack.yaml
jjb/policy/policy-common.yaml
jjb/policy/policy-drools-applications.yaml
jjb/policy/policy-parent.yaml
jjb/vnfsdk/vnfsdk-functest.yaml
jjb/vnfsdk/vnfsdk-refrepo.yaml
jjb/vnfsdk/vnfsdk-validation.yaml
jjb/vnfsdk/vnfsdk-ves-agent.yaml
shell/docker-ts-tag-override.sh [new file with mode: 0755]

index ab202ed..c69c670 100644 (file)
@@ -12,7 +12,6 @@
       - gerrit-maven-verify
       - gerrit-maven-merge:
           cron: '@daily'
-          mvn-params: '-P dependency-list'
       - gerrit-maven-stage:
           build-node: centos7-builder-4c-4g
           sign-artifacts: true
index d2bde42..4104859 100644 (file)
@@ -6,7 +6,6 @@
       - gerrit-maven-verify
       - gerrit-maven-merge:
           cron: '@daily'
-          mvn-params: '-P dependency-list'
       - gerrit-maven-stage:
           build-node: centos7-builder-4c-4g
           sign-artifacts: true
index b61a9ea..aea76c6 100644 (file)
@@ -5,7 +5,6 @@
     jobs:
       - gerrit-maven-verify
       - gerrit-maven-merge:
-          mvn-params: '-P dependency-list'
           cron: '@daily'
       - gerrit-maven-stage:
           build-node: centos7-builder-4c-4g
index 0ce073e..90837d7 100644 (file)
@@ -5,7 +5,6 @@
     jobs:
       - gerrit-maven-verify
       - gerrit-maven-merge:
-          mvn-params: '-P dependency-list'
           cron: '@daily'
       - gerrit-maven-stage:
           build-node: centos7-builder-4c-4g
index 38ed199..cd04db7 100644 (file)
@@ -6,7 +6,6 @@
       - gerrit-maven-verify
       - gerrit-maven-merge:
           cron: '@daily'
-          mvn-params: '-P dependency-list'
       - gerrit-maven-stage:
           build-node: centos7-builder-4c-4g
           sign-artifacts: true
index daf2b42..3430516 100644 (file)
@@ -5,7 +5,6 @@
     jobs:
       - gerrit-maven-verify
       - gerrit-maven-merge:
-          mvn-params: '-P dependency-list'
           cron: '@daily'
       - gerrit-maven-stage:
           build-node: centos7-builder-4c-4g
index 12bc102..868151a 100644 (file)
@@ -5,7 +5,6 @@
     jobs:
       - gerrit-maven-verify
       - gerrit-maven-merge:
-          mvn-params: '-P dependency-list'
           cron: '@daily'
       - gerrit-maven-stage:
           build-node: centos7-builder-4c-4g
index 7f7c779..73ea823 100644 (file)
@@ -5,7 +5,6 @@
     jobs:
       - gerrit-maven-verify
       - gerrit-maven-merge:
-          mvn-params: '-P dependency-list'
           cron: '@daily'
       - gerrit-maven-stage:
           build-node: centos7-builder-4c-4g
index 245c64e..71ce51b 100644 (file)
@@ -5,7 +5,6 @@
     jobs:
       - gerrit-maven-verify
       - gerrit-maven-merge:
-          mvn-params: '-P dependency-list'
           cron: '@daily'
       - gerrit-maven-stage:
           build-node: centos7-builder-4c-4g
index c2f2d5f..b3dae54 100644 (file)
     jobs:
       - gerrit-maven-sonar:
           mvn-params: '-Ddocker.pull.registry=nexus3.onap.org:10001'
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-docker-8c-8g
     project: 'clamp'
index bb0a9f7..a203a75 100644 (file)
     name: dcaegen2-platform-aoadapter
     # root of docker build
     docker-root: adapter/acumos
+    # tag override
+    docker-get-container-tag-script: ../../shell/docker-ts-tag-override.sh
     # image name
-    docker-name: '{name}'
+    docker-name: 'onap/{name}'
     stream:
       - master:
             branch: master
     jobs:
       - gerrit-tox-sonar
     cron: '@daily'
+
+- project:
+    <<: *dcaegen2_platform_common
+    name: dcaegen2-platform-aoadapter-clm
+    docker-root: adapter/acumos
+    jobs:
+      - gerrit-maven-clm
+    nexus-iq-namespace: 'onap-'
+    project-name: 'dcaegen2-platform-aoadapter-clm'
+    mvn-params: '-f adapter/acumos/pom.xml'
+    branch: 'master'
+
index b8387d0..1210edb 100644 (file)
     jobs:
       - gerrit-tox-sonar
     cron: '@daily'
+
+- project:
+    <<: *dcaegen2_platform_common
+    name: dcaegen2-platform-mod-distributorapi-clm
+    docker-root: mod/distributorapi
+    jobs:
+      - gerrit-maven-clm
+    nexus-iq-namespace: 'onap-'
+    project-name: 'dcaegen2-platform-mod-distributorapi-clm'
+    mvn-params: '-f mod/distributorapi/pom.xml'
+    branch: 'master'
index ffe5640..ca63a42 100644 (file)
     jobs:
       - gerrit-tox-sonar
     cron: '@daily'
+
+- project:
+    <<: *dcaegen2_platform_common
+    name: dcaegen2-platform-mod-onboardingapi-clm
+    docker-root: mod/onboardingapi
+    jobs:
+      - gerrit-maven-clm
+    nexus-iq-namespace: 'onap-'
+    project-name: 'dcaegen2-platform-mod-onboardingapi-clm'
+    mvn-params: '-f mod/onboardingapi/pom.xml'
+    branch: 'master'
diff --git a/jjb/dcaegen2/dcaegen2-platform-oti-eventhandler.yaml b/jjb/dcaegen2/dcaegen2-platform-oti-eventhandler.yaml
new file mode 100644 (file)
index 0000000..fa64115
--- /dev/null
@@ -0,0 +1,45 @@
+---
+# dcagen2_platform_common is defined in dcaegen2-platform-adapter.yaml
+
+- project:
+    <<: *dcaegen2_platform_common
+    name: dcaegen2-platform-oti-event-handler
+    # root of docker build
+    docker-root: oti/event-handler
+    # image name
+    docker-name: '{name}'
+    stream:
+      - master:
+            branch: master
+    jobs:
+      - '{project-name}-gerrit-docker-jobs'
+
+- project:
+    <<: *dcaegen2_platform_common
+    name: dcagen2-platform-oti-event-handler-verify
+    docker-root: oti/event-handler
+    stream:
+      - all:
+            branch: '*'
+    jobs:
+      - gerrit-tox-verify
+
+- project:
+    <<: *dcaegen2_platform_common
+    name: dcaegen2-platform-oti-event-handler-sonar
+    docker-root: oti/event-handler
+    branch: master
+    jobs:
+      - gerrit-tox-sonar
+    cron: '@daily'
+
+- project:
+    <<: *dcaegen2_platform_common
+    name: dcaegen2-platform-oti-event-handler-clm
+    docker-root: oti/event-handler
+    jobs:
+      - gerrit-maven-clm
+    nexus-iq-namespace: 'onap-'
+    project-name: 'dcaegen2-platform-oti-event-handler-clm'
+    mvn-params: '-f oti/event-handler/pom.xml'
+    branch: 'master'
diff --git a/jjb/dcaegen2/dcaegen2-platform-oti-eventproc.yaml b/jjb/dcaegen2/dcaegen2-platform-oti-eventproc.yaml
new file mode 100644 (file)
index 0000000..d295171
--- /dev/null
@@ -0,0 +1,80 @@
+---
+- project:
+    name: dcaegen2-platform-oti-event-proc
+    project-name: dcaegen2-platform-oti
+    # git repo
+    project: dcaegen2/platform
+    jobs:
+      - '{project-name}-{stream}-{subproject}-verify-java'
+      - '{project-name}-{stream}-{subproject}-merge-java':
+          mvn-goals: 'clean install'
+    subproject:
+      - eventproc:
+          pom: 'oti/event-proc/pom.xml'
+          pattern: 'oti/event-proc/**'
+    stream:
+      - 'master':
+          branch: 'master'
+    mvn-settings: dcaegen2-platform-settings
+    files: '**'
+    archive-artifacts: ''
+    build-node: ubuntu1604-docker-8c-8g
+
+- project:
+    name: dcaegen2-platform-oti-event-proc-release
+    project: 'dcaegen2/platform'
+    project-name: 'dcaegen2-platform-oti-event-proc'
+    jobs:
+      - gerrit-maven-stage:
+          sign-artifacts: true
+          build-node: centos7-docker-8c-8g
+          maven-versions-plugin: true
+          version-properties-file: 'oti/event-proc/version.properties'
+          mvn-pom: 'oti/event-proc/pom.xml'
+          mvn-params: '-f oti/event-proc/pom.xml'
+          mvn-goals: 'clean deploy -Ddockerfile.skip -f oti/event-proc/pom.xml'
+          pattern: 'oti/event-proc/**'
+      - gerrit-maven-docker-stage:
+          build-node: ubuntu1604-docker-8c-8g
+          mvn-goals: 'clean package dockerfile:build dockerfile:push -f oti/event-proc/pom.xml'
+          container-public-registry: 'nexus3.onap.org:10001'
+          container-staging-registry: 'nexus3.onap.org:10003'
+          pattern: 'oti/event-proc/**'
+
+    stream:
+      - 'master':
+          branch: 'master'
+    mvn-settings: 'dcaegen2-platform-settings'
+    maven-deploy-properties: |
+      deployAtEnd=true
+    files: '**'
+    archive-artifacts: ''
+    build-node: 'ubuntu1604-docker-8c-8g'
+
+- project:
+    name: dcaegen2-platform-oti-event-proc-sonar
+    jobs:
+      - gerrit-maven-sonar
+    cron: '@daily'
+    build-node: ubuntu1604-builder-4c-4g
+    project: 'dcaegen2/platform'
+    project-name: 'dcaegen2-platform-oti-event-proc'
+    branch: 'master'
+    mvn-settings: 'dcaegen2-platform-settings'
+    mvn-params: '-f oti/event-proc/pom.xml'
+    mvn-goals: 'clean install'
+    mvn-opts: '-Xmx1024m -XX:MaxPermSize=256m'
+
+
+- project:
+    name: dcaegen2-platform-oti-event-proc-clm
+    jobs:
+      - gerrit-maven-clm
+    nexus-iq-namespace: 'onap-'
+    build-node: ubuntu1604-docker-8c-8g
+    project: 'dcaegen2/platform'
+    project-name: dcaegen2-platform-oti-event-proc-clm
+    mvn-params: '-f oti/event-proc/pom.xml'
+    branch: 'master'
+    mvn-settings: 'dcaegen2-platform-settings'
+
index 49eea28..fffa81d 100644 (file)
     name: demo-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'demo'
index 4c69d4c..47fcf39 100644 (file)
     name: externalapi-nbi-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'externalapi/nbi'
index ec98862..6a51fc5 100644 (file)
     name: msb-apigateway-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'msb/apigateway'
index 3e2fe17..149238e 100644 (file)
     name: msb-discovery-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'msb/discovery'
index 4367193..579f463 100644 (file)
     name: msb-java-sdk-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'msb/java-sdk'
index 8e5a1ce..09426a2 100644 (file)
     name: msb-swagger-sdk-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'msb/swagger-sdk'
index 7ac4fca..b8bf8a1 100644 (file)
     name: multicloud-azure-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'multicloud/azure'
index 388f94c..d5e24d2 100644 (file)
     name: multicloud-framework-multivimbroker-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'multicloud/framework'
     name: multicloud-framework-artifactbroker-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'multicloud/framework'
index c297872..205d374 100644 (file)
     name: multicloud-openstack-vmware-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'multicloud/openstack/vmware'
index da9605f..eefdc77 100644 (file)
     name: multicloud-openstack-windriver-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'multicloud/openstack'
     name: multicloud-openstack-pike-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'multicloud/openstack'
     name: multicloud-openstack-starlingx-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'multicloud/openstack'
     name: multicloud-openstack-fcaps-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'multicloud/openstack'
 #    name: multicloud-openstack-lenovo-sonar
 #    jobs:
 #      - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
 #    cron: '@daily'
 #    build-node: ubuntu1604-builder-4c-4g
 #    project: 'multicloud/openstack'
index 3ac5b25..ec7d783 100644 (file)
@@ -37,6 +37,7 @@
     project-name: 'policy-common'
     branch: 'master'
     mvn-settings: 'policy-common-settings'
+    java-version: openjdk11
     mvn-goals: 'clean install'
     mvn-opts: '-Xmx1024m -XX:MaxPermSize=256m'
 
@@ -49,6 +50,7 @@
     project-name: 'policy-common'
     branch: 'master'
     mvn-settings: 'policy-common-settings'
+    java-version: openjdk11
 
 - project:
     name: policy-common-info
index 8949ed8..905958d 100644 (file)
@@ -57,6 +57,7 @@
     project-name: 'policy-drools-applications'
     branch: 'master'
     mvn-settings: 'policy-drools-applications-settings'
+    build-node: ubuntu1604-docker-8c-8g
 
 - project:
     name: policy-drools-applications-info
index dca2452..86a5326 100644 (file)
@@ -31,6 +31,7 @@
     project-name: 'policy-parent'
     branch: 'master'
     mvn-settings: 'policy-parent-settings'
+    java-version: openjdk11
 
 - project:
     name: policy-parent-info
index 30a1de5..583b7b6 100644 (file)
     name: vnfsdk-functest-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'vnfsdk/functest'
index db4954b..53efe17 100644 (file)
     name: vnfsdk-refrepo-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'vnfsdk/refrepo'
index 1709243..b3a664f 100644 (file)
     name: vnfsdk-validation-sonar
     jobs:
       - gerrit-maven-sonar
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'vnfsdk/validation'
index 8bcbd0b..52751aa 100644 (file)
           make-opts: -j6
           stream: master
           build-node: centos7-builder-4c-4g
+    sonarcloud: true
+    sonarcloud-project-organization: '{sonarcloud_project_organization}'
+    sonarcloud-api-token: '{sonarcloud_api_token}'
+    sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}'
+    sonar-mvn-goal: "org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar"
     cron: '@daily'
     build-node: ubuntu1604-builder-4c-4g
     project: 'vnfsdk/ves-agent'
diff --git a/shell/docker-ts-tag-override.sh b/shell/docker-ts-tag-override.sh
new file mode 100755 (executable)
index 0000000..e14d2e5
--- /dev/null
@@ -0,0 +1,50 @@
+#!/bin/bash
+
+# ================================================================================
+# Copyright (c) 2019 AT&T Intellectual Property. All rights reserved.
+# ================================================================================
+# 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.
+# ============LICENSE_END=========================================================
+
+set -feu -o pipefail
+
+echo "--> docker-ts-tag-override.sh"
+
+# Get project version from pom.xml
+version=`xmllint --xpath "//*[local-name()='project']/*[local-name()='version']/text()" $DOCKER_ROOT/pom.xml`
+echo "INFO: version from pom file $version"
+
+# Some pom has -SNAPSHOT or -STAGING under pom version, remove all text
+version="${version//[^0-9.]/}"
+
+# Get build TS for specifying in the tag
+timestamp=$(date +%C%y%m%dT%H%M%SZ)
+
+# Following the https://wiki.onap.org/display/DW/Independent+Versioning+and+Release+Process
+# IndependentVersioningandReleaseProcess-StandardizedDockerTagging
+# ONAP Tag requirement :  {imagename}:{semver}-SNAPSHOT-{timestamp}Z (from CIMAN-132)
+
+if [[ $version =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
+  tag="${version}-SNAPSHOT-${timestamp}"
+else
+  # Default to latest tag with TS if not conforming to semantic versioning
+  echo "WARN: version not complaint to sem-ver; tag defaulted to latest"
+  version=latest
+  tag="${version}-${timestamp}"
+fi
+
+echo "INFO: docker tag is $tag"
+
+# Write DOCKER_IMAGE_TAG information to a file so it can be
+# injected into the environment for following steps
+echo "DOCKER_IMAGE_TAG=$tag" >> "$WORKSPACE/env_docker_inject.txt"