diff options
Diffstat (limited to 'jjb')
127 files changed, 4671 insertions, 9601 deletions
diff --git a/jjb/ci-management/ci-management-jobs.yaml b/jjb/ci-management/ci-management-jobs.yaml index e99855eb3..3380eda7b 100644 --- a/jjb/ci-management/ci-management-jobs.yaml +++ b/jjb/ci-management/ci-management-jobs.yaml @@ -6,14 +6,15 @@ - gerrit-jenkins-cfg-merge - gerrit-jenkins-sandbox-cleanup - gerrit-jjb-deploy-job - - gerrit-jjb-merge + - gerrit-jjb-merge: + build-node: centos8-builder-2c-2g - gerrit-jjb-verify project: ci-management project-name: ci-management - build-node: centos7-builder-4c-4g - build-timeout: 60 - jjb-version: 2.6.0 + build-node: centos8-builder-2c-2g + build-timeout: 15 + jjb-version: 6.0.0 - project: name: ci-management @@ -26,6 +27,6 @@ project-name: ci-management jobs: - gerrit-info-yaml-verify - build-node: centos7-builder-4c-4g + build-node: centos8-builder-2c-2g project: ci-management branch: master diff --git a/jjb/ci-management/ci-packer-jobs.yaml b/jjb/ci-management/ci-packer-jobs.yaml index 1672c9350..0496d98ea 100644 --- a/jjb/ci-management/ci-packer-jobs.yaml +++ b/jjb/ci-management/ci-packer-jobs.yaml @@ -7,16 +7,15 @@ project: ci-management project-name: ci-management - build-node: centos7-builder-2c-2g + build-node: centos8-builder-2c-2g openstack-cloud: vexci - packer-version: 1.4.0 + packer-version: 1.8.2 platforms: - centos-7 - - ubuntu-16.04 - - ubuntu-18.04 - - ubuntu-18.04-arm64 - - ubuntu-16.04-arm64 + - centos-8 + - ubuntu-20.04 + - ubuntu-20.04-arm64 templates: - builder diff --git a/jjb/ci-management/package-list.sh b/jjb/ci-management/package-list.sh index 6172b7b54..2b4325641 100644 --- a/jjb/ci-management/package-list.sh +++ b/jjb/ci-management/package-list.sh @@ -34,16 +34,6 @@ libparc-dev \ libmemif-dev \ longbow-dev" -export PACKAGE_LIST_CENTOS="libhicnctrl-devel \ -libhicnctrl-memif-devel \ -libhicntransport-memif-devel \ -libhicn-devel \ -libhicntransport-devel \ -hicn-plugin-devel \ -libparc-devel \ -libmemif-devel \ -longbow-devel" - export VERSION_WHITELIST="19.01-227 \ 19.08-289 \ 20.01-73 \ diff --git a/jjb/ci-management/packagecloud-repo-cleanup.sh b/jjb/ci-management/packagecloud-repo-cleanup.sh index 8fdfe1187..456b3a36d 100644 --- a/jjb/ci-management/packagecloud-repo-cleanup.sh +++ b/jjb/ci-management/packagecloud-repo-cleanup.sh @@ -1,11 +1,12 @@ #!/bin/bash -set -euo pipefail +echo "---> jjb/ci-management/packagecloud-repo-cleanup.sh" + +set -euxo pipefail # Number of packages to keep. N_PACKAGES=5 PACKAGECLOUD_REPO_DEB="https://packagecloud.io/install/repositories/fdio/${STREAM}/script.deb.sh" -PACKAGECLOUD_REPO_RPM="https://packagecloud.io/install/repositories/fdio/${STREAM}/script.rpm.sh" FACTER_OS=$(/usr/bin/facter operatingsystem) PACKAGE_LIST="" @@ -75,46 +76,6 @@ build_package_blacklist_ubuntu () { echo ${OUTPUT_LIST} } -# Params -# $1: Package list -build_package_blacklist_centos () { - PACKAGE_LIST=${@} - OUTPUT_LIST="" - VERSIONS="" - ARCH=$(uname -m) - - for package in ${PACKAGE_LIST}; do - OUTPUT=$(yum --showduplicates list ${package} 2> /dev/null) - if [[ ${?} -ne 0 || -z "${OUTPUT}" ]]; then - continue - fi - - VERSIONS="$(echo ${OUTPUT} | grep -Eo "${VERSION_REGEX}" | head -n -${N_PACKAGES})" - - for version in ${VERSIONS}; do - if ! check_version_whitelist ${version}; then - OUTPUT_LIST+="${package}-${version}.${ARCH}.rpm " - fi - done - done - - echo ${OUTPUT_LIST} -} - -promote_attic_repo_centos () { - FACTER_OSMAJREL=$(/usr/bin/facter operatingsystemmajrelease) - FACTER_ARCH=$(/usr/bin/facter architecture) - - for package in ${@}; do - echo package_cloud promote \ - ${PCIO_CO}/${STREAM}/el/${FACTER_OSMAJREL}/os/${FACTER_ARCH}/ \ - ${package} ${PCIO_CO}/attic/el/${FACTER_OSMAJREL}/os/${FACTER_ARCH}/ - package_cloud promote \ - ${PCIO_CO}/${STREAM}/el/${FACTER_OSMAJREL}/os/${FACTER_ARCH}/ \ - ${package} ${PCIO_CO}/attic/el/${FACTER_OSMAJREL}/os/${FACTER_ARCH}/ - done -} - promote_attic_repo_ubuntu () { FACTER_LSBNAME=$(/usr/bin/facter lsbdistcodename) @@ -138,12 +99,6 @@ setup_fdio_repo () { FUNCTIONS["promote_attic_repo"]="promote_attic_repo_ubuntu" PACKAGE_LIST="${PACKAGE_LIST_COMMON} ${PACKAGE_LIST_UBUNTU}" ;; - CentOS) - curl -s ${PACKAGECLOUD_REPO_RPM} | sudo bash - FUNCTIONS["package_blacklist"]="build_package_blacklist_centos" - FUNCTIONS["promote_attic_repo"]="promote_attic_repo_centos" - PACKAGE_LIST="${PACKAGE_LIST_COMMON} ${PACKAGE_LIST_CENTOS}" - ;; *) echo_err "Distribution ${FACTER_OS} is not supported." ;; @@ -158,4 +113,4 @@ build_package_blacklist () { setup_fdio_repo PACKAGES_TO_PROMOTE=$(build_package_blacklist ${PACKAGE_LIST}) -promote_to_attic_repo ${PACKAGES_TO_PROMOTE}
\ No newline at end of file +promote_to_attic_repo ${PACKAGES_TO_PROMOTE} diff --git a/jjb/ci-management/packagecloud-repo-cleanup.yaml b/jjb/ci-management/packagecloud-repo-cleanup.yaml index c64e24a08..1c107c2fa 100644 --- a/jjb/ci-management/packagecloud-repo-cleanup.yaml +++ b/jjb/ci-management/packagecloud-repo-cleanup.yaml @@ -1,18 +1,24 @@ - project: - name: packagecloud-repo-cleanup + name: packagecloud-repo-cleanup-x86_64 jobs: - - 'packagecloud-repo-cleanup-release-{os}' - - 'packagecloud-repo-cleanup-hicn-{os}' + - 'packagecloud-repo-cleanup-release-{os}-{executor-arch}' + - 'packagecloud-repo-cleanup-hicn-{os}-{executor-arch}' project: 'ci-management' os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - ubuntu1804arm: - repo-os-part: 'ubuntu-arm.bionic.main' - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - - centos7: - repo-os-part: 'centos7' + - ubuntu2004 + + executor-arch: "x86_64" + +- project: + name: packagecloud-repo-cleanup-aarch64 + jobs: + - 'packagecloud-repo-cleanup-release-{os}-{executor-arch}' + - 'packagecloud-repo-cleanup-hicn-{os}-{executor-arch}' + project: 'ci-management' + os: + - ubuntu2004 + + executor-arch: "aarch64" - project: name: packagecloud-view @@ -21,17 +27,15 @@ project-name: packagecloud - job-template: - name: 'packagecloud-repo-cleanup-release-{os}' + name: 'packagecloud-repo-cleanup-release-{os}-{executor-arch}' project-type: freestyle - node: '{os}-us' + node: 'builder-{os}-prod-{executor-arch}' concurrent: true - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: @@ -42,10 +46,6 @@ os: '{os}' - stream-parameter: stream: 'release' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. wrappers: - fdio-infra-wrappers: @@ -75,25 +75,25 @@ target: '/root/packagecloud_api' - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - package-list.sh - packagecloud-repo-cleanup.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish - job-template: - name: 'packagecloud-repo-cleanup-hicn-{os}' + name: 'packagecloud-repo-cleanup-hicn-{os}-{executor-arch}' project-type: freestyle - node: '{os}-us' + node: 'builder-{os}-prod-{executor-arch}' concurrent: true - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: @@ -104,10 +104,6 @@ os: '{os}' - stream-parameter: stream: 'hicn' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. wrappers: - fdio-infra-wrappers: @@ -138,9 +134,11 @@ target: '/root/packagecloud_api' - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - package-list.sh - packagecloud-repo-cleanup.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish diff --git a/jjb/cicn/cicn.yaml b/jjb/cicn/cicn.yaml deleted file mode 100644 index c19a06aaa..000000000 --- a/jjb/cicn/cicn.yaml +++ /dev/null @@ -1,632 +0,0 @@ ---- - -- project: - name: cicn-libparc - jobs: - - 'cicn-libparc-verify-{stream}-{os}' - - 'cicn-libparc-merge-{stream}-{os}' - - 'cicn-libparc-docs-verify-{stream}' - - 'cicn-libparc-docs-merge-{stream}' - - project: 'cicn' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - - centos7: - repo-os-part: 'centos7' - - stream: - - master: - branch: 'cframework/master' - repo-stream-part: 'master' - - type: - - short - - long - -- project: - name: cicn-libparc-arm64 - jobs: - - 'cicn-arm64-libparc-verify-{stream}-{os}' - - 'cicn-arm64-libparc-merge-{stream}-{os}' - - project: 'cicn' - stream: - - master: - branch: 'cframework/master' - repo-stream-part: 'master' - os: - - ubuntu1804: - repo-os-part: 'ubuntu-arm.bionic.main' - - type: - - short - - long - -- project: - name: cicn-viper - jobs: - - 'cicn-viper-verify-{stream}-{os}' - - 'cicn-viper-merge-{stream}-{os}' - - project: 'cicn' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - stream: - - master: - branch: 'viper/master' - repo-stream-part: 'master' - - type: - - short - - long - -- job-template: - name: 'cicn-libparc-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-m' - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - stream-parameter: - stream: 'hicn' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - reverse: - jobs: 'cicn-longbow-merge-{stream}-ubuntu1604' - result: 'success' - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - reverse: - jobs: 'cicn-longbow-merge-{stream}-{os}' - result: 'failure' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root/.packagecloud' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root/packagecloud_api' - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'cicn-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - shell: - !include-raw-escape: - - include-raw-cicn-libparc-build.sh - - provide-maven-settings: - settings-file: 'cicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-cicn-maven-push.sh - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'cicn-libparc-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-m' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: - - include-raw-cicn-libparc-build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'cicn-libparc-docs-merge-{stream}' - - project-type: freestyle - node: 'ubuntu1604-builder-8c-32g' - concurrent: true - archive-artifacts: 'libparc/build/documentation/*.tar' - allow-empty: 'true' - fingerprint: false - only-if-success: true - default-excludes: false - - build-discarder: - 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}' - - maven-exec: - maven-version: 'mvn33-new' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - reverse: - jobs: 'cicn-libparc-merge-{stream}-ubuntu1604' - result: 'success' - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'run-docs' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'cicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - include-raw-cicn-libparc-docs.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'cicn-libparc-docs-verify-{stream}' - - project-type: freestyle - node: 'ubuntu1604-builder-8c-32g' - concurrent: true - archive-artifacts: 'libparc/build/documentation/*.tar' - allow-empty: 'true' - fingerprint: false - only-if-success: true - default-excludes: false - - build-discarder: - 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}' - - maven-exec: - maven-version: 'mvn33-new' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'cicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - include-raw-cicn-libparc-docs.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'cicn-arm64-libparc-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}arm-us' - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - stream-parameter: - stream: 'hicn' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root/.packagecloud' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root/packagecloud_api' - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'cicn-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - shell: - !include-raw-escape: - - include-raw-cicn-libparc-build.sh - - provide-maven-settings: - settings-file: 'cicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-cicn-maven-push.sh - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'cicn-arm64-libparc-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}arm-us' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: - - include-raw-cicn-libparc-build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'cicn-viper-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-m' - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - stream-parameter: - stream: 'hicn' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - reverse: - jobs: 'cicn-libicnet-merge-{stream}-{os}' - result: 'failure' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root/.packagecloud' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root/packagecloud_api' - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'cicn-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - shell: - !include-raw-escape: - - include-raw-cicn-viper-build.sh - - provide-maven-settings: - settings-file: 'cicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-cicn-maven-push.sh - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'cicn-viper-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-m' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: - - include-raw-cicn-viper-build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- project: - name: cicn-info - project-name: cicn - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-2c-2g - project: cicn - branch: master - -- project: - name: cicn-sonar - project: cicn - project-name: cicn - mvn-settings: cicn-settings - sonarcloud: true - sonarcloud-project-organization: '{sonarcloud_project_organization}' - sonarcloud-api-token: '{sonarcloud_api_token}' - sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}' - branch: master - build-node: centos7-builder-2c-2g - jobs: - - gerrit-maven-sonar diff --git a/jjb/cicn/include-raw-cicn-libparc-docs.sh b/jjb/cicn/include-raw-cicn-libparc-docs.sh deleted file mode 100644 index cb4d698e1..000000000 --- a/jjb/cicn/include-raw-cicn-libparc-docs.sh +++ /dev/null @@ -1,74 +0,0 @@ -#!/bin/bash -set -xe -o pipefail - -update_cmake_repo() { - cat /etc/resolv.conf - echo "nameserver 8.8.8.8" | sudo tee -a /etc/resolv.conf - cat /etc/resolv.conf - - CMAKE_INSTALL_SCRIPT_URL="https://cmake.org/files/v3.8/cmake-3.8.0-Linux-x86_64.sh" - CMAKE_INSTALL_SCRIPT="/tmp/install_cmake.sh" - curl ${CMAKE_INSTALL_SCRIPT_URL} > ${CMAKE_INSTALL_SCRIPT} - - sudo mkdir -p /opt/cmake - sudo bash ${CMAKE_INSTALL_SCRIPT} --skip-license --prefix=/opt/cmake - export PATH=/opt/cmake/bin:$PATH -} - -cd libparc - -[ "$DOCS_REPO_URL" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site" -[ "$PROJECT_PATH" ] || PROJECT_PATH="io/fd/cicn/libparc" -[ "$DOC_FILE" ] || DOC_FILE="cicn.libparc.docs.zip" -[ "$DOC_DIR" ] || DOC_DIR="build/documentation/generated-documentation/html" -[ "$SITE_DIR" ] || SITE_DIR="build/documentation/deploy-site/" -[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" -[ "$VERSION" ] || VERSION=$(bash scripts/version rpm-version) - -echo "Current directory: $(pwd)" - -update_cmake_repo -mkdir -p build -pushd build -cmake -DDOC_ONLY=ON .. -make documentation -popd - -if [[ ${JOB_NAME} == *merge* ]]; then - mkdir -p $(dirname ${RESOURCES_DIR}) - mv -f ${DOC_DIR} ${RESOURCES_DIR} - cd ${SITE_DIR} - find . -type f '(' -name '*.md5' -o -name '*.dot' -o -name '*.map' ')' -delete - cat > pom.xml << EOF - <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>io.fd.vpp</groupId> - <artifactId>docs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> - - <properties> - <generateReports>false</generateReports> - </properties> - - <build> - <extensions> - <extension> - <groupId>org.apache.maven.wagon</groupId> - <artifactId>wagon-webdav-jackrabbit</artifactId> - <version>3.3.3</version> - </extension> - </extensions> - </build> - <distributionManagement> - <site> - <id>fdio-site</id> - <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/${VERSION}</url> - </site> - </distributionManagement> - </project> -EOF - ${MVN} site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C - cd - -fi diff --git a/jjb/cicn/include-raw-cicn-maven-push.sh b/jjb/cicn/include-raw-cicn-maven-push.sh deleted file mode 100644 index 6ce3b2c06..000000000 --- a/jjb/cicn/include-raw-cicn-maven-push.sh +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/bash -set -xe -o pipefail -echo "*******************************************************************" -echo "* STARTING PUSH OF PACKAGES TO REPOS" -echo "* NOTHING THAT HAPPENS BELOW THIS POINT IS RELATED TO BUILD FAILURE" -echo "*******************************************************************" - -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" -GROUP_ID="io.fd.${PROJECT}" -BASEURL="${NEXUSPROXY}/content/repositories/fd.io." -BASEREPOID='fdio-' - -if [ "${OS}" == "ubuntu1604" ]; then - # Find the files - JARS=$(find . -type f -iname '*.jar') - DEBS=$(find . -type f -iname '*.deb') - for i in $JARS - do - push_jar "$i" - done - - for i in $DEBS - do - push_deb "$i" - done -elif [ "${OS}" == "ubuntu1804" ]; then - # Find the files - JARS=$(find . -type f -iname '*.jar') - DEBS=$(find . -type f -iname '*.deb') - for i in $JARS - do - push_jar "$i" - done - - for i in $DEBS - do - push_deb "$i" - done -elif [ "${OS}" == "centos7" ]; then - # Find the files - RPMS=$(find . -type f -iname '*.rpm') - SRPMS=$(find . -type f -iname '*.srpm') - SRCRPMS=$(find . -type f -name '*.src.rpm') - for i in $RPMS $SRPMS $SRCRPMS - do - push_rpm "$i" - done -elif [ "${OS}" == "opensuse" ]; then - # Find the files - RPMS=$(find . -type f -iname '*.rpm') - for i in $RPMS - do - push_rpm "$i" - done -fi -# vim: ts=4 sw=4 sts=4 et ft=sh : diff --git a/jjb/csit/csit-perf.yaml b/jjb/csit/csit-perf.yaml index 1b43e3ea1..20630caea 100644 --- a/jjb/csit/csit-perf.yaml +++ b/jjb/csit/csit-perf.yaml @@ -1,5 +1,5 @@ -# Copyright (c) 2020 Cisco and/or its affiliates. -# Copyright (c) 2019 PANTHEON.tech s.r.o. and/or its affiliates. +# Copyright (c) 2024 Cisco and/or its affiliates. +# Copyright (c) 2024 PANTHEON.tech s.r.o. and/or its affiliates. # 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: @@ -20,148 +20,536 @@ jobs: - 'csit-dpdk-perf-verify-{stream}-{node-arch}': node-arch: - - 2n-clx - - 2n-skx - - 2n-dnv - - 3n-skx - - 3n-hsw - - 3n-dnv + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 3n-tsh: - executor: 'ubuntu1804arm-us' - - 'csit-dpdk-perf-mrr-weekly-master{node-arch}': + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 'csit-dpdk-perf-mrr-weekly-master-{node-arch}': node-arch: - - '' - - -2n-clx - - -2n-skx - - -3n-skx + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-tsh: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' periodicity: '0 0 * * 6' + - 'csit-trex-perf-verify-{stream}-{node-arch}': + node-arch: + - 1n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 'csit-vpp-perf-verify-{stream}-{node-arch}': node-arch: - - 2n-clx - - 2n-skx - - 2n-dnv - - 3n-skx - - 3n-hsw - - 3n-dnv + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 3n-tsh: - executor: 'ubuntu1804arm-us' + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' stream: - master: branch: 'master' branch-id: 'oper' - - '1908_1': - branch: 'rls1908_1' - branch-id: 'oper-rls1908_1' - - '1908_2': - branch: 'rls1908_2' - branch-id: 'oper-rls1908_2' - - '2001': - branch: 'rls2001' - branch-id: 'oper-rls2001' - - '2005': - branch: 'rls2005' - branch-id: 'oper-rls2005' - - 'csit-vpp-perf-mrr-daily-master{node-arch}': + - '2402': + branch: 'rls2402' + branch-id: 'oper-rls2402' + - 'csit-vpp-perf-mrr-daily-master-{node-arch}': node-arch: - - '': - periodicity: '0 2,14 * * *' - - -2n-clx: - periodicity: '0 2,14 * * *' - - -2n-skx: - periodicity: '0 2,14 * * *' - - -2n-dnv: - periodicity: '0 2,14 * * *' - - -3n-skx: - periodicity: '0 2,14 * * *' - - -3n-dnv: - periodicity: '0 2,14 * * *' - - -3n-tsh: - executor: 'ubuntu1804arm-us' - periodicity: '0 14 * * *' - - 'csit-vpp-perf-mrr-weekly-{stream}-{node-arch}': + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + periodicity: '30 22 * * 0-4' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 3n-tsh: + os: 'ubuntu2204' + executor-arch: 'aarch64' + periodicity: '30 22 * * 0-4' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + periodicity: '30 22 * * 0-4' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 'csit-vpp-perf-hoststack-daily-master-{node-arch}': node-arch: - - 2n-clx - - 2n-skx - - 3n-skx - stream: - - master: - branch: 'master' - branch-id: 'oper' - - '1908_2': - branch: 'rls1908_2' - branch-id: 'oper-rls1908_2' + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '30 22 * * 0-4' + - 'csit-vpp-perf-mrr-weekly-master-{node-arch}': + node-arch: + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '0 0 * * 6' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '0 0 * * 6' + - 2n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '0 0 * * 1' + - 2n-c6in: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '0 0 * * 1' + - 2n-c7gn: + os: 'ubuntu2204' + executor-arch: 'aarch64' + periodicity: '0 0 * * 1' + - 'csit-vpp-perf-soak-weekly-master-{node-arch}': + node-arch: + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' periodicity: '0 0 * * 6' + - 'csit-trex-perf-ndrpdr-weekly-master-{node-arch}': + node-arch: + - 1n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '0 0 * * 6' + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '0 0 * * 6' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + periodicity: '0 0 * * 6' - 'csit-vpp-perf-ndrpdr-weekly-master-{node-arch}': node-arch: - - 2n-clx - - 2n-skx - - 3n-skx - - 3n-hsw + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-tsh: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' periodicity: '0 0 * * 6' - 'csit-vpp-perf-report-iterative-{stream_report}-{node-arch}': node-arch: - - 2n-clx - - 2n-skx - - 2n-dnv - - 3n-skx - - 3n-hsw - - 3n-dnv + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 3n-tsh: - executor: 'ubuntu1804arm-us' + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 2n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-c6in: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-c7gn: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 'csit-dpdk-perf-report-iterative-{stream_report}-{node-arch}': node-arch: - - 2n-clx - - 2n-skx - - 2n-dnv - - 3n-skx - - 3n-hsw - - 3n-dnv + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 3n-tsh: - executor: 'ubuntu1804arm-us' + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 2n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 'csit-trex-perf-report-iterative-{stream_report}-{node-arch}': + node-arch: + - 1n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 'csit-vpp-perf-report-coverage-{stream_report}-{node-arch}': node-arch: - - 2n-clx - - 2n-skx - - 2n-dnv - - 3n-skx - - 3n-hsw - - 3n-dnv + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 3n-tsh: - executor: 'ubuntu1804arm-us' + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 2n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-c6in: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-c7gn: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 'csit-dpdk-perf-report-coverage-{stream_report}-{node-arch}': node-arch: - - 2n-clx - - 2n-skx - - 2n-dnv - - 3n-skx - - 3n-hsw - - 3n-dnv + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' - 3n-tsh: - executor: 'ubuntu1804arm-us' + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 2n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-c6in: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-c7gn: + os: 'ubuntu2204' + executor-arch: 'aarch64' + - 3n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 'csit-trex-perf-report-coverage-{stream_report}-{node-arch}': + node-arch: + - 1n-aws: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' project: 'csit' - executor: 'ubuntu1804-us' branch: 'master' branch-id: 'oper' - csit-perf-trial-duration: "1.0" - csit-perf-trial-multiplicity: "10" + csit-perf-trial-duration: '1.0' + csit-perf-trial-multiplicity: '10' stream: - master: branch: 'master' branch-id: 'oper' - - '1908_2': - branch: 'rls1908_2' - branch-id: 'oper-rls1908_2' - - '2001': - branch: 'rls2001' - branch-id: 'oper-rls2001' - - '2005': - branch: 'rls2005' - branch-id: 'oper-rls2005' + - '2402': + branch: 'rls2402' + branch-id: 'oper-rls2402' stream_report: - - '2005': - branch: 'rls2005' - branch-id: 'oper-rls2005' + - '2402': + branch: 'rls2402' + branch-id: 'oper-rls2402' + build-artifact-num-to-keep: 10 @@ -180,10 +568,6 @@ <li>trigger: keyword in comment to csit patch: <b>csit-{node-arch}-perftest tag_list</b> </ul> - <li>executor - <ul> - <li>{executor} - </ul> <li>perf test-cases selection <ul> <li>test-cases selected using trigger keyword followed by tags @@ -212,33 +596,27 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: 'archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' - - gerrit-refspec-parameter + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' - gerrit-event-type-parameter - gerrit-event-comment-text-parameter - csit-perf-trial-duration-parameter: csit-perf-trial-duration: "{csit-perf-trial-duration}" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. # This is a manually-triggered verify job, part of API coverage. # CRC checking is needed to ensure vpp crc job breaks only when intended. # Can be removed when this job is no longer needed for full API coverage. @@ -265,19 +643,16 @@ builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-verify.sh publishers: - - robot: - output-path: archive - other-files: - - '*.*' - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: - name: 'csit-vpp-perf-mrr-daily-master{node-arch}' + name: 'csit-vpp-perf-mrr-daily-master-{node-arch}' description: | <ul> @@ -285,10 +660,6 @@ <ul> <li>check vpp perf mrr daily </ul> - <li>executor - <ul> - <li>{executor} - </ul> <li>perf test-cases selection <ul> <li>all CSIT VPP MRR perf suites @@ -302,16 +673,13 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: false - archive-artifacts: 'csit/archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: @@ -322,10 +690,6 @@ csit-perf-trial-duration: "{csit-perf-trial-duration}" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. wrappers: - fdio-infra-wrappers-non-activity-timeout: @@ -340,29 +704,83 @@ properties-file: variables.prop - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-timed.sh publishers: - - robot: - output-path: 'csit/archive' - other-files: - - '*.*' - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: - name: 'csit-vpp-perf-mrr-weekly-{stream}-{node-arch}' + name: 'csit-vpp-perf-hoststack-daily-master-{node-arch}' description: | <ul> <li>objective <ul> - <li>check vpp perf mrr weekly on {node-arch} + <li>check vpp perf hoststack daily </ul> - <li>executor + <li>perf test-cases selection <ul> - <li>{executor} + <li>all CSIT VPP HOSTSTACK perf suites + </ul> + <li>results + <ul> + <li>jjb verify: PASS/FAIL + <li>present: no + <li>analyse: csit project (catch malfunctions/degradations) + </ul> + </ul> + + project-type: freestyle + node: 'm-builder-{os}-prod-{executor-arch}' + concurrent: false + latest-only: false + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + - csit-perf-trial-duration-parameter: + csit-perf-trial-duration: "{csit-perf-trial-duration}" + - csit-perf-trial-multiplicity-parameter: + csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" + + wrappers: + - fdio-infra-wrappers-non-activity-timeout: + build-timeout: '{build-timeout}' + + triggers: + - timed: '{periodicity}' + + builders: + - shell: 'echo "BRANCH_ID={branch-id}" > $WORKSPACE/variables.prop' + - inject: + properties-file: variables.prop + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/perf-timed.sh + + publishers: + - fdio-infra-publish + +- job-template: + name: 'csit-vpp-perf-mrr-weekly-master-{node-arch}' + + description: | + <ul> + <li>objective + <ul> + <li>check vpp perf mrr weekly on {node-arch} </ul> <li>perf test-cases selection <ul> @@ -377,16 +795,13 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: false - archive-artifacts: 'csit/archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: @@ -397,10 +812,6 @@ csit-perf-trial-duration: "{csit-perf-trial-duration}" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. wrappers: - fdio-infra-wrappers-non-activity-timeout: @@ -415,16 +826,13 @@ properties-file: variables.prop - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-timed.sh publishers: - - robot: - output-path: 'csit/archive' - other-files: - - '*.*' - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: name: 'csit-vpp-perf-ndrpdr-weekly-master-{node-arch}' @@ -435,13 +843,126 @@ <ul> <li>check vpp perf ndrpdr weekly on {node-arch} </ul> - <li>executor + <li>perf test-cases selection + <ul> + <li>pre-selected CSIT VPP NDRPDR perf suites + </ul> + <li>results + <ul> + <li>jjb verify: PASS/FAIL + <li>present: no + <li>analyse: csit project (catch malfunctions/degradations) + </ul> + </ul> + project-type: freestyle + node: 'm-builder-{os}-prod-{executor-arch}' + concurrent: false + latest-only: false + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + + wrappers: + - fdio-infra-wrappers-non-activity-timeout: + build-timeout: '{build-timeout}' + + triggers: + - timed: '{periodicity}' + + builders: + - shell: 'echo "BRANCH_ID={branch-id}" > $WORKSPACE/variables.prop' + - inject: + properties-file: variables.prop + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/perf-timed.sh + + publishers: + - fdio-infra-publish + +- job-template: + name: 'csit-vpp-perf-soak-weekly-master-{node-arch}' + + description: | + <ul> + <li>objective + <ul> + <li>check vpp perf soak weekly on {node-arch} + </ul> + <li>perf test-cases selection + <ul> + <li>NF Density CSIT VPP SOAK perf suites + </ul> + <li>results <ul> - <li>{executor} + <li>jjb verify: PASS/FAIL + <li>present: no + <li>analyse: csit project (catch malfunctions/degradations) + </ul> + </ul> + + project-type: freestyle + node: 'm-builder-{os}-prod-{executor-arch}' + concurrent: false + latest-only: false + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + - csit-perf-trial-duration-parameter: + csit-perf-trial-duration: "{csit-perf-trial-duration}" + - csit-perf-trial-multiplicity-parameter: + csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" + + wrappers: + - fdio-infra-wrappers-non-activity-timeout: + build-timeout: '{build-timeout}' + + triggers: + - timed: '{periodicity}' + + builders: + - shell: 'echo "BRANCH_ID={branch-id}" > $WORKSPACE/variables.prop' + - inject: + properties-file: variables.prop + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/perf-timed.sh + + publishers: + - fdio-infra-publish + +- job-template: + name: 'csit-trex-perf-ndrpdr-weekly-master-{node-arch}' + + description: | + <ul> + <li>objective + <ul> + <li>check trex perf ndrpdr weekly on {node-arch} </ul> <li>perf test-cases selection <ul> - <li>pre-selected CSIT VPP NDRPDR perf suites + <li>pre-selected CSIT TREX NDRPDR perf suites </ul> <li>results <ul> @@ -451,26 +972,19 @@ </ul> </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: false - archive-artifacts: 'csit/archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. wrappers: - fdio-infra-wrappers-non-activity-timeout: @@ -485,16 +999,99 @@ properties-file: variables.prop - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-timed.sh publishers: - - robot: - output-path: 'csit/archive' - other-files: - - '*.*' + - fdio-infra-publish + +- job-template: + name: 'csit-trex-perf-verify-{stream}-{node-arch}' + + description: | + <ul> + <li>objective + <ul> + <li>perf verify - per csit gerrit patch + </ul> + <li>job + <ul> + <li>name: <b>csit-trex-perf-verify-{stream}-{node-arch}</b> + <li>trigger: keyword in comment to csit patch: + <b>csit-trex-{node-arch}-perftest tag_list</b> + </ul> + <li>perf test-cases selection + <ul> + <li>test-cases selected using trigger keyword followed by tags + <li>all test-cases are labelled with CSIT RF topic tags + defined in <i>csit/docs/tag_documentation.rst</i> + </ul> + <li>proposed keywords + <ul> + <li>focus on testing specified trex packet processing path + <li>format: csit-{node-arch}-perftest tag_list + </ul> + <li>results + <ul> + <li>jjb verify: PASS/FAIL + <li>present: no + <li>analyse: no + </ul> + </ul> + + project-type: freestyle + node: 'm-builder-{os}-prod-{executor-arch}' + concurrent: true + latest-only: false + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' + - gerrit-event-type-parameter + - gerrit-event-comment-text-parameter + - csit-perf-trial-duration-parameter: + csit-perf-trial-duration: "{csit-perf-trial-duration}" + - csit-perf-trial-multiplicity-parameter: + csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" + # This job does not interact with VPP so not setting fail-on-crc-mismatch. + + scm: + - gerrit-trigger-scm: + credentials-id: 'jenkins-gerrit-credentials' + refspec: '$GERRIT_REFSPEC' + choosing-strategy: 'gerrit' + + wrappers: + - fdio-infra-wrappers-non-activity-timeout: + build-timeout: '{build-timeout}' - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + triggers: + - gerrit-trigger-csit-perftest: + project: '{project}' + branch: '{branch}' + trigger-word: 'csit-trex-{node-arch}-perftest' + skip-vote: false + + builders: + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/perf-verify.sh + + publishers: + - fdio-infra-publish - job-template: name: 'csit-dpdk-perf-verify-{stream}-{node-arch}' @@ -511,10 +1108,6 @@ <li>trigger: keyword in comment to csit patch: <b>csit-dpdk-{node-arch}-perftest tag_list</b> </ul> - <li>executor - <ul> - <li>{executor} - </ul> <li>perf test-cases selection <ul> <li>test-cases selected using trigger keyword followed by tags @@ -538,30 +1131,27 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: 'archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' + - gerrit-event-type-parameter + - gerrit-event-comment-text-parameter - csit-perf-trial-duration-parameter: csit-perf-trial-duration: "{csit-perf-trial-duration}" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. scm: - gerrit-trigger-scm: @@ -583,19 +1173,16 @@ builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-verify.sh publishers: - - robot: - output-path: archive - other-files: - - '*.*' - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: - name: 'csit-dpdk-perf-mrr-weekly-master{node-arch}' + name: 'csit-dpdk-perf-mrr-weekly-master-{node-arch}' description: | <ul> @@ -603,10 +1190,6 @@ <ul> <li>check dpdk perf mrr weekly </ul> - <li>executor - <ul> - <li>{executor} - </ul> <li>perf test-cases selection <ul> <li>all CSIT DPDK MRR perf suites @@ -620,16 +1203,13 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: false - archive-artifacts: 'csit/archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: @@ -640,10 +1220,6 @@ csit-perf-trial-duration: "{csit-perf-trial-duration}" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. wrappers: - fdio-infra-wrappers-non-activity-timeout: @@ -658,16 +1234,13 @@ properties-file: variables.prop - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-timed.sh publishers: - - robot: - output-path: 'csit/archive' - other-files: - - '*.*' - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: name: 'csit-vpp-perf-report-iterative-{stream_report}-{node-arch}' @@ -689,10 +1262,6 @@ <li>trigger example: csit-vpp-report-iter-{node-arch}-perftest vpp-00 </ul> - <li>executor - <ul> - <li>{executor} - </ul> <li>perf test-cases selection <ul> <li>test-cases selected by tags defined in @@ -709,30 +1278,27 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: 'archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' + - gerrit-event-type-parameter + - gerrit-event-comment-text-parameter - csit-perf-trial-duration-parameter: csit-perf-trial-duration: "{csit-perf-trial-duration}" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. scm: - gerrit-trigger-scm: @@ -754,16 +1320,13 @@ builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-verify.sh publishers: - - robot: - output-path: archive - other-files: - - '*.*' - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: name: 'csit-dpdk-perf-report-iterative-{stream_report}-{node-arch}' @@ -785,10 +1348,6 @@ <li>trigger example: csit-dpdk-report-iter-{node-arch}-perftest dpdk-00 </ul> - <li>executor - <ul> - <li>{executor} - </ul> <li>perf test-cases selection <ul> <li>test-cases selected by tags defined in @@ -805,30 +1364,27 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: 'archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' + - gerrit-event-type-parameter + - gerrit-event-comment-text-parameter - csit-perf-trial-duration-parameter: csit-perf-trial-duration: "{csit-perf-trial-duration}" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. scm: - gerrit-trigger-scm: @@ -850,16 +1406,99 @@ builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-verify.sh publishers: - - robot: - output-path: archive - other-files: - - '*.*' + - fdio-infra-publish + +- job-template: + name: 'csit-trex-perf-report-iterative-{stream_report}-{node-arch}' + + description: | + <ul> + <li>objective + <ul> + <li>get trex performance iterative data for csit report + </ul> + <li>job + <ul> + <li>name: + <b>csit-trex-perf-report-iterative-{stream_report}- + {node-arch}</b> + <li>trigger: keyword in comment to csit patch: + <b>csit-trex-report-iter-{node-arch}-perftest + test_set_id</b> + <li>trigger example: + csit-trex-report-iter-{node-arch}-perftest trex-00 + </ul> + <li>perf test-cases selection + <ul> + <li>test-cases selected by tags defined in + <i>csit/docs/job_specs/report_iterative/{node-arch}/ + test_set_id.md</i> + </ul> + + <li>results + <ul> + <li>jjb verify: PASS/FAIL + <li>present: trex performance + <li>analyse: trex performance + </ul> + </ul> + + project-type: freestyle + node: 'm-builder-{os}-prod-{executor-arch}' + concurrent: true + latest-only: false + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' + - gerrit-event-type-parameter + - gerrit-event-comment-text-parameter + - csit-perf-trial-duration-parameter: + csit-perf-trial-duration: "{csit-perf-trial-duration}" + - csit-perf-trial-multiplicity-parameter: + csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + scm: + - gerrit-trigger-scm: + credentials-id: 'jenkins-gerrit-credentials' + refspec: '$GERRIT_REFSPEC' + choosing-strategy: 'gerrit' + + wrappers: + - fdio-infra-wrappers-non-activity-timeout: + build-timeout: '{build-timeout}' + + triggers: + - gerrit-trigger-csit-perftest: + project: '{project}' + branch: '{branch}' + trigger-word: 'csit-trex-report-iter-{node-arch}-perftest' + skip-vote: false + + builders: + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/perf-verify.sh + + publishers: + - fdio-infra-publish - job-template: name: 'csit-vpp-perf-report-coverage-{stream_report}-{node-arch}' @@ -881,10 +1520,6 @@ <li>trigger example: csit-vpp-report-cov-{node-arch}-perftest ip4-00 </ul> - <li>executor - <ul> - <li>{executor} - </ul> <li>perf test-cases selection <ul> <li>test-cases selected by tags defined in @@ -901,30 +1536,27 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: 'archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' + - gerrit-event-type-parameter + - gerrit-event-comment-text-parameter - csit-perf-trial-duration-parameter: csit-perf-trial-duration: "{csit-perf-trial-duration}" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. scm: - gerrit-trigger-scm: @@ -946,16 +1578,13 @@ builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-verify.sh publishers: - - robot: - output-path: archive - other-files: - - '*.*' - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: name: 'csit-dpdk-perf-report-coverage-{stream_report}-{node-arch}' @@ -977,10 +1606,6 @@ <li>trigger example: csit-dpdk-report-cov-{node-arch}-perftest dpdk-00 </ul> - <li>executor - <ul> - <li>{executor} - </ul> <li>perf test-cases selection <ul> <li>test-cases selected by tags defined in @@ -997,30 +1622,27 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'm-builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: 'archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' + - gerrit-event-type-parameter + - gerrit-event-comment-text-parameter - csit-perf-trial-duration-parameter: csit-perf-trial-duration: "{csit-perf-trial-duration}" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. scm: - gerrit-trigger-scm: @@ -1042,13 +1664,96 @@ builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/perf-verify.sh publishers: - - robot: - output-path: archive - other-files: - - '*.*' + - fdio-infra-publish - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' +- job-template: + name: 'csit-trex-perf-report-coverage-{stream_report}-{node-arch}' + + description: | + <ul> + <li>objective + <ul> + <li>get trex performance coverage data for csit report + </ul> + <li>job + <ul> + <li>name: + <b>csit-trex-perf-report-coverage-{stream_report}- + {node-arch}</b> + <li>trigger: keyword in comment to csit patch: + <b>csit-trex-report-cov-{node-arch}-perftest + test_set_id</b> + <li>trigger example: + csit-trex-report-cov-{node-arch}-perftest trex-00 + </ul> + <li>perf test-cases selection + <ul> + <li>test-cases selected by tags defined in + <i>csit/docs/job_specs/report_coverage/{node-arch}/ + test_set_id.md</i> + </ul> + + <li>results + <ul> + <li>jjb verify: PASS/FAIL + <li>present: trex performance + <li>analyse: trex performance + </ul> + </ul> + + project-type: freestyle + node: 'm-builder-{os}-prod-{executor-arch}' + concurrent: true + latest-only: false + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' + - gerrit-event-type-parameter + - gerrit-event-comment-text-parameter + - csit-perf-trial-duration-parameter: + csit-perf-trial-duration: "{csit-perf-trial-duration}" + - csit-perf-trial-multiplicity-parameter: + csit-perf-trial-multiplicity: "{csit-perf-trial-multiplicity}" + + scm: + - gerrit-trigger-scm: + credentials-id: 'jenkins-gerrit-credentials' + refspec: '$GERRIT_REFSPEC' + choosing-strategy: 'gerrit' + + wrappers: + - fdio-infra-wrappers-non-activity-timeout: + build-timeout: '{build-timeout}' + + triggers: + - gerrit-trigger-csit-perftest: + project: '{project}' + branch: '{branch}' + trigger-word: 'csit-trex-report-cov-{node-arch}-perftest' + skip-vote: false + + builders: + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/perf-verify.sh + + publishers: + - fdio-infra-publish diff --git a/jjb/csit/csit-terraform.yaml b/jjb/csit/csit-terraform.yaml new file mode 100644 index 000000000..de5998e38 --- /dev/null +++ b/jjb/csit/csit-terraform.yaml @@ -0,0 +1,120 @@ +# Copyright (c) 2023 Cisco and/or its affiliates. +# 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. + +--- +- project: + name: csit-provision + description: 'CSIT Jenkins jobs.' + + jobs: + - 'csit-terraform-aws-eb-version-verify-{os}-{executor-arch}' + - 'csit-terraform-aws-eb-version-deploy-{os}-{executor-arch}' + + project: 'csit' + branch: 'master' + os: + - 'ubuntu2204' + executor-arch: 'x86_64' + build-artifact-num-to-keep: 10 + +- job-template: + name: 'csit-terraform-aws-eb-version-verify-{os}-{executor-arch}' + + project-type: freestyle + node: 's-builder-{os}-prod-{executor-arch}' + concurrent: false + latest-only: false + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + + scm: + - gerrit-trigger-scm: + credentials-id: 'jenkins-gerrit-credentials' + refspec: '' + choosing-strategy: 'default' + + wrappers: + - fdio-infra-wrappers-non-activity-timeout: + build-timeout: '{build-timeout}' + + triggers: + - gerrit-trigger-csit-terraform: + project: '{project}' + branch: '{branch}' + trigger-word: 'terraform-cdash-verify' + skip-vote: false + + builders: + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/terraform-aws-eb-version-verify.sh + + publishers: + - fdio-infra-publish + +- job-template: + name: 'csit-terraform-aws-eb-version-deploy-{os}-{executor-arch}' + + project-type: freestyle + node: 's-builder-{os}-prod-{executor-arch}' + concurrent: false + latest-only: false + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + + parameters: + - project-parameter: + project: '{project}' + - gerrit-parameter: + branch: '{branch}' + + scm: + - gerrit-trigger-scm: + credentials-id: 'jenkins-gerrit-credentials' + refspec: '' + choosing-strategy: 'default' + + wrappers: + - fdio-infra-wrappers-non-activity-timeout: + build-timeout: '{build-timeout}' + + triggers: + - gerrit-trigger-csit-terraform: + project: '{project}' + branch: '{branch}' + trigger-word: 'terraform-cdash-deploy' + skip-vote: false + + builders: + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/terraform-aws-eb-version-deploy.sh + + publishers: + - fdio-infra-publish diff --git a/jjb/csit/csit-tox.yaml b/jjb/csit/csit-tox.yaml index 2dfe07bf7..0e9d7ffc2 100644 --- a/jjb/csit/csit-tox.yaml +++ b/jjb/csit/csit-tox.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2020 Cisco and/or its affiliates. +# Copyright (c) 2023 Cisco and/or its affiliates. # 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: @@ -16,46 +16,37 @@ name: csit-validate jobs: - - 'csit-verify-tox-{stream}' + - 'csit-verify-tox-{stream}-{os}-{executor-arch}' project: 'csit' branch: 'master' + os: 'ubuntu2204' + executor-arch: 'x86_64' stream: - master: branch: 'master' - - '1908_2': - branch: 'rls1908_2' - - '2001': - branch: 'rls2001' - - '2005': - branch: 'rls2005' + - '2402': + branch: 'rls2402' - job-template: - name: 'csit-verify-tox-{stream}' + name: 'csit-verify-tox-{stream}-{os}-{executor-arch}' project-type: freestyle - node: ubuntu1804-us + node: 's-builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: '*.log' latest-only: false - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' - - gerrit-refspec-parameter - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' scm: - gerrit-trigger-scm: @@ -68,23 +59,45 @@ build-timeout: '{build-timeout}' triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' + # Tox trigger is special. + - gerrit: + server-name: 'Primary' + trigger-on: + - patchset-created-event: + exclude-drafts: 'true' + exclude-trivial-rebase: 'false' + exclude-no-code-change: 'false' + # Not enabling on draft published event. + # Frequently, people publish for public access, not fr verify. + # Use recheck comment to trigger verify. + - comment-added-contains-event: + comment-contains-value: 'recheck' + - comment-added-contains-event: + comment-contains-value: 'reverify' + projects: + - project-compare-type: 'ANT' + project-pattern: '{project}' + branches: + - branch-compare-type: 'ANT' + branch-pattern: '**/{branch}' + override-votes: true + gerrit-build-notbuilt-verified-value: 0 + gerrit-build-successful-verified-value: 1 + failed-message: 'Tox failed. No further verify jobs will be started.' + successful-message: 'tox_success' + skip-vote: + successful: true + failed: false + unstable: false + notbuilt: false builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/tox.sh publishers: - # TODO: Remove this when a voting pylint difference checker - # with nice enough output is implemented. - - violations: - pylint: - min: 10 - max: 250 - unstable: 250 - pattern: 'pylint.log' - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish diff --git a/jjb/csit/csit-vpp-device.yaml b/jjb/csit/csit-vpp-device.yaml index 373c20a3f..dbf3ef931 100644 --- a/jjb/csit/csit-vpp-device.yaml +++ b/jjb/csit/csit-vpp-device.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2020 Cisco and/or its affiliates. +# Copyright (c) 2023 Cisco and/or its affiliates. # 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: @@ -15,125 +15,62 @@ - project: name: csit-vpp-device description: 'CSIT jenkins jobs.' - os: - - 'ubuntu1804' - node-arch: - - '1n-skx' - - '1n-tx2': - executor: 'vpp-csit-arm-ubuntu18' - skip-vote: 'true' - trigger: 'gerrit-trigger-csit-vpp-devicetest-manual' jobs: - - 'csit-vpp-device-{stream}-{os}-{node-arch}' - - 'csit-vpp-device-{stream}-{os}-{node-arch}-semiweekly': + - 'csit-vpp-device-{stream}-{os}-{executor-arch}-{node-arch}' + - 'csit-vpp-device-semiweekly-{stream}-{os}-{executor-arch}-{node-arch}' + - 'csit-vpp-device-weekly-{stream}-{os}-{executor-arch}-{node-arch}' + - 'csit-vpp-device-report-coverage-{stream}-{node-arch}': stream: - - master: - branch: 'master' - branch-id: 'oper' - - '1908_2': - branch: 'rls1908_2' - branch-id: 'oper-rls1908_2' - - '2005': - branch: 'rls2005' - branch-id: 'oper-rls2005' - - 'csit-vpp-device-{stream}-{os}-{node-arch}-weekly': - stream: - - master: - branch: 'master' - branch-id: 'oper' - - '1908_2': - branch: 'rls1908_2' - branch-id: 'oper-rls1908_2' - - '2005': - branch: 'rls2005' - branch-id: 'oper-rls2005' - - 'csit-vpp-device-master-{os}-1n-tx2-csit-verify-hourly' - - 'csit-vpp-device-master-{os}-1n-tx2-vpp-verify-hourly' - + - '2402': + branch: 'rls2402' + branch-id: 'oper-rls2402' + node-arch: + - '1n-alt': + os: 'ubuntu2204' + executor-arch: 'aarch64' + make-parallel-jobs: '32' + skip-vote: 'false' + - '1n-spr': + os: 'ubuntu2204' + executor-arch: 'x86_64' + make-parallel-jobs: '32' + skip-vote: 'true' project: 'csit' - executor: 'vpp-csit-device' branch: 'master' branch-id: 'oper' - trigger: 'gerrit-trigger-csit-vpp-devicetest-full' stream: - master: branch: 'master' branch-id: 'oper' - - '1908_2': - branch: 'rls1908_2' - branch-id: 'oper-rls1908_2' - - '2001': - branch: 'rls2001' - branch-id: 'oper-rls2001' - - '2005': - branch: 'rls2005' - branch-id: 'oper-rls2005' + - '2402': + branch: 'rls2402' + branch-id: 'oper-rls2402' - job-template: - name: 'csit-vpp-device-{stream}-{os}-{node-arch}' - description: | - <ul> - <li>objective - <ul> - <li>vpp-device verify - per csit gerrit patch - </ul> - <li>job - <ul> - <li>name: <b>csit-vpp-device-{stream}-{os}-{node-arch}</b> - <li>trigger: keyword in comment to csit patch: - <b>csit-devicetest tag_list</b> - </ul> - <li>executor - <ul> - <li>{executor} - </ul> - <li>test-cases selection - <ul> - <li>test-cases selected using trigger keyword followed by tags - <li>all test-cases are labelled with CSIT RF topic tags - defined in <i>csit/docs/tag_documentation.rst</i> - </ul> - <li>default tags for vpp-device test type - <ul> - <li>devicetest - </ul> - <li>results - <ul> - <li>jjb verify: PASS/FAIL - <li>present: no - <li>analyse: no - </ul> - </ul> + name: 'csit-vpp-device-report-coverage-{stream}-{node-arch}' project-type: freestyle - node: '{executor}' + node: 'csit-builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: 'archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' - os-parameter: os: '{os}' - - gerrit-refspec-parameter + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' - gerrit-event-type-parameter - gerrit-event-comment-text-parameter - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - # This is an automatic verify job, part of API coverage. - # CRC checking is needed to ensure vpp crc job breaks only when intended. - # Unlikely to be removed, as this job is primary source of API coverage. - csit-fail-on-crc-mismatch-parameter: fail-on-crc-mismatch: 'True' @@ -148,247 +85,150 @@ build-timeout: '{build-timeout}' triggers: - - '{trigger}': + - gerrit-trigger-csit-perftest: project: '{project}' branch: '{branch}' - skip-vote: '{skip-vote}' + trigger-word: 'csit-vpp-report-dev-{node-arch}' + skip-vote: false builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/csit/device-verify.sh publishers: - - robot: - output-path: archive - other-files: - - '*.*' - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: - name: 'csit-vpp-device-{stream}-{os}-{node-arch}-semiweekly' - description: | - <ul> - <li>objective - <ul> - <li>Validate latest vpp build from corresponding branch stored - in nexus against verified CSIT codebase of corresponding - branch. - </ul> - <li>executor - <ul> - <li>{executor} - </ul> - <li>test-cases selection - <ul> - <li>pre-selected test-cases - <li>all test-cases are labelled with CSIT RF topic tags - defined in <i>csit/docs/tag_documentation.rst</i> - </ul> - <li>default tags for vpp-device test type - <ul> - <li>devicetest - </ul> - <li>results - <ul> - <li>jjb verify: PASS/FAIL - <li>present: no - <li>analyse: no - </ul> - </ul> + name: 'csit-vpp-device-{stream}-{os}-{executor-arch}-{node-arch}' project-type: freestyle - node: '{executor}' - concurrent: false - archive-artifacts: 'csit/archive/*.*' + node: 'csit-builder-{os}-prod-{executor-arch}' + concurrent: true latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' - os-parameter: os: '{os}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + - gerrit-refspec-parameter: + refspec: '$GERRIT_REFSPEC' + - gerrit-event-type-parameter + - gerrit-event-comment-text-parameter + # This is an automatic verify job, part of API coverage. + # CRC checking is needed to ensure vpp crc job breaks only when intended. + # Unlikely to be removed, as this job is primary source of API coverage. + - csit-fail-on-crc-mismatch-parameter: + fail-on-crc-mismatch: 'True' + + scm: + - gerrit-trigger-scm: + credentials-id: 'jenkins-gerrit-credentials' + refspec: '$GERRIT_REFSPEC' + choosing-strategy: 'gerrit' wrappers: - - fdio-infra-wrappers-non-activity-timeout: + - fdio-infra-wrappers: build-timeout: '{build-timeout}' triggers: - - timed: '0 4 * * 2,6' - - - gerrit-trigger-manually-triggered: - comment-trigger-value: 'csit-verify-vpp' - name: '{project}' + - gerrit-trigger-csit-vpp-devicetest-full: + project: '{project}' branch: '{branch}' + skip-vote: '{skip-vote}' builders: - - shell: 'echo "BRANCH_ID={branch-id}" > $WORKSPACE/variables.prop' - - inject: - properties-file: variables.prop - shell: !include-raw-escape: - - ../scripts/csit/device-semiweekly.sh + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/device-verify.sh publishers: - - robot: - output-path: 'csit/archive' - other-files: - - '*.*' - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: - name: 'csit-vpp-device-{stream}-{os}-{node-arch}-weekly' - description: | - <ul> - <li>objective - <ul> - <li>Validate CSIT code of corresponding branch against - verified vpp build from corresponding branch. - </ul> - <li>executor - <ul> - <li>{executor} - </ul> - <li>test-cases selection - <ul> - <li>pre-selected test-cases - <li>all test-cases are labelled with CSIT RF topic tags - defined in <i>csit/docs/tag_documentation.rst</i> - </ul> - <li>default tags for vpp-device test type - <ul> - <li>devicetest - </ul> - <li>results - <ul> - <li>jjb verify: PASS/FAIL - <li>present: no - <li>analyse: no - </ul> - </ul> + name: 'csit-vpp-device-semiweekly-{stream}-{os}-{executor-arch}-{node-arch}' project-type: freestyle - node: '{executor}' + node: 'csit-builder-{os}-prod-{executor-arch}' concurrent: false - archive-artifacts: 'archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' - os-parameter: os: '{os}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - git-scm: - credentials-id: 'jenkins-gerrit-credentials' - branch: '{branch}' wrappers: - fdio-infra-wrappers-non-activity-timeout: build-timeout: '{build-timeout}' triggers: - - timed: '0 4 * * 0' + - timed: '0 4 * * 2,6' - gerrit-trigger-manually-triggered: - comment-trigger-value: 'csit-vpp-ref-verify' + comment-trigger-value: 'csit-verify-vpp' name: '{project}' branch: '{branch}' builders: + - shell: 'echo "BRANCH_ID={branch-id}" > $WORKSPACE/variables.prop' + - inject: + properties-file: variables.prop - shell: !include-raw-escape: - - ../scripts/csit/device-verify.sh + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/device-semiweekly.sh publishers: - - robot: - output-path: archive - other-files: - - '*.*' - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish - job-template: - name: 'csit-vpp-device-master-{os}-1n-tx2-csit-verify-hourly' - description: | - <ul> - <li>objective - <ul> - <li>Validate CSIT code of corresponding branch against - verified vpp build from corresponding branch. - </ul> - <li>executor - <ul> - <li>vpp-csit-arm-ubuntu18 - </ul> - <li>test-cases selection - <ul> - <li>pre-selected test-cases - <li>all test-cases are labelled with CSIT RF topic tags - defined in <i>csit/docs/tag_documentation.rst</i> - </ul> - <li>default tags for vpp-device test type - <ul> - <li>devicetest - </ul> - <li>results - <ul> - <li>jjb verify: PASS/FAIL - <li>present: no - <li>analyse: no - </ul> - </ul> + name: 'csit-vpp-device-weekly-{stream}-{os}-{executor-arch}-{node-arch}' project-type: freestyle - node: 'vpp-csit-arm-ubuntu18' + node: 'csit-builder-{os}-prod-{executor-arch}' concurrent: false - archive-artifacts: 'archive/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' - os-parameter: - os: 'ubuntu1804' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + os: '{os}' scm: - git-scm: @@ -400,96 +240,20 @@ build-timeout: '{build-timeout}' triggers: - - timed: '0 * * * *' - - builders: - - shell: - !include-raw-escape: - - ../scripts/csit/device-verify.sh - - publishers: - - robot: - output-path: archive - other-files: - - '*.*' - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'csit-vpp-device-master-{os}-1n-tx2-vpp-verify-hourly' - description: | - <ul> - <li>objective - <ul> - <li>Validate latest vpp build from corresponding branch stored - in nexus against verified CSIT codebase of corresponding - branch. - </ul> - <li>executor - <ul> - <li>vpp-csit-arm-ubuntu18 - </ul> - <li>test-cases selection - <ul> - <li>pre-selected test-cases - <li>all test-cases are labelled with CSIT RF topic tags - defined in <i>csit/docs/tag_documentation.rst</i> - </ul> - <li>default tags for vpp-device test type - <ul> - <li>devicetest - </ul> - <li>results - <ul> - <li>jjb verify: PASS/FAIL - <li>present: no - <li>analyse: no - </ul> - </ul> - - project-type: freestyle - node: 'vpp-csit-arm-ubuntu18' - concurrent: false - archive-artifacts: 'csit/archive/*.*' - latest-only: false - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + - timed: '0 4 * * 0' - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: + - gerrit-trigger-manually-triggered: + comment-trigger-value: 'csit-vpp-ref-verify' + name: '{project}' branch: '{branch}' - - os-parameter: - os: 'ubuntu1804' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - wrappers: - - fdio-infra-wrappers-non-activity-timeout: - build-timeout: '{build-timeout}' - - triggers: - - timed: '30 * * * *' builders: - - shell: 'echo "BRANCH_ID={branch-id}" > $WORKSPACE/variables.prop' - - inject: - properties-file: variables.prop - shell: !include-raw-escape: - - ../scripts/csit/device-semiweekly.sh + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/csit/device-verify.sh publishers: - - robot: - output-path: 'csit/archive' - other-files: - - '*.*' - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' + - fdio-infra-publish diff --git a/jjb/csit/csit.yaml b/jjb/csit/csit.yaml index 7e3b8f033..5bb63fd5c 100644 --- a/jjb/csit/csit.yaml +++ b/jjb/csit/csit.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2020 Cisco and/or its affiliates. +# Copyright (c) 2023 Cisco and/or its affiliates. # 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: @@ -13,288 +13,11 @@ --- - project: - name: csit - description: 'CSIT Jenkins jobs.' - - jobs: - - 'csit-docs-merge-{stream}' - - 'csit-report-merge-{stream}' - - 'csit-trending-daily-master' - - project: 'csit' - branch: 'master' - executor: 'ubuntu1804-us' - executor-large: 'ubuntu1804-l' - build-artifact-num-to-keep: 10 - stream: - - master: - branch: 'master' - - '1908_2': - branch: 'rls1908_2' - - '2001': - branch: 'rls2001' - - '2005': - branch: 'rls2005' - -- project: name: csit-view views: - project-view project-name: csit -- job-template: - name: 'csit-docs-merge-{stream}' - - project-type: freestyle - node: '{executor}' - concurrent: true - allow-empty: 'true' - fingerprint: false - only-if-success: true - default-excludes: false - - build-discarder: - 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}' - - maven-exec: - maven-version: 'mvn33-new' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers-non-activity-timeout: - build-timeout: '{build-timeout}' - - triggers: - - reverse: - jobs: 'csit-vpp-device-{stream}-ubuntu1804-1n-skx-weekly' - result: 'success' - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'run-docs' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'csit-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'csit-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/csit/docs.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'csit-report-merge-{stream}' - - project-type: freestyle - node: '{executor-large}' - concurrent: false - allow-empty: 'true' - fingerprint: false - only-if-success: true - default-excludes: false - - build-discarder: - 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}' - - maven-exec: - maven-version: 'mvn33-new' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers-non-activity-timeout: - build-timeout: '{build-timeout}' - - triggers: - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'run-report' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'csit-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'csit-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/csit/report.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'csit-trending-daily-master' - - project-type: freestyle - node: '{executor-large}' - concurrent: false - - build-discarder: - 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}' - - maven-exec: - maven-version: 'mvn33-new' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers-non-activity-timeout: - build-timeout: '{build-timeout}' - - triggers: - - timed: '0 2,14 * * *' - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'csit-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'csit-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/csit/cpta.sh - - publishers: - - email-ext: - # yamllint disable-line rule:line-length - recipients: 'tifrank@cisco.com, csit-report+int+616+181919729795594561@lists.fd.io' - reply-to: '' - content-type: 'text' - subject: 'Failed tests as of $BUILD_TIMESTAMP' - # yamllint disable-line rule:line-length - body: | - Following tests failed in the last trending job runs, listed per testbed type. - - ${{FILE,path="build-root/docs/deploy-site/src/site/resources/trending/_static/vpp/trending-failed-tests.txt"}} - - always: true - failure: false - - - email-ext: - # yamllint disable-line rule:line-length - recipients: 'tifrank@cisco.com, csit-report+int+616+181919729795594561@lists.fd.io' - reply-to: '' - content-type: 'text' - subject: 'Regressions as of $BUILD_TIMESTAMP' - # yamllint disable-line rule:line-length - body: | - Following regressions occured in the last trending job runs, listed per testbed type. - - ${{FILE,path="build-root/docs/deploy-site/src/site/resources/trending/_static/vpp/trending-regressions.txt"}} - - always: true - failure: false - - - email-ext: - # yamllint disable-line rule:line-length - recipients: 'tifrank@cisco.com, csit-report+int+616+181919729795594561@lists.fd.io' - reply-to: '' - content-type: 'text' - subject: 'Progressions as of $BUILD_TIMESTAMP' - # yamllint disable-line rule:line-length - body: | - Following progressions occured in the last trending job runs, listed per testbed type. - - ${{FILE,path="build-root/docs/deploy-site/src/site/resources/trending/_static/vpp/trending-progressions.txt"}} - - always: true - failure: false - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - - project: name: csit-info project-name: csit diff --git a/jjb/dmm/dmm.yaml b/jjb/dmm/dmm.yaml deleted file mode 100644 index fc916d659..000000000 --- a/jjb/dmm/dmm.yaml +++ /dev/null @@ -1,253 +0,0 @@ ---- -######################################################################### -# -# Copyright (c) 2018 Huawei Technologies Co.,Ltd. -# 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. -######################################################################### - -- project: - name: dmm - jobs: - - 'dmm-verify-{stream}-checkstyle' - - 'dmm-verify-{stream}-{os}' - - 'dmm-merge-{stream}-{os}' - - project: 'dmm' - os: 'ubuntu1604' - - stream: - - master: - branch: 'master' - - non-dpdk: - branch: 'none-dpdk' - - DMM-2: - branch: 'DMM-2' - -- project: - name: dmm-csit - jobs: - - 'dmm-csit-verify-func-{stream}-{os}-virl' - - project: 'dmm' - os: 'ubuntu1604' - - stream: - - master: - branch: 'master' - - DMM-2: - branch: 'DMM-2' - -- project: - name: dmm-view - views: - - project-view - project-name: dmm - -- job-template: - name: 'dmm-verify-{stream}-checkstyle' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - - build-discarder: - 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: 'dmm' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: 'dmm' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: include-raw-dmm-test-checkstyle.sh - - publishers: - - lf-infra-publish - -- job-template: - name: 'dmm-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - - build-discarder: - 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: 'dmm' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: 'dmm' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: include-raw-build.sh - - publishers: - - lf-infra-publish - -- job-template: - name: 'dmm-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - build-discarder: - 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: 'dmm' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: 'dmm' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: include-raw-build.sh - - publishers: - - lf-infra-publish - -- job-template: - name: 'dmm-csit-verify-func-{stream}-{os}-virl' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - archive-artifacts: 'csit/archive/*.*' - latest-only: false - - build-discarder: - 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: 'dmm' - - gerrit-parameter: - branch: '{branch}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: 'dmm' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: include-raw-dmm-csit-functional-virl.sh - - publishers: - - robot-report: - output-path: 'csit' - - lf-infra-publish - -- project: - name: dmm-info - project-name: dmm - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-2c-2g - project: dmm - branch: master - -- project: - name: dmm-sonar - project: dmm - project-name: dmm - mvn-settings: dmm-settings - sonarcloud: true - sonarcloud-project-organization: '{sonarcloud_project_organization}' - sonarcloud-api-token: '{sonarcloud_api_token}' - sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}' - branch: master - build-node: centos7-docker-2c-2g - jobs: - - gerrit-maven-sonar diff --git a/jjb/dmm/include-raw-build.sh b/jjb/dmm/include-raw-build.sh deleted file mode 100755 index c49fcec6e..000000000 --- a/jjb/dmm/include-raw-build.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/bash -# basic build script example -set -e -o pipefail - -# Make DMM -./scripts/build.sh all - -echo "*******************************************************************" -echo "* DMM BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" - -# Run unit tests application -#need to be added - -#echo "*******************************************************************" -#echo "* DMM UNIT TESTS SUCCESSFUL" -#echo "*******************************************************************" diff --git a/jjb/dmm/include-raw-dmm-csit-functional-virl.sh b/jjb/dmm/include-raw-dmm-csit-functional-virl.sh deleted file mode 100644 index 444d2611c..000000000 --- a/jjb/dmm/include-raw-dmm-csit-functional-virl.sh +++ /dev/null @@ -1,45 +0,0 @@ -#!/bin/bash -# Copyright (c) 2018 Huawei Technologies Co.,Ltd. -# 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. - -set -xeu -o pipefail - -# Clone csit and start tests -git clone https://gerrit.fd.io/r/csit - -# If the git clone fails, complain clearly and exit -if [ $? != 0 ]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/csit" - exit 1 -fi - -mkdir -p ./csit/dmm/ - -# Move the dmm to the csit dir -rsync -av --progress --exclude="./csit" . ./csit/dmm/ - -cd csit - -# execute dmm bootstrap script if it exists -if [ -e bootstrap-DMM.sh ] -then - # make sure that bootstrap-DMM.sh is executable - chmod +x bootstrap-DMM.sh - # run the script - ./bootstrap-DMM.sh -else - echo 'ERROR: No bootstrap-DMM.sh found' - exit 1 -fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/global-defaults.yaml b/jjb/global-defaults.yaml index d77b53d7d..aead37a88 100644 --- a/jjb/global-defaults.yaml +++ b/jjb/global-defaults.yaml @@ -5,18 +5,17 @@ name: global build-days-to-keep: 30 - build-num-to-keep: 40 - build-artifact-days-to-keep: -1 - build-artifact-num-to-keep: 5 # Timeout in minutes build-timeout: 360 build-perf-timeout: 5760 + failure-notification: "releng+fdio@linuxfoundation.org" + failure-notification-prefix: "[releng]" + # global-jjb gerrit-server-name: Primary jenkins-ssh-credential: jenkins-gerrit-credentials lftools-version: <1.0.0 - archive-artifacts: '' # fd.io branch defaults branch: master @@ -31,6 +30,13 @@ csit-perf-trial-duration: 1.0 csit-perf-trial-multiplicity: 1 + # Config for PackageCloud.IO archive of DEB/RPM packages + packagecloud-account: fdio + packagecloud-repo: staging + + # Release config + jenkins-ssh-release-credential: jenkins-release + # Sonarcloud sonarcloud_project_organization: fdio sonarcloud_api_token: 9ea26e0b0bbe1f436a0df06d61d1e97dc5a3d6e3 diff --git a/jjb/global-macros.yaml b/jjb/global-macros.yaml index 66a70ba48..2de57c726 100644 --- a/jjb/global-macros.yaml +++ b/jjb/global-macros.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2020 Cisco and/or its affiliates. +# Copyright (c) 2021 Cisco and/or its affiliates. # 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: @@ -41,6 +41,22 @@ description: "The number of cores to use for builds." - parameter: + name: make-test-os-parameter + parameters: + - string: + name: MAKE_TEST_OS + default: '{make-test-os}' + description: "The OS on which 'make test' is run." + +- parameter: + name: make-test-multiworker-os-parameter + parameters: + - string: + name: MAKE_TEST_MULTIWORKER_OS + default: '{make-test-multiworker-os}' + description: "The OS on which 'make test' is run with multiple VPP workers." + +- parameter: name: csit-fail-on-crc-mismatch-parameter parameters: - string: @@ -165,14 +181,6 @@ description: "JJB configured PROJECT parameter to identify a Gerrit project" - parameter: - name: repo-name-parameter - parameters: - - string: - name: REPO_NAME - default: '{repo-name}' - description: 'Name of repo to which to publish packaging' - -- parameter: name: stream-parameter parameters: - string: @@ -280,6 +288,22 @@ #### TRIGGERS # Keep 'trigger' entries ordered alphabetically, please. - trigger: + name: gerrit-trigger-build + # Comes from hicn, some verify jobs wait for build to pass. + triggers: + - gerrit: + server-name: 'Primary' + trigger-on: + - comment-added-contains-event: + comment-contains-value: 'build_success-{stream}-{os}-{executor-arch}' + projects: + - project-compare-type: 'ANT' + project-pattern: '{name}' + branches: + - branch-compare-type: 'ANT' + branch-pattern: '**/{branch}' + +- trigger: name: gerrit-trigger-checkstyle # Comes from VPP, some verify jobs wait for checkstyle to pass. # This macro is to be used for such verify jobs which are voting. @@ -345,24 +369,42 @@ notbuilt: '{skip-vote}' - trigger: + name: gerrit-trigger-csit-terraform + # Manual trigger common for csit-terraform jobs. + triggers: + - gerrit: + server-name: 'Primary' + trigger-on: + - comment-added-contains-event: + comment-contains-value: '{trigger-word}' + projects: + - project-compare-type: 'ANT' + project-pattern: '{project}' + branches: + - branch-compare-type: 'ANT' + branch-pattern: '**/{branch}' + skip-vote: + successful: '{skip-vote}' + failed: '{skip-vote}' + unstable: '{skip-vote}' + notbuilt: '{skip-vote}' + +- trigger: name: gerrit-trigger-csit-vpp-devicetest-full - # Comes from CSIT, for automatic jobs running "device" tests with VPP builds. + # Comes from CSIT, for automatic jobs running device tests with VPP builds. # The job acts as an automatic verify job for CSIT contributions. triggers: - gerrit: server-name: 'Primary' trigger-on: - - patchset-created-event: - exclude-drafts: 'true' - exclude-trivial-rebase: 'false' - exclude-no-code-change: 'false' - - draft-published-event + # The main way the job is triggered automatically on patch upload. + # Gated by tox job, so we do not spend resources on WiP changes. - comment-added-contains-event: - comment-contains-value: 'recheck' - - comment-added-contains-event: - comment-contains-value: 'reverify' + comment-contains-value: 'tox_success' + # Manual trigger to allow testing WiP changes with selected tags. - comment-added-contains-event: comment-contains-value: 'csit-devicetest' + # A comment with "recheck" restarts tox job, so no condition here. projects: - project-compare-type: 'ANT' project-pattern: '{project}' @@ -616,6 +658,103 @@ latest-only: true - publisher: + name: csit-trending-failed + publishers: + - email-ext: + # yamllint disable-line rule:line-length + recipients: 'tifrank@cisco.com, csit-report+int+616+181919729795594561@lists.fd.io' + reply-to: '' + content-type: 'text' + subject: '{branch}: Failed tests as of $BUILD_TIMESTAMP' + # yamllint disable-line rule:line-length + body: | + Following tests failed in the last trending job runs, listed per testbed type. + + ${{FILE,path="resources/tools/presentation/_build/_static/vpp/trending-failed-tests.txt"}} + failure: false + success: true + +- publisher: + name: csit-trending-failed-job + publishers: + - email-ext: + # yamllint disable-line rule:line-length + recipients: 'tifrank@cisco.com, csit-report+int+616+181919729795594561@lists.fd.io' + reply-to: '' + content-type: 'text' + subject: '{branch}: The build number $BUILD_NUMBER of the job $JOB_NAME failed' + # yamllint disable-line rule:line-length + body: | + For more information see $BUILD_URL. + failure: true + success: false + +- publisher: + name: csit-trending-progressions + publishers: + - email-ext: + # yamllint disable-line rule:line-length + recipients: 'tifrank@cisco.com, csit-report+int+616+181919729795594561@lists.fd.io' + reply-to: '' + content-type: 'text' + subject: '{branch}: Progressions as of $BUILD_TIMESTAMP' + # yamllint disable-line rule:line-length + body: | + Following progressions occured in the last trending job runs, listed per testbed type. + + ${{FILE,path="resources/tools/presentation/_build/_static/vpp/trending-progressions.txt"}} + failure: false + success: true + +- publisher: + name: csit-trending-regressions + publishers: + - email-ext: + # yamllint disable-line rule:line-length + recipients: 'tifrank@cisco.com, csit-report+int+616+181919729795594561@lists.fd.io' + reply-to: '' + content-type: 'text' + subject: '{branch}: Regressions as of $BUILD_TIMESTAMP' + # yamllint disable-line rule:line-length + body: | + Following regressions occured in the last trending job runs, listed per testbed type. + + ${{FILE,path="resources/tools/presentation/_build/_static/vpp/trending-regressions.txt"}} + failure: false + success: true + +- publisher: + name: vpp-dpdk-rdma-version-mismatch + publishers: + - email-ext: + # NOTE: noreply@jenkins.fd.io must be a member of vpp-build@lists.fd.io + # for the email to be distributed to the group members. + # yamllint disable-line rule:line-length + recipients: 'vpp-build@lists.fd.io' + reply-to: '' + content-type: 'text' + subject: '{branch}: vpp-dpdk-rdma-version-mismatch job failed!' + # yamllint disable-line rule:line-length + body: | + Build $BUILD_NUMBER of $JOB_NAME failed. + Check $BUILD_URL + console log to see if the job failed due to a package version mismatch or + a CI infra issue. If the failure was due to a CI infra issue, then + there is nothing else to be done. + + However, if there was a package version mismatch, then the MLX driver + is NOT being built in the VPP DPDK library. Please push a gerrit change + with the updated package version(s) in the version matrix file, resolve + any build issues, and merge the change to re-enable the building of the + MLX DPDK driver in the VPP DPDK library. + + Thanks, + The VPP Build Maintainers + + failure: true + success: false + +- publisher: name: email-notification publishers: - email-ext: @@ -635,16 +774,93 @@ - recipients - publisher: - name: fdio-infra-shiplogs - # To archive things, the job will need to create an "archives" directory in - # the workspace and this macro will handle copying the contents of the - # archives directory. + name: fdio-infra-publish-docs + # macro to finish up a docs build. + # + # Handles the following: + # - Mapping docs S3 bucket credentials for merge job docs upload + # - Cleanup workspace + publishers: + - postbuildscript: + builders: + - role: BOTH + build-on: + - ABORTED + - FAILURE + - NOT_BUILT + - SUCCESS + - UNSTABLE + build-steps: + - fdio-infra-ship-docs + mark-unstable-if-failed: true + - workspace-cleanup: + exclude: + # Do not clean up *.jenkins-trigger files for jobs that use a + # properties file as input for triggering another build. + - "**/*.jenkins-trigger" + fail-build: false + +- publisher: + name: fdio-infra-publish-cov-7day + # macro to finish up a verify docs build. + # + # Handles the following: + # - Mapping 7-day retention S3 bucket credentials for verify job docs upload + # - Cleanup workspace + publishers: + - postbuildscript: + builders: + - role: BOTH + build-on: + - ABORTED + - FAILURE + - NOT_BUILT + - SUCCESS + - UNSTABLE + build-steps: + - fdio-infra-ship-cov-7day + mark-unstable-if-failed: true + - workspace-cleanup: + exclude: + # Do not clean up *.jenkins-trigger files for jobs that use a + # properties file as input for triggering another build. + - "**/*.jenkins-trigger" + fail-build: false + +- publisher: + name: fdio-infra-publish-docs-7day + # macro to finish up a verify docs build. # - # Uses the build parameter ARCHIVE_ARTIFACTS if not empty to find files to - # archive. You can pass globstar patterns for example "**/*.xml **/*.log" as - # the archive pattern. This is a space separated list of files to archive. + # Handles the following: + # - Mapping 7-day retention S3 bucket credentials for verify job docs upload + # - Cleanup workspace + publishers: + - postbuildscript: + builders: + - role: BOTH + build-on: + - ABORTED + - FAILURE + - NOT_BUILT + - SUCCESS + - UNSTABLE + build-steps: + - fdio-infra-ship-docs-7day + mark-unstable-if-failed: true + - workspace-cleanup: + exclude: + # Do not clean up *.jenkins-trigger files for jobs that use a + # properties file as input for triggering another build. + - "**/*.jenkins-trigger" + fail-build: false + +- publisher: + name: fdio-infra-publish + # macro to finish up a build. # - # Also ensure that the workspace is cleaned up at the end of the build. + # Handles the following: + # - Shipping logs to S3 logs repository + # - Cleanup workspace publishers: - postbuildscript: builders: @@ -656,19 +872,15 @@ - SUCCESS - UNSTABLE build-steps: - - shell: !include-raw: include-raw-deploy-archives.sh - - maven-target: - maven-version: '{maven-version}' - pom: '.archives/deploy-archives.xml' - goals: 'clean deploy -V -B -q -Dmaven.repo.local=/tmp/r' - settings: 'jenkins-log-archives-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - description-setter: - regexp: '^Build logs: .*' + - shell: !include-raw-escape: scripts/post_build_executor_info.sh + - shell: !include-raw-escape: scripts/post_build_deploy_archives.sh + - fdio-infra-ship-logs mark-unstable-if-failed: true - workspace-cleanup: + exclude: + # Do not clean up *.jenkins-trigger files for jobs that use a + # properties file as input for triggering another build. + - "**/*.jenkins-trigger" fail-build: false - publisher: @@ -701,6 +913,7 @@ - robot: output-path: '{output-path}' other-files: '' + # [end] Keep 'publisher' entries ordered alphabetically, please. #### BUILDERS @@ -711,12 +924,63 @@ - shell: | $WORKSPACE/scripts/check-unicode.sh jjb/ -- property: - name: fdio-infra-properties - properties: - - build-discarder: - days-to-keep: '{build-days-to-keep}' - num-to-keep: '{build-num-to-keep}' +- builder: + name: fdio-infra-ship-docs + builders: + - config-file-provider: + files: + - file-id: "jenkins-s3-docs-ship" + target: $HOME/.aws/credentials + - shell: !include-raw-escape: + - scripts/terraform_s3_docs_ship.sh + - shell: !include-raw-escape: + - scripts/publish_docs.sh + - shell: !include-raw: + - ../global-jjb/shell/logs-clear-credentials.sh + +- builder: + name: fdio-infra-ship-cov-7day + builders: + - config-file-provider: + files: + - file-id: "jenkins-s3-vpp-docs-ship" + target: $HOME/.aws/credentials + - shell: !include-raw-escape: + - scripts/terraform_s3_docs_ship.sh + - shell: !include-raw-escape: + - scripts/publish_cov.sh + - shell: !include-raw: + - ../global-jjb/shell/logs-clear-credentials.sh + +- builder: + name: fdio-infra-ship-docs-7day + builders: + - config-file-provider: + files: + - file-id: "jenkins-s3-vpp-docs-ship" + target: $HOME/.aws/credentials + - shell: !include-raw-escape: + - scripts/terraform_s3_docs_ship.sh + - shell: !include-raw-escape: + - scripts/publish_docs.sh + - shell: !include-raw: + - ../global-jjb/shell/logs-clear-credentials.sh + +- builder: + name: fdio-infra-ship-logs + builders: + - config-file-provider: + files: + - file-id: "jenkins-s3-log-ship" + target: $HOME/.aws/credentials + - shell: !include-raw-escape: + - scripts/publish_library_py.sh + - shell: !include-raw: + - scripts/publish_logs.sh + - shell: !include-raw: + - ../global-jjb/shell/logs-clear-credentials.sh + - description-setter: + regexp: "(^S3 build logs: .*)" - builder: name: packer-validate diff --git a/jjb/hc2vpp/hc2vpp-csit.yaml b/jjb/hc2vpp/hc2vpp-csit.yaml deleted file mode 100644 index a1f84820e..000000000 --- a/jjb/hc2vpp/hc2vpp-csit.yaml +++ /dev/null @@ -1,436 +0,0 @@ ---- -- project: - name: hc2vpp-csit - description: 'jenkins jobs to test Hc2vpp features.' - jobs: - - 'hc2vpp-csit-integration-{stream}-{os}' - - 'hc2vpp-csit-verify-{stream}-{os}' - - 'hc2vpp-csit-integration-odl-{odl}-{stream}-{os}' - - 'hc2vpp-csit-verify-odl-{odl}-{stream}-{os}' - project: 'hc2vpp' - build-artifact-num-to-keep: 10 - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - '1810': - branch: 'stable/1810' - repo-stream-part: 'stable.1810' - - '1901': - branch: 'stable/1901' - repo-stream-part: 'stable.1901' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - - odl: 'neon' - -- project: - name: csit-hc2vpp-perf - description: 'jenkins jobs to test Hc2vpp performance.' - jobs: - - 'hc2vpp-csit-perf-{stream}-{os}' - project: 'hc2vpp' - build-artifact-num-to-keep: 10 - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - - odl: 'neon' - -- job-template: - name: 'hc2vpp-csit-integration-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - archive-artifacts: '**/csit/archive/*.*' - latest-only: false - - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - git-scm: - credentials-id: 'jenkins-gerrit-credentials' - branch: '{branch}' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - reverse: - jobs: 'hc2vpp-integration-{stream}-{os}' - result: 'success' - - builders: - - shell: - !include-raw-escape: include-raw-hc2vpp-csit-integration.sh - - publishers: - - email-notification: - email-prefix: '[hc2vpp]' - - - robot-report: - output-path: 'csit/archive' - - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'hc2vpp-csit-verify-{stream}-{os}' - - project-type: maven - node: '{os}-builder-4c-4g' - jdk: openjdk8-{os} - concurrent: true - archive-artifacts: '**/csit/archive/*.*' - latest-only: false - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn36' - - maven-exec: - maven-version: 'mvn36' - - stream-parameter: - stream: '{stream}' - - odl-parameter: - odl: '{odl}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'verify-csit' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - prebuilders: - - provide-maven-settings: - settings-file: 'honeycomb-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: include-raw-hc2vpp-csit-verify-prebuild.sh - - maven: - maven-name: 'mvn36' - root-pom: 'pom.xml' - # yamllint disable-line rule:line-length - goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -DskipTests -Dcheckstyle.skip=true' - maven-opts: '-Xmx2048m -Dmaven.compile.fork=true' - settings: 'hc2vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - postbuilders: - - shell: - !include-raw-escape: include-raw-hc2vpp-csit-verify.sh - - publishers: - - email-notification: - email-prefix: '[hc2vpp]' - - - robot-report: - output-path: 'csit/archive' - - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'hc2vpp-csit-integration-odl-{odl}-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - archive-artifacts: '**/csit/archive/*.*' - latest-only: false - - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - stream-parameter: - stream: '{stream}' - - odl-parameter: - odl: '{odl}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - git-scm: - credentials-id: 'jenkins-gerrit-credentials' - branch: '{branch}' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - reverse: - jobs: 'hc2vpp-integration-{stream}-{os}' - result: 'success' - - builders: - - shell: - !include-raw-escape: include-raw-hc2vpp-csit-integration-odl.sh - - publishers: - - email-notification: - email-prefix: '[hc2vpp]' - - - robot-report: - output-path: 'csit/archive' - - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'hc2vpp-csit-verify-odl-{odl}-{stream}-{os}' - - project-type: maven - node: '{os}-builder-4c-4g' - jdk: openjdk8-{os} - concurrent: true - archive-artifacts: '**/csit/archive/*.*' - latest-only: false - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn36' - - maven-exec: - maven-version: 'mvn36' - - stream-parameter: - stream: '{stream}' - - odl-parameter: - odl: '{odl}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'verify-csit' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - prebuilders: - - provide-maven-settings: - settings-file: 'honeycomb-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: include-raw-hc2vpp-csit-verify-prebuild.sh - - maven: - maven-name: 'mvn36' - root-pom: 'pom.xml' - # yamllint disable-line rule:line-length - goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -DskipTests -Dcheckstyle.skip=true' - maven-opts: '-Xmx2048m -Dmaven.compile.fork=true' - settings: 'hc2vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - postbuilders: - - shell: - !include-raw-escape: include-raw-hc2vpp-csit-verify-odl.sh - - publishers: - - email-notification: - email-prefix: '[hc2vpp]' - - - robot-report: - output-path: 'csit/archive' - - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'hc2vpp-csit-perf-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: false - archive-artifacts: '**/csit/archive/*.*' - latest-only: false - - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - stream-parameter: - stream: '{stream}' - - odl-parameter: - odl: '{odl}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - timed: '@weekly' - - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'verify-perf' - - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: false - failed: false - unstable: false - notbuilt: false - - builders: - - shell: - !include-raw-escape: include-raw-hc2vpp-csit-perf.sh - - publishers: - - robot-report: - output-path: 'csit/archive' - - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- parameter: - name: odl-parameter - parameters: - - string: - name: ODL - default: '{odl}' - description: "ODL version parameter." diff --git a/jjb/hc2vpp/hc2vpp.yaml b/jjb/hc2vpp/hc2vpp.yaml deleted file mode 100644 index f030cfe6c..000000000 --- a/jjb/hc2vpp/hc2vpp.yaml +++ /dev/null @@ -1,286 +0,0 @@ ---- -- project: - name: hc2vpp - jobs: - - 'hc2vpp-verify-{stream}-{os}' - - 'hc2vpp-merge-{stream}-{os}' - - 'hc2vpp-integration-{stream}-{os}' - project: 'hc2vpp' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - skip-site: 'false' - skip-jar-deploy: 'false' - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - skip-site: 'true' - skip-jar-deploy: 'true' - - centos7: - repo-os-part: 'centos7' - skip-site: 'true' - skip-jar-deploy: 'true' - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - '1810': - branch: 'stable/1810' - repo-stream-part: 'stable.1810' - - '1901': - branch: 'stable/1901' - repo-stream-part: 'stable.1901' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - -- project: - name: hc2vpp-view - views: - - project-view - project-name: hc2vpp - -- job-template: - name: 'hc2vpp-verify-{stream}-{os}' - project-type: maven - node: '{os}-builder-4c-4g' - concurrent: true - jdk: openjdk8-{os} - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: 'hc2vpp' - branch: '{branch}' - - maven: - maven-name: 'mvn36' - root-pom: 'pom.xml' - # yamllint disable-line rule:line-length - goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dmerge site' - maven-opts: '-Xmx2048m -Dmaven.compile.fork=true' - settings: 'hc2vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - publishers: - - email-notification: - email-prefix: '[hc2vpp]' - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'hc2vpp-merge-{stream}-{os}' - project-type: maven - node: '{os}-builder-4c-4g' - jdk: openjdk8-{os} - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn36' - - maven-exec: - maven-version: 'mvn36' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - ssh-agent-credentials: - users: - - 'jenkins-gerrit-credentials' - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: 'hc2vpp' - branch: '{branch}' - - maven: - maven-name: 'mvn36' - root-pom: 'pom.xml' - # yamllint disable-line rule:line-length - goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dmerge -Dsonar -Ddocs.hc.folder=io/fd/hc2vpp -Dmaven.site.skip={skip-site} site -Dmaven.site.deploy.skip={skip-site} site:deploy' - maven-opts: '-Xmx2048m -Dmaven.compile.fork=true' - settings: 'hc2vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - reporters: - - findbugs - - publishers: - - sonar: - jdk: 'openjdk8-{os}' - language: 'java' - branch: '{stream}' - - email-notification: - email-prefix: '[hc2vpp]' - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'hc2vpp-integration-{stream}-{os}' - project-type: maven - node: '{os}-builder-4c-4g' - jdk: openjdk8-{os} - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - stream-parameter: - stream: '{stream}' - - maven-project-parameter: - maven: 'mvn36' - - maven-exec: - maven-version: 'mvn36' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: SKIP_JAR_DEPLOY - default: '{skip-jar-deploy}' - # yamllint disable-line rule:line-length - description: "Skips deployment of hc2vpp jars if variable is set to true" - - scm: - - git-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - branch: '{branch}' - - wrappers: - - ssh-agent-credentials: - users: - - 'jenkins-gerrit-credentials' - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - reverse: - jobs: 'jvpp-merge-{stream}-{os},hc2vpp-merge-{stream}-{os}' - result: 'success' - - prebuilders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/home/jenkins' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/home/jenkins' - - - shell: - !include-raw-escape: include-raw-hc2vpp-integration-prebuild.sh - maven: - maven-name: 'mvn36' - root-pom: 'pom.xml' - # yamllint disable-line rule:line-length - goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dmerge' - maven-opts: '-Xmx2048m -Dmaven.compile.fork=true' - settings: 'hc2vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - postbuilders: - - maven-target: - maven-version: 'mvn36' - goals: '--version' - settings: 'hc2vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'hc2vpp-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-hc2vpp-pkg-push.sh - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - reporters: - - findbugs - - publishers: - - email-notification: - email-prefix: '[hc2vpp]' - - maven-deploy: - id: '' - unique-version: true - deploy-unstable: false - release-env-var: SKIP_JAR_DEPLOY - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- project: - name: hc2vpp-info - project-name: hc2vpp - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-2c-2g - project: hc2vpp - branch: master - -- project: - name: hc2vpp-sonar - project: hc2vpp - project-name: hc2vpp - mvn-settings: hc2vpp-settings - sonarcloud: true - sonarcloud-project-organization: '{sonarcloud_project_organization}' - sonarcloud-api-token: '{sonarcloud_api_token}' - sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}' - branch: master - build-node: centos7-docker-2c-2g - jobs: - - gerrit-maven-sonar diff --git a/jjb/hc2vpp/include-raw-hc2vpp-csit-integration-odl.sh b/jjb/hc2vpp/include-raw-hc2vpp-csit-integration-odl.sh deleted file mode 100644 index d21d19343..000000000 --- a/jjb/hc2vpp/include-raw-hc2vpp-csit-integration-odl.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash -set -xeu -o pipefail - -# Get CSIT branch -if [[ -f csit-test-branch ]]; then - chmod +x csit-test-branch - CSIT_BRANCH=`./csit-test-branch` -else - CSIT_BRANCH='master' -fi - -# Clone csit -git clone https://gerrit.fd.io/r/csit --branch ${CSIT_BRANCH} - -# If the git clone fails, complain clearly and exit -if [[ $? != 0 ]]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/csit --branch ${CSIT_BRANCH}" - exit 1 -fi - -cd csit -# execute csit bootstrap script if it exists -if [[ ! -e bootstrap-hc2vpp-integration-odl.sh ]] -then - echo 'ERROR: No bootstrap-hc2vpp-integration.sh found' - exit 1 -else - # make sure that bootstrap.sh is executable - chmod +x bootstrap-hc2vpp-integration-odl.sh - # run the script - ./bootstrap-hc2vpp-integration-odl.sh ${STREAM} ${OS} ${ODL} -fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/hc2vpp/include-raw-hc2vpp-csit-integration.sh b/jjb/hc2vpp/include-raw-hc2vpp-csit-integration.sh deleted file mode 100644 index 84a381839..000000000 --- a/jjb/hc2vpp/include-raw-hc2vpp-csit-integration.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash -set -xeu -o pipefail - -# Get CSIT branch -if [[ -f csit-test-branch ]]; then - chmod +x csit-test-branch - CSIT_BRANCH=`./csit-test-branch` -else - CSIT_BRANCH='master' -fi - -# Clone csit -git clone https://gerrit.fd.io/r/csit --branch ${CSIT_BRANCH} - -# If the git clone fails, complain clearly and exit -if [[ $? != 0 ]]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/csit --branch ${CSIT_BRANCH}" - exit 1 -fi - -cd csit -# execute csit bootstrap script if it exists -if [[ ! -e bootstrap-hc2vpp-integration.sh ]] -then - echo 'ERROR: No bootstrap-hc2vpp-integration.sh found' - exit 1 -else - # make sure that bootstrap.sh is executable - chmod +x bootstrap-hc2vpp-integration.sh - # run the script - ./bootstrap-hc2vpp-integration.sh ${STREAM} ${OS} -fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/hc2vpp/include-raw-hc2vpp-csit-perf.sh b/jjb/hc2vpp/include-raw-hc2vpp-csit-perf.sh deleted file mode 100644 index bf46af58a..000000000 --- a/jjb/hc2vpp/include-raw-hc2vpp-csit-perf.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash -set -xeu -o pipefail - -# Get CSIT branch -if [[ -f csit-test-branch ]]; then - chmod +x csit-test-branch - CSIT_BRANCH=`./csit-test-branch` -else - CSIT_BRANCH='master' -fi - -# Clone csit -git clone https://gerrit.fd.io/r/csit --branch ${CSIT_BRANCH} - -# If the git clone fails, complain clearly and exit -if [[ $? != 0 ]]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/csit --branch ${CSIT_BRANCH}" - exit 1 -fi - -cd csit -# execute csit bootstrap script if it exists -if [[ ! -e bootstrap-hc2vpp-perf.sh ]] -then - echo 'ERROR: No bootstrap-hc2vpp-perf.sh found' - exit 1 -else - # make sure that bootstrap.sh is executable - chmod +x bootstrap-hc2vpp-perf.sh - # run the script - ./bootstrap-hc2vpp-perf.sh ${STREAM} ${OS} ${ODL} -fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/hc2vpp/include-raw-hc2vpp-csit-verify-odl.sh b/jjb/hc2vpp/include-raw-hc2vpp-csit-verify-odl.sh deleted file mode 100644 index 271668d52..000000000 --- a/jjb/hc2vpp/include-raw-hc2vpp-csit-verify-odl.sh +++ /dev/null @@ -1,42 +0,0 @@ -#!/bin/bash -set -xeu -o pipefail - -# Figure out what system we are running on -if [[ -f /etc/lsb-release ]];then - . /etc/lsb-release -elif [[ -f /etc/redhat-release ]];then - sudo yum install -y redhat-lsb - DISTRIB_ID=`lsb_release -si` - DISTRIB_RELEASE=`lsb_release -sr` - DISTRIB_CODENAME=`lsb_release -sc` - DISTRIB_DESCRIPTION=`lsb_release -sd` -fi -echo "----- OS INFO -----" -echo DISTRIB_ID: ${DISTRIB_ID} -echo DISTRIB_RELEASE: ${DISTRIB_RELEASE} -echo DISTRIB_CODENAME: ${DISTRIB_CODENAME} -echo DISTRIB_DESCRIPTION: ${DISTRIB_DESCRIPTION} -DISTRIB_ID="Ubuntu" -if [[ "$DISTRIB_ID" != "Ubuntu" ]]; then - echo 'ERROR: Only Ubuntu is supported currently.' - exit 2 -fi - -# create HC .deb packages -./packaging/deb/${DISTRIB_CODENAME}/debuild.sh -cp ./packaging/deb/${DISTRIB_CODENAME}/*.deb ${WORKSPACE}/csit - -cd ${WORKSPACE}/csit -# execute csit bootstrap script if it exists -if [[ ! -e bootstrap-hc2vpp-verify.sh ]] -then - echo 'ERROR: No bootstrap-hc2vpp-verify.sh found' - exit 1 -else - # make sure that bootstrap.sh is executable - chmod +x bootstrap-hc2vpp-verify.sh - # run the script - ./bootstrap-hc2vpp-verify-odl.sh ${OS} ${ODL} -fi - -# vim: ts=4 ts=4 sts=4 et :
\ No newline at end of file diff --git a/jjb/hc2vpp/include-raw-hc2vpp-csit-verify-prebuild.sh b/jjb/hc2vpp/include-raw-hc2vpp-csit-verify-prebuild.sh deleted file mode 100644 index 8e0c4ef91..000000000 --- a/jjb/hc2vpp/include-raw-hc2vpp-csit-verify-prebuild.sh +++ /dev/null @@ -1,89 +0,0 @@ -#!/bin/bash -set -xe -o pipefail - -# Parse optional arguments from gerrit comment trigger -for i in ${GERRIT_EVENT_COMMENT_TEXT}; do - case ${i} in - *honeycomb=*) - hc_commit_id=`echo "${i}" | cut -d = -f2-` - ;; - *jvpp=*) - jvpp_commit_id=`echo "${i}" | cut -d = -f2-` - ;; - *vpp=*) - vpp_commit_id=`echo "${i}" | cut -d = -f2-` - ;; - *nsh_sfc=*) - nsh_commit_id=`echo "${i}" | cut -d = -f2-` - ;; - *csit=*) - csit_commit_id=`echo "${i}" | cut -d = -f2-` - ;; - *) - ;; - esac -done - -# If HC variable is set, clone and build Honeycomb infra from the specified commit -# Otherwise skip this step, hc2vpp will use Honeycomb snapshots from Nexus -if [[ -n "${hc_commit_id}" ]]; then - git clone https://gerrit.fd.io/r/honeycomb - cd honeycomb - ref=`git ls-remote -q | grep ${hc_commit_id} | awk '{print $2}'` - git fetch origin ${ref} && git checkout FETCH_HEAD - mvn clean install -DskipTests -Dcheckstyle.skip -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" - if [[ $? != 0 ]]; then - echo "Honeycomb infra build failed." - exit 1 - fi - cd ${WORKSPACE} - # Clean up when done. Leftover build files interfere with building hc2vpp. - rm -rf honeycomb -fi - -# TODO: Add option to build custom VPP and NSH packages - -# Get CSIT branch from which to test from -if [[ -f csit-test-branch ]]; then - chmod +x csit-test-branch - CSIT_BRANCH=`./csit-test-branch` -else - CSIT_BRANCH='master' -fi - -# Clone csit -git clone https://gerrit.fd.io/r/csit --branch ${CSIT_BRANCH} - -# If the git clone fails, complain clearly and exit -if [[ $? != 0 ]]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/csit --branch ${CSIT_BRANCH}" - exit 1 -fi - -cd csit - -# If CSIT commit ID is given, checkout the specified commit -if [[ -n "${csit_commit_id}" ]]; then - # Example: - # ... - # e8f326efebb58e28dacb9ebb653baf95aad1448c refs/changes/08/11808/1 - # ... - ref=`git ls-remote -q | grep ${csit_commit_id} | awk '{print $2}'` - git fetch origin ${ref} && git checkout FETCH_HEAD -fi - -# Download VPP packages -if [[ "1807 1810 1901" =~ .*$STREAM.* ]]; then - # add stable prefix for branches which have older version of package download script - # This can be removed when support for 1901 branch ends. - if [[ -n "${jvpp_commit_id}" ]]; then - echo "Error: Specifying jvpp custom commit is not supported for 1807,1810,1901 stable branches" - exit 1 - fi - ./resources/tools/scripts/download_hc_build_pkgs.sh 'stable.'${STREAM} ${OS} -else - # master and 1904+ branches use new package-cloud download script - ./resources/tools/scripts/download_hc_build_pkgs.sh ${STREAM} ${OS} ${jvpp_commit_id} -fi - -cd ${WORKSPACE} diff --git a/jjb/hc2vpp/include-raw-hc2vpp-csit-verify.sh b/jjb/hc2vpp/include-raw-hc2vpp-csit-verify.sh deleted file mode 100644 index 21dc80ced..000000000 --- a/jjb/hc2vpp/include-raw-hc2vpp-csit-verify.sh +++ /dev/null @@ -1,42 +0,0 @@ -#!/bin/bash -set -xeu -o pipefail - -# Figure out what system we are running on -if [[ -f /etc/lsb-release ]];then - . /etc/lsb-release -elif [[ -f /etc/redhat-release ]];then - sudo yum install -y redhat-lsb - DISTRIB_ID=`lsb_release -si` - DISTRIB_RELEASE=`lsb_release -sr` - DISTRIB_CODENAME=`lsb_release -sc` - DISTRIB_DESCRIPTION=`lsb_release -sd` -fi -echo "----- OS INFO -----" -echo DISTRIB_ID: ${DISTRIB_ID} -echo DISTRIB_RELEASE: ${DISTRIB_RELEASE} -echo DISTRIB_CODENAME: ${DISTRIB_CODENAME} -echo DISTRIB_DESCRIPTION: ${DISTRIB_DESCRIPTION} - -if [[ "$DISTRIB_ID" != "Ubuntu" ]]; then - echo 'ERROR: Only Ubuntu is supported currently.' - exit 2 -fi - -# create HC .deb packages -./packaging/deb/${DISTRIB_CODENAME}/debuild.sh -cp ./packaging/deb/${DISTRIB_CODENAME}/*.deb ${WORKSPACE}/csit - -cd ${WORKSPACE}/csit -# execute csit bootstrap script if it exists -if [[ ! -e bootstrap-hc2vpp-verify.sh ]] -then - echo 'ERROR: No bootstrap-hc2vpp-verify.sh found' - exit 1 -else - # make sure that bootstrap.sh is executable - chmod +x bootstrap-hc2vpp-verify.sh - # run the script - ./bootstrap-hc2vpp-verify.sh ${OS} -fi - -# vim: ts=4 ts=4 sts=4 et :
\ No newline at end of file diff --git a/jjb/hc2vpp/include-raw-hc2vpp-integration-prebuild.sh b/jjb/hc2vpp/include-raw-hc2vpp-integration-prebuild.sh deleted file mode 100644 index dc4ca43de..000000000 --- a/jjb/hc2vpp/include-raw-hc2vpp-integration-prebuild.sh +++ /dev/null @@ -1,95 +0,0 @@ -#!/bin/bash - -set -ex -# Download the latest VPP java API package -VERSION="RELEASE" -VERSION=`./jvpp-version` - -# Figure out what system we are running on -if [[ -f /etc/lsb-release ]];then - . /etc/lsb-release -elif [[ -f /etc/redhat-release ]];then - sudo yum install -y redhat-lsb - DISTRIB_ID=`lsb_release -si` - DISTRIB_RELEASE=`lsb_release -sr` - DISTRIB_CODENAME=`lsb_release -sc` - DISTRIB_DESCRIPTION=`lsb_release -sd` -fi -echo "----- OS INFO -----" -echo DISTRIB_ID: ${DISTRIB_ID} -echo DISTRIB_RELEASE: ${DISTRIB_RELEASE} -echo DISTRIB_CODENAME: ${DISTRIB_CODENAME} -echo DISTRIB_DESCRIPTION: ${DISTRIB_DESCRIPTION} - -if [[ "$VERSION" == *"-release" ]]; then - # at the time when HC2VPP release packages are being build, - # jvpp release packages are already promoted to release repository. - # Therefore we need to switch to release repository in order to download - # correct jvpp package versions - STREAM="release" -fi - -echo "----- DOWNLOADING PACKAGES -----" -if ! [[ -z ${REPO_NAME} ]]; then - REPO_URL="https://packagecloud.io/fdio/${STREAM}" - echo "REPO_URL: ${REPO_URL}" - if [[ "$DISTRIB_ID" == "Ubuntu" ]]; then - if [[ -f /etc/apt/sources.list.d/99fd.io.list ]];then - echo "Deleting: /etc/apt/sources.list.d/99fd.io.list" - sudo rm /etc/apt/sources.list.d/99fd.io.list - fi - if ! [[ "${STREAM}" == "master" ]]; then - echo "stable branch - clearing all fdio repos. new one will be installed." - sudo rm -f /etc/apt/sources.list.d/fdio_*.list - fi - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.deb.sh | sudo bash - if [[ "${VERSION}" != 'RELEASE' ]]; then - # download specific version if set - echo VERSION: ${VERSION} - apt-get download vpp-api-java=${VERSION} || true - else - # download latest version for specified stream - apt-get download vpp-api-java || true - fi - - elif [[ "$DISTRIB_ID" == "CentOS" ]]; then - if [[ -f /etc/yum.repos.d/fdio-master.repo ]]; then - echo "Deleting: /etc/yum.repos.d/fdio-master.repo" - sudo rm /etc/yum.repos.d/fdio-master.repo - fi - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.rpm.sh | sudo bash - if [[ "${VERSION}" != 'RELEASE' ]]; then - # download specific version if set - echo VERSION: ${VERSION} - yumdownloader vpp-api-java-${VERSION} || true - else - # download latest version for specified stream - yumdownloader vpp-api-java || true - fi - fi -fi - -# install vpp-api-java, this extracts jvpp .jar files into usr/share/java -if [[ "${OS}" == "centos7" ]]; then - sudo rpm --nodeps --install vpp-api-java* -else - sudo dpkg --ignore-depends=vpp,vpp-plugin-core --install vpp-api-java* -fi -sudo rm vpp-api-java* - -# install jvpp jars into maven repo, so that maven picks them up when building hc2vpp -version=`./jvpp/version` - -current_dir=`pwd` -cd /usr/share/java - -for item in jvpp*.jar; do - # Example filename: jvpp-registry-17.01-20161206.125556-1.jar - # ArtifactId = jvpp-registry - # Version = 17.01 - basefile=$(basename -s .jar "$item") - artifactId=$(echo "$basefile" | cut -d '-' -f 1-2) - mvn install:install-file -Dfile=${item} -DgroupId=io.fd.jvpp -DartifactId=${artifactId} -Dversion=${version} -Dpackaging=jar -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -done - -cd ${current_dir} diff --git a/jjb/hc2vpp/include-raw-hc2vpp-pkg-push.sh b/jjb/hc2vpp/include-raw-hc2vpp-pkg-push.sh deleted file mode 100644 index fbf06c029..000000000 --- a/jjb/hc2vpp/include-raw-hc2vpp-pkg-push.sh +++ /dev/null @@ -1,83 +0,0 @@ -#!/bin/bash -set -x - -# In case of master branch, update vpp_dependencies file -# to match vpp-api-java and eliminate Java API mismatches (HC2VPP-102). -# -# In order to have control of package dependencies in the release artifacts (HC2VPP-282), -# the vpp_dependencies file is not modified in case of stable branch -# (after VPP API freeze, Java API mismatches occur very rarely). -if [[ "${STREAM}" == "master" ]]; then - if [[ "${OS}" == "centos7" ]]; then - # Determine VPP Java API version used in maven build - JVPP_VERSION=`yum list installed vpp-api-java | grep vpp-api-java | awk '{ printf $2; }'` - VERSION=`yum deplist vpp-api-java |grep vpp-lib |head -1 | awk '{ print $3}'` - - # Write a file that will echo VPP dependencies - echo -n 'echo' > vpp_dependencies - echo " \"vpp = ${VERSION}, vpp-plugins = ${VERSION}, vpp-api-java = ${JVPP_VERSION}\"" >> vpp_dependencies - chmod +x vpp_dependencies - - # Overwrite default dependencies file - mv vpp_dependencies packaging/rpm/ - else - # Determine VPP Java API version used in maven build - JVPP_VERSION=`apt list --installed | grep vpp-api-java | awk '{ printf $2; }'` - # get vpp-api-java package dependencies - JVPP_DEPS=`apt-cache show vpp-api-java=${JVPP_VERSION} |grep Depends: | sed "s/Depends: //"` - # separate deps with newline, then find VPP dependency and filter out the version - VERSION=`echo ${JVPP_DEPS}| sed "s/, /\\n/" |grep "vpp " | sed "s/).*//" |sed "s/.* //"` - - # Write a file that will echo VPP dependencies - echo -n 'echo' > vpp_dependencies - echo " \"vpp (= ${VERSION}), vpp-plugin-core (= ${VERSION}), vpp-api-java (= ${JVPP_VERSION})\"" >> vpp_dependencies - chmod +x vpp_dependencies - - # Overwrite default dependencies file - mv vpp_dependencies packaging/deb/common/ - fi -fi - -# Build package -if [[ "${OS}" == "centos7" ]]; then - - # Build the rpms - ./packaging/rpm/rpmbuild.sh - - # Find the files - RPMS=$(find ./packaging/ -type f -iname '*.rpm') - SRPMS=$(find ./packaging/ -type f -iname '*.srpm') - SRCRPMS=$(find ./packaging/ -type f -name '*.src.rpm') - - # Publish hc2vpp packages - for i in ${RPMS} ${SRPMS} ${SRCRPMS} - do - push_rpm "$i" - done -elif [[ "${OS}" == "ubuntu1604" ]]; then - - # Build the debs - ./packaging/deb/xenial/debuild.sh - - # Find the files - DEBS=$(find ./packaging/ -type f -iname '*.deb') - - # Publish hc2vpp packages - for i in ${DEBS} - do - push_deb "$i" - done -elif [[ "${OS}" == "ubuntu1804" ]]; then - - # Build the debs - ./packaging/deb/bionic/debuild.sh - - # Find the files - DEBS=$(find ./packaging/ -type f -iname '*.deb') - - # Publish hc2vpp packages - for i in ${DEBS} - do - push_deb "$i" - done -fi diff --git a/jjb/hicn/hicn-docs.yaml b/jjb/hicn/hicn-docs.yaml index eec3533f5..c865faa34 100644 --- a/jjb/hicn/hicn-docs.yaml +++ b/jjb/hicn/hicn-docs.yaml @@ -2,156 +2,127 @@ - project: name: hicn-docs jobs: - - 'hicn-docs-merge-{stream}' - - 'hicn-docs-verify-{stream}' - - project: 'hicn' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' + - "hicn-docs-verify-{stream}-{os}-{executor-arch}" + - "hicn-docs-merge-{stream}-{os}-{executor-arch}" + project: "hicn" + os: ubuntu2004 + executor-arch: "x86_64" stream: - - master: - branch: 'master' - repo-stream-part: 'master' + - "master": + branch: "master" + repo: "hicn" + branch-refspec: "" + - "2210": + branch: "stable/2210" + repo: "2210" + branch-refspec: "" type: - short - long - job-template: - name: 'hicn-docs-verify-{stream}' + name: "hicn-docs-verify-{stream}-{os}-{executor-arch}" project-type: freestyle - node: ubuntu1804-us + node: "builder-{os}-prod-{executor-arch}" concurrent: true - archive-artifacts: - - '**/build-doxygen/lib/doc/html/*' - - '**/docs/build/html' - allow-empty: 'true' + allow-empty: "true" fingerprint: false only-if-success: true default-excludes: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: - project: '{project}' + project: "{project}" - gerrit-parameter: - branch: '{branch}' + branch: "{branch}" + - gerrit-refspec-parameter: + refspec: "{branch-refspec}" - os-parameter: - os: 'ubuntu1804' - - maven-exec: - maven-version: 'mvn33-new' + os: "{os}" - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + stream: "{repo}" scm: - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' + credentials-id: "jenkins-gerrit-credentials" + refspec: "$GERRIT_REFSPEC" + choosing-strategy: "gerrit" wrappers: - fdio-infra-wrappers: - build-timeout: '{build-timeout}' + build-timeout: "{build-timeout}" triggers: - - gerrit-trigger-checkstyle: - name: '{project}' - branch: '{branch}' + - gerrit-trigger-checkstyle-nonvoting: + name: "{project}" + branch: "{branch}" builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'hicn-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'hicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: include-raw-hicn-docs.sh + - shell: !include-raw-escape: ../scripts/setup_executor_env.sh + - shell: !include-raw-escape: ../scripts/hicn/docs.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 + - fdio-infra-publish-docs-7day + - fdio-infra-publish - job-template: - name: 'hicn-docs-merge-{stream}' + name: "hicn-docs-merge-{stream}-{os}-{executor-arch}" project-type: freestyle - node: ubuntu1804-us + node: "builder-{os}-prod-{executor-arch}" concurrent: false - archive-artifacts: - - '**/build-doxygen/lib/doc/html/*' - - '**/docs/build/html' - allow-empty: 'true' + allow-empty: "true" fingerprint: false only-if-success: true default-excludes: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: - project: '{project}' + project: "{project}" - gerrit-parameter: - branch: '{branch}' + branch: "{branch}" + - gerrit-refspec-parameter: + refspec: "{branch-refspec}" - os-parameter: - os: 'ubuntu1804' - - maven-exec: - maven-version: 'mvn33-new' + os: "{os}" - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + stream: "{repo}" scm: - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' + credentials-id: "jenkins-gerrit-credentials" + refspec: "" + choosing-strategy: "default" wrappers: - fdio-infra-wrappers: - build-timeout: '{build-timeout}' + build-timeout: "{build-timeout}" triggers: - reverse: - jobs: 'hicn-merge-{stream}-ubuntu1804' - result: 'success' + jobs: "hicn-merge-{stream}-{os}-{executor-arch}" + result: "success" - gerrit: - server-name: 'Primary' + server-name: "Primary" trigger-on: - comment-added-contains-event: - comment-contains-value: 'run-docs' + comment-contains-value: "run-docs" projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' + - project-compare-type: "ANT" + project-pattern: "{project}" branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' + - branch-compare-type: "ANT" + branch-pattern: "**/{branch}" skip-vote: successful: true failed: true @@ -159,23 +130,9 @@ notbuilt: true builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'hicn-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'hicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: include-raw-hicn-docs.sh + - shell: !include-raw-escape: ../scripts/setup_executor_env.sh + - shell: !include-raw-escape: ../scripts/hicn/docs.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 + - fdio-infra-publish-docs + - fdio-infra-publish diff --git a/jjb/hicn/hicn.yaml b/jjb/hicn/hicn.yaml index 4f6f18f9c..843d85295 100644 --- a/jjb/hicn/hicn.yaml +++ b/jjb/hicn/hicn.yaml @@ -1,145 +1,120 @@ +# Copyright (c) 2021 Cisco and/or its affiliates. +# 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. + --- - project: - name: hicn-verify + name: hicn-x86_64 jobs: - - 'hicn-verify-{stream}-{os}' - - project: 'hicn' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - centos7: - repo-os-part: 'centos7' - + - "hicn-verify-build-{stream}-{os}-{executor-arch}" + - "hicn-verify-functest-{stream}-{os}-{executor-arch}" + - "hicn-merge-{stream}-{os}-{executor-arch}" + project: "hicn" + os: ubuntu2004 + executor-arch: "x86_64" stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - lightng: - branch: 'hicn-light-ng' - repo-stream-part: 'hicn-light-ng' - - type: - - short - - long + - "master": + branch: "master" + repo: "hicn" + - "2210": + branch: "stable/2210" + repo: "2210" - project: - name: hicn-merge + name: hicn-aarch64 jobs: - - 'hicn-merge-{stream}-{os}' - - project: 'hicn' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - centos7: - repo-os-part: 'centos7' - + - "hicn-verify-build-{stream}-{os}-{executor-arch}" + - "hicn-merge-{stream}-{os}-{executor-arch}" + project: "hicn" + os: ubuntu2004 + executor-arch: "aarch64" stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - type: - - short - - long + - "master": + branch: "master" + repo: "hicn" + - "2210": + branch: "stable/2210" + repo: "2210" - project: - name: hicn-arm-verify + name: hicn-misc jobs: - - 'hicn-arm-verify-{stream}-{os}' - - project: 'hicn' - os: - - ubuntu1804: - repo-os-part: 'ubuntu-arm.bionic.main' - + - "hicn-checkstyle-verify-{stream}-{os}-{executor-arch}" + project: "hicn" stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - lightng: - branch: 'hicn-light-ng' - repo-stream-part: 'hicn-light-ng' - - type: - - short - - long + - "master": + branch: "master" + repo: "hicn" + - "2210": + branch: "stable/2210" + repo: "2210" + os: ubuntu2004 + executor-arch: "x86_64" - project: - name: hicn-arm-merge + name: hicn-extras-x86_64 jobs: - - 'hicn-arm-merge-{stream}-{os}' - - project: 'hicn' - os: - - ubuntu1804: - repo-os-part: 'ubuntu-arm.bionic.main' - + - "hicn-extras-verify-{stream}-{os}-{executor-arch}" + - "hicn-extras-build-{stream}-{os}-{executor-arch}" + project: "hicn" + os: ubuntu2004 + executor-arch: "x86_64" stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - type: - - short - - long + - "master": + branch: "master" + repo: "hicn" + - "2210": + branch: "stable/2210" + repo: "2210" - project: - name: hicn-misc + name: hicn-extras-aarch64 jobs: - - 'hicn-checkstyle-verify-{stream}' - project: 'hicn' + - "hicn-extras-verify-{stream}-{os}-{executor-arch}" + - "hicn-extras-build-{stream}-{os}-{executor-arch}" + project: "hicn" + os: ubuntu2004 + executor-arch: "aarch64" stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - lightng: - branch: 'hicn-light-ng' - repo-stream-part: 'hicn-light-ng' - os: ubuntu1804 + - "master": + branch: "master" + repo: "hicn" + - "2210": + branch: "stable/2210" + repo: "2210" - project: - name: hicn-extras + name: hicn-vpp-latest-x86_64 jobs: - - 'hicn-extras-verify-{stream}-{os}' - - 'hicn-extras-build-{stream}-{os}' - project: 'hicn' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - centos7: - repo-os-part: 'centos7' - + - "hicn-vpp-latest-verify-{stream}-{os}-{executor-arch}" + project: "hicn" + os: ubuntu2004 + executor-arch: "x86_64" stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - type: - - short - - long + - "master": + branch: "master" + repo: "hicn" - project: - name: hicn-extras-arm + name: hicn-vpp-latest-aarch64 jobs: - - 'hicn-extras-arm-verify-{stream}-{os}' - - 'hicn-extras-arm-build-{stream}-{os}' - - project: 'hicn' - os: - - ubuntu1804: - repo-os-part: 'ubuntu-arm.bionic.main' - + - "hicn-vpp-latest-verify-{stream}-{os}-{executor-arch}" + project: "hicn" + os: ubuntu2004 + executor-arch: "aarch64" stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - type: - - short - - long - + - "master": + branch: "master" + repo: "hicn" - project: name: hicn-view @@ -147,79 +122,127 @@ - project-view project-name: hicn +- project: + name: hicn-sonar + jobs: + - "hicn-sonar-scanner-{stream}" + project: hicn + sonarcloud: true + sonarcloud-project-organization: "{sonarcloud_project_organization}" + sonarcloud-api-token: "{sonarcloud_api_token}" + sonarcloud-project-key: "{sonarcloud_project_organization}-{project}" + stream: + - "master": + branch: "master" + repo: "hicn" + - "2210": + branch: "stable/2210" + repo: "2210" + - job-template: - name: 'hicn-checkstyle-verify-{stream}' + name: "hicn-sonar-scanner-{stream}" project-type: freestyle - node: '{os}-us' + node: centos7-docker-4c-4g concurrent: true - archive-artifacts: '**/tmp/hicn-failed-unittests/*/* **/core' - build-discarder: - 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}" + - stream-parameter: + stream: "{repo}" + + scm: + - gerrit-trigger-scm: + credentials-id: "jenkins-gerrit-credentials" + refspec: "" + choosing-strategy: "default" + + wrappers: + - fdio-infra-wrappers: + build-timeout: "{build-timeout}" + + triggers: + - gerrit-trigger-patch-merged: + name: "{project}" + branch: "{branch}" + + builders: + - inject: + properties-content: | + SONAR_HOST_URL=https://sonarcloud.io + PROJECT_KEY={sonarcloud-project-key} + PROJECT_ORGANIZATION={sonarcloud-project-organization} + API_TOKEN={sonarcloud-api-token} + - shell: !include-raw-escape: + - ../scripts/hicn/sonar.sh + +- job-template: + name: "hicn-checkstyle-verify-{stream}-{os}-{executor-arch}" + + project-type: freestyle + node: "builder-{os}-prod-{executor-arch}" + concurrent: true + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: - project: '{project}' + project: "{project}" - gerrit-parameter: - branch: '{branch}' + branch: "{branch}" - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.ubuntu.bionic.main' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + os: "{os}" scm: - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' + credentials-id: "jenkins-gerrit-credentials" + refspec: "$GERRIT_REFSPEC" + choosing-strategy: "gerrit" wrappers: - fdio-infra-wrappers: - build-timeout: '{build-timeout}' + build-timeout: "{build-timeout}" triggers: - gerrit: - server-name: 'Primary' + server-name: "Primary" trigger-on: - patchset-created-event: - exclude-drafts: 'true' - exclude-trivial-rebase: 'false' - exclude-no-code-change: 'true' + exclude-drafts: "true" + exclude-trivial-rebase: "false" + exclude-no-code-change: "true" - draft-published-event - comment-added-contains-event: - comment-contains-value: 'checkstylecheck' + comment-contains-value: "checkstylecheck" - comment-added-contains-event: - comment-contains-value: 'docsonly' + comment-contains-value: "docsonly" - comment-added-contains-event: - comment-contains-value: 'recheck' + comment-contains-value: "recheck" - comment-added-contains-event: - comment-contains-value: 'reverify' + comment-contains-value: "reverify" projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' + - project-compare-type: "ANT" + project-pattern: "{project}" branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' + - branch-compare-type: "ANT" + branch-pattern: "**/{branch}" file-paths: - compare-type: REG_EXP pattern: ^((?!\/COMMIT_MSG|docs|_abc|_def[\/\.]).)*$ - disable-strict-forbidden-file-verification: 'true' + disable-strict-forbidden-file-verification: "true" override-votes: true gerrit-build-notbuilt-verified-value: 0 gerrit-build-successful-verified-value: 1 # yamllint disable-line rule:line-length - notbuilt-message: 'Automatic retry of failed jobs may be in process. A proper vote should be set when retry completes.' + notbuilt-message: "Automatic retry of failed jobs may be in process. A proper vote should be set when retry completes." # yamllint disable-line rule:line-length - failed-message: 'Checkstyle failed. No further verify jobs will be started.' - successful-message: 'checkstyle_success' + failed-message: "Checkstyle failed. No further verify jobs will be started." + successful-message: "checkstyle_success" skip-vote: successful: true failed: false @@ -227,355 +250,236 @@ notbuilt: false builders: - - shell: - !include-raw-escape: include-raw-hicn-checkstyle.sh + - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: !include-raw-escape: + - ../scripts/hicn/checkstyle.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish - naginator: rerun-unstable-builds: true max-failed-builds: 1 fixed-delay: 90 - job-template: - name: 'hicn-verify-{stream}-{os}' + name: "hicn-verify-build-{stream}-{os}-{executor-arch}" project-type: freestyle - node: '{os}-us' + node: "builder-{os}-prod-{executor-arch}" concurrent: true - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: - project: '{project}' + project: "{project}" - gerrit-parameter: - branch: '{branch}' + branch: "{branch}" - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' + os: "{os}" - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + stream: "{repo}" scm: - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' + credentials-id: "jenkins-gerrit-credentials" + refspec: "$GERRIT_REFSPEC" + choosing-strategy: "gerrit" wrappers: - fdio-infra-wrappers: build-timeout: 120 triggers: - - gerrit-trigger-checkstyle: - name: '{project}' - branch: '{branch}' + - gerrit: + server-name: "Primary" + trigger-on: + - comment-added-contains-event: + comment-contains-value: "checkstyle_success" + projects: + - project-compare-type: "ANT" + project-pattern: "{project}" + branches: + - branch-compare-type: "ANT" + branch-pattern: "**/{branch}" + # yamllint disable-line rule:line-length + notbuilt-message: "Automatic retry of failed jobs may be in process. A proper vote should be set when retry completes." + # yamllint disable-line rule:line-length + failed-message: "Build failed. No further verify jobs will be started." + successful-message: "build_success-{stream}-{os}-{executor-arch}" + skip-vote: + successful: true + failed: true + unstable: true + notbuilt: true + override-votes: true + gerrit-build-successful-verified-value: 1 + gerrit-build-failed-verified-value: 1 + gerrit-build-unstable-verified-value: 1 + gerrit-build-notbuilt-verified-value: 1 builders: - - shell: - !include-raw-escape: - - include-raw-hicn-build.sh + - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: !include-raw-escape: + - ../scripts/hicn/build.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 2 - fixed-delay: 90 + - fdio-infra-publish + - archive-artifacts: + artifacts: "packages/*.deb, packages/*.rpm" + - xunit: + thresholdmode: "percent" + thresholds: + - failed: + failure: 0 + types: + - gtest: + pattern: "**/reports/*report.xml" - job-template: - name: 'hicn-arm-verify-{stream}-{os}' + name: "hicn-verify-functest-{stream}-{os}-{executor-arch}" project-type: freestyle - node: '{os}arm-us' + node: "ubuntu2004-docker-4c-4g" concurrent: true - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: - project: '{project}' + project: "{project}" - gerrit-parameter: - branch: '{branch}' + branch: "{branch}" - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' + os: "{os}" - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + stream: "{repo}" scm: - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' + credentials-id: "jenkins-gerrit-credentials" + refspec: "$GERRIT_REFSPEC" + choosing-strategy: "gerrit" wrappers: - fdio-infra-wrappers: build-timeout: 120 triggers: - - gerrit-trigger-checkstyle: - name: '{project}' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: - - include-raw-hicn-build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 - -- job-template: - name: 'hicn-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-us' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' - - stream-parameter: - stream: 'hicn' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' + - gerrit-trigger-build: + name: "{project}" + branch: "{branch}" + stream: "{stream}" + os: "{os}" + executor-arch: "{executor-arch}" builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root/.packagecloud' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root/packagecloud_api' - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'hicn-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - shell: - !include-raw-escape: - - include-raw-hicn-checkstyle.sh - - shell: - !include-raw-escape: - - include-raw-hicn-build.sh - - provide-maven-settings: - settings-file: 'hicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-hicn-maven-push.sh + - shell: !include-raw-escape: + - ../scripts/hicn/functest.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 + - robot: + output-path: "tests" + pass-threshold: 75.0 + only-critical: false + - fdio-infra-publish - job-template: - name: 'hicn-arm-merge-{stream}-{os}' + name: "hicn-merge-{stream}-{os}-{executor-arch}" project-type: freestyle - node: '{os}arm-us' + node: "builder-{os}-prod-{executor-arch}" - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: - project: '{project}' + project: "{project}" - gerrit-parameter: - branch: '{branch}' + branch: "{branch}" - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' + os: "{os}" - stream-parameter: - stream: 'hicn' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + stream: "{stream}" scm: - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' + credentials-id: "jenkins-gerrit-credentials" + refspec: "" + choosing-strategy: "default" wrappers: - fdio-infra-wrappers: - build-timeout: '{build-timeout}' + build-timeout: "{build-timeout}" triggers: - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' + name: "{project}" + branch: "{branch}" builders: - config-file-provider: files: - - file-id: '.packagecloud' - target: '/root' + - file-id: ".packagecloud" + target: "/root/.packagecloud" - config-file-provider: files: - - file-id: 'packagecloud_api' - target: '/root' - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'hicn-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - shell: - !include-raw-escape: - - include-raw-hicn-checkstyle.sh - - shell: - !include-raw-escape: - - include-raw-hicn-build.sh - - provide-maven-settings: - settings-file: 'hicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: + - file-id: "packagecloud_api" + target: "/root/packagecloud_api" + - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: !include-raw-escape: + - ../scripts/hicn/checkstyle.sh + - shell: !include-raw-escape: + - ../scripts/hicn/build.sh + - shell: !include-raw-escape: - ../scripts/packagecloud_push.sh - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-hicn-maven-push.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 - -- project: - name: hicn-sonar - project: hicn - project-name: hicn - mvn-settings: hicn-settings - sonarcloud: true - sonarcloud-project-organization: '{sonarcloud_project_organization}' - sonarcloud-api-token: '{sonarcloud_api_token}' - sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}' - branch: master - build-node: centos7-docker-2c-2g - jobs: - - gerrit-maven-sonar + - fdio-infra-publish + - xunit: + thresholdmode: "percent" + thresholds: + - failed: + failure: 0 + types: + - gtest: + pattern: "**/reports/*report.xml" - job-template: - name: 'hicn-extras-verify-{stream}-{os}' + name: "hicn-extras-verify-{stream}-{os}-{executor-arch}" project-type: freestyle - node: '{os}-us' + node: "builder-{os}-prod-{executor-arch}" concurrent: true - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: - project: '{project}' + project: "{project}" - gerrit-parameter: - branch: '{branch}' + branch: "{branch}" - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' + os: "{os}" - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + stream: "{repo}" scm: - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' + credentials-id: "jenkins-gerrit-credentials" + refspec: "$GERRIT_REFSPEC" + choosing-strategy: "gerrit" wrappers: - fdio-infra-wrappers: @@ -583,279 +487,134 @@ triggers: - gerrit: - server-name: 'Primary' + server-name: "Primary" trigger-on: - comment-added-contains-event: - comment-contains-value: 'verify-extras' + comment-contains-value: "verify-extras" projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' + - project-compare-type: "ANT" + project-pattern: "{project}" branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' + - branch-compare-type: "ANT" + branch-pattern: "**/{branch}" builders: - - shell: - !include-raw-escape: - - include-raw-hicn-extras-build.sh + - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: !include-raw-escape: + - ../scripts/hicn/build-extras.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 2 - fixed-delay: 90 + - fdio-infra-publish - job-template: - name: 'hicn-extras-build-{stream}-{os}' + name: "hicn-extras-build-{stream}-{os}-{executor-arch}" project-type: freestyle - node: '{os}-us' + node: "builder-{os}-prod-{executor-arch}" - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: - project: '{project}' + project: "{project}" - gerrit-parameter: - branch: '{branch}' + branch: "{branch}" - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' + os: "{os}" - stream-parameter: - stream: 'hicn' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + stream: "{repo}" scm: - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' + credentials-id: "jenkins-gerrit-credentials" + refspec: "" + choosing-strategy: "default" wrappers: - fdio-infra-wrappers: - build-timeout: '{build-timeout}' + build-timeout: "{build-timeout}" triggers: - gerrit: - server-name: 'Primary' + server-name: "Primary" trigger-on: - comment-added-contains-event: - comment-contains-value: 'build-extras' + comment-contains-value: "build-extras" projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' + - project-compare-type: "ANT" + project-pattern: "{project}" branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' + - branch-compare-type: "ANT" + branch-pattern: "**/{branch}" builders: - config-file-provider: files: - - file-id: '.packagecloud' - target: '/root/.packagecloud' + - file-id: ".packagecloud" + target: "/root/.packagecloud" - config-file-provider: files: - - file-id: 'packagecloud_api' - target: '/root/packagecloud_api' - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'hicn-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - shell: - !include-raw-escape: - - include-raw-hicn-extras-build.sh - - provide-maven-settings: - settings-file: 'hicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: + - file-id: "packagecloud_api" + target: "/root/packagecloud_api" + - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: !include-raw-escape: + - ../scripts/hicn/build-extras.sh + - shell: !include-raw-escape: - ../scripts/packagecloud_push.sh - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-hicn-maven-push.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 + - fdio-infra-publish - job-template: - name: 'hicn-extras-arm-verify-{stream}-{os}' + name: "hicn-vpp-latest-verify-{stream}-{os}-{executor-arch}" project-type: freestyle - node: '{os}arm-us' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'verify-extras' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - - builders: - - shell: - !include-raw-escape: - - include-raw-hicn-extras-build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 - -- job-template: - name: 'hicn-extras-arm-build-{stream}-{os}' - - project-type: freestyle - node: '{os}arm-us' + node: "builder-{os}-prod-{executor-arch}" + concurrent: true - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: - project: '{project}' + project: "{project}" - gerrit-parameter: - branch: '{branch}' + branch: "{branch}" - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' + os: "{os}" - stream-parameter: - stream: 'hicn' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + stream: "{repo}" scm: - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' + credentials-id: "jenkins-gerrit-credentials" + refspec: "$GERRIT_REFSPEC" + choosing-strategy: "gerrit" wrappers: - fdio-infra-wrappers: - build-timeout: '{build-timeout}' + build-timeout: 120 triggers: - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'build-extras' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' + - timed: "H H * * *" + - gerrit-trigger-manually-triggered: + comment-trigger-value: "verify-vpp-latest" + name: "{project}" + branch: "{branch}" builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root/.packagecloud' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root/packagecloud_api' - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'hicn-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - shell: - !include-raw-escape: - - include-raw-hicn-extras-build.sh - - provide-maven-settings: - settings-file: 'hicn-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-hicn-maven-push.sh + - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: !include-raw-escape: + - ../scripts/hicn/build-vpp-latest.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 + - fdio-infra-publish - project: name: hicn-info diff --git a/jjb/hicn/include-raw-hicn-docs.sh b/jjb/hicn/include-raw-hicn-docs.sh deleted file mode 100644 index f90c8fe8d..000000000 --- a/jjb/hicn/include-raw-hicn-docs.sh +++ /dev/null @@ -1,54 +0,0 @@ -#!/bin/bash -set -xe -o pipefail - -[ "$DOCS_REPO_URL" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site" -[ "$PROJECT_PATH" ] || PROJECT_PATH="io/fd/hicn" -[ "$DOC_FILE" ] || DOC_FILE="hicn.docs.zip" -[ "$DOC_DIR" ] || DOC_DIR="build-doxygen/lib/doc/html" -[ "$SITE_DIR" ] || SITE_DIR="build/doc/deploy-site/" -[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" -[ "$VERSION" ] || VERSION=$(git describe --abbrev=0 | egrep -o "([0-9]{1,}\.)+[0-9]{1,}") - -echo "Current directory: $(pwd)" - -bash scripts/build-packages.sh sphinx -bash scripts/build-packages.sh doxygen - -if [[ ${JOB_NAME} == *merge* ]]; then - mkdir -p $(dirname ${RESOURCES_DIR}) - mv -f ${DOC_DIR} ${RESOURCES_DIR} - cd ${SITE_DIR} - find . -type f '(' -name '*.md5' -o -name '*.dot' -o -name '*.map' ')' -delete - cat > pom.xml << EOF - <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>io.fd.hicn</groupId> - <artifactId>docs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> - - <properties> - <generateReports>false</generateReports> - </properties> - - <build> - <extensions> - <extension> - <groupId>org.apache.maven.wagon</groupId> - <artifactId>wagon-webdav-jackrabbit</artifactId> - <version>2.10</version> - </extension> - </extensions> - </build> - <distributionManagement> - <site> - <id>fdio-site</id> - <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/${VERSION}</url> - </site> - </distributionManagement> - </project> -EOF - ${MVN} -B site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C - cd - -fi diff --git a/jjb/hicn/include-raw-hicn-maven-push.sh b/jjb/hicn/include-raw-hicn-maven-push.sh deleted file mode 100644 index 6e3c9a86e..000000000 --- a/jjb/hicn/include-raw-hicn-maven-push.sh +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/bash -set -xe -o pipefail -echo "*******************************************************************" -echo "* STARTING PUSH OF PACKAGES TO REPOS" -echo "* NOTHING THAT HAPPENS BELOW THIS POINT IS RELATED TO BUILD FAILURE" -echo "*******************************************************************" - -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" -GROUP_ID="io.fd.${PROJECT}" -BASEURL="${NEXUSPROXY}/content/repositories/fd.io." -BASEREPOID='fdio-' - -if [ "${OS}" == "ubuntu1604" ]; then - # Find the files - JARS=$(find . -type f -iname '*.jar') - DEBS=$(find . -type f -iname '*.deb') - for i in $JARS - do - push_jar "$i" - done - - for i in $DEBS - do - push_deb "$i" - done -elif [ "${OS}" == "ubuntu1804" ]; then - # Find the files - JARS=$(find . -type f -iname '*.jar') - DEBS=$(find . -type f -iname '*.deb') - for i in $JARS - do - push_jar "$i" - done - - for i in $DEBS - do - push_deb "$i" - done -elif [ "${OS}" == "centos7" ]; then - # Find the files - RPMS=$(find . -type f -iname '*.rpm') - SRPMS=$(find . -type f -iname '*.srpm') - SRCRPMS=$(find . -type f -name '*.src.rpm') - for i in $RPMS $SRPMS $SRCRPMS - do - push_rpm "$i" - done -fi diff --git a/jjb/honeycomb/honeycomb.yaml b/jjb/honeycomb/honeycomb.yaml deleted file mode 100644 index e088d5478..000000000 --- a/jjb/honeycomb/honeycomb.yaml +++ /dev/null @@ -1,305 +0,0 @@ ---- -- project: - name: honeycomb - jobs: - - 'honeycomb-verify-{stream}-{os}' - - 'honeycomb-merge-{stream}-{os}' - - 'honeycomb-benchmark-master-{os}' - project: 'honeycomb' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - '1810': - branch: 'stable/1810' - repo-stream-part: 'stable.1810' - - '1901': - branch: 'stable/1901' - repo-stream-part: 'stable.1901' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - -- project: - name: honeycomb-view - views: - - project-view - project-name: honeycomb - -- job-template: - name: 'honeycomb-verify-{stream}-{os}' - project-type: maven - node: '{os}-builder-4c-4g' - concurrent: true - jdk: openjdk8-{os} - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: 'honeycomb' - branch: '{branch}' - - maven: - maven-name: 'mvn36' - root-pom: 'pom.xml' - # yamllint disable-line rule:line-length - goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dmerge site' - maven-opts: '-Xmx2048m -Dmaven.compile.fork=true' - settings: 'honeycomb-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - publishers: - - email-notification: - email-prefix: '[honeycomb]' - - lf-infra-publish - -- job-template: - name: 'honeycomb-merge-{stream}-{os}' - project-type: maven - node: '{os}-builder-4c-4g' - jdk: openjdk8-{os} - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn36' - - maven-exec: - maven-version: 'mvn36' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - ssh-agent-credentials: - users: - - 'jenkins-gerrit-credentials' - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: 'honeycomb' - branch: '{branch}' - - maven: - maven-name: 'mvn36' - root-pom: 'pom.xml' - # yamllint disable-line rule:line-length - goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dmerge -Dsonar site site:deploy' - maven-opts: '-Xmx2048m -Dmaven.compile.fork=true' - settings: 'honeycomb-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - postbuilders: - - maven-target: - maven-version: 'mvn36' - goals: '--version' - settings: 'honeycomb-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'honeycomb-settings' - global-settings-file: 'global-settings' - - reporters: - - findbugs - - publishers: - - sonar: - jdk: 'openjdk8-{os}' - language: 'java' - branch: '{stream}' - - email-notification: - email-prefix: '[honeycomb]' - - maven-deploy: - id: '' - unique-version: true - deploy-unstable: false - - lf-infra-publish - -- job-template: - name: 'honeycomb-benchmark-master-{os}' - project-type: maven - node: '{os}-builder-4c-4g' - jdk: openjdk8-{os} - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn36' - - maven-exec: - maven-version: 'mvn36' - - repo-name-parameter: - repo-name: 'master.{repo-os-part}' - - scm: - - git-scm: - credentials-id: 'jenkins-gerrit-credentials' - branch: 'master' - - wrappers: - - ssh-agent-credentials: - users: - - 'jenkins-gerrit-credentials' - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - timed: '@daily' - - maven: - maven-name: 'mvn36' - root-pom: 'pom.xml' - # yamllint disable-line rule:line-length - goals: 'clean install -V -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dmerge -Pbenchmark' - maven-opts: '-Xmx2048m -Dmaven.compile.fork=true' - settings: 'honeycomb-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - publishers: - - plot: - - title: 'Infrastructure CFG write benchmark (simple-container)' - yaxis: 'ops/second' - csv-file-name: 'simple-container.csv' - group: 'infra-bench' - keep-records: true - numbuilds: '20' - style: 'line' - use-description: false - series: - - file: 'infra/it/benchmark/target/simple-container.csv' - display-table: true - format: 'csv' - inclusion-flag: 'include-by-string' - # yamllint disable-line rule:line-length - exclude: 'persistence=true freq=1,persistence=true freq=10,persistence=false freq=1,persistence=false freq=10' - - title: 'Infrastructure CFG write benchmark (list-in-container)' - yaxis: 'ops/second' - csv-file-name: 'list-in-container.csv' - group: 'infra-bench' - keep-records: true - numbuilds: '20' - style: 'line' - use-description: false - series: - - file: 'infra/it/benchmark/target/list-in-container.csv' - display-table: true - format: 'csv' - inclusion-flag: 'include-by-string' - # yamllint disable-line rule:line-length - exclude: 'persistence=true freq=1,persistence=true freq=10,persistence=false freq=1,persistence=false freq=10' - # yamllint disable-line rule:line-length - - title: 'Infrastructure CFG write benchmark (complex-list-in-container)' - yaxis: 'ops/second' - csv-file-name: 'complex-list-in-container.csv' - group: 'infra-bench' - keep-records: true - numbuilds: '20' - style: 'line' - use-description: false - series: - - file: 'infra/it/benchmark/target/complex-list-in-container.csv' - display-table: true - format: 'csv' - inclusion-flag: 'include-by-string' - # yamllint disable-line rule:line-length - exclude: 'persistence=true freq=1,persistence=true freq=10,persistence=false freq=1,persistence=false freq=10' - - title: 'Infrastructure CFG read benchmark' - yaxis: 'ops/second' - csv-file-name: 'operational-read.csv' - group: 'infra-bench' - keep-records: true - numbuilds: '20' - style: 'line' - use-description: false - series: - - file: 'infra/it/benchmark/target/operational-read.csv' - display-table: true - format: 'csv' - inclusion-flag: 'include-by-string' - # yamllint disable-line rule:line-length - exclude: 'simple-container,list-in-container,complex-list-in-container' - - - lf-infra-publish - -- project: - name: honeycomb-info - project-name: honeycomb - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-2c-2g - project: honeycomb - branch: master - -- project: - name: honeycomb-sonar - project: honeycomb - project-name: honeycomb - mvn-settings: honeycomb-settings - sonarcloud: true - sonarcloud-project-organization: '{sonarcloud_project_organization}' - sonarcloud-api-token: '{sonarcloud_api_token}' - sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}' - branch: master - build-node: centos7-docker-2c-2g - jobs: - - gerrit-maven-sonar diff --git a/jjb/include-raw-deploy-archives.sh b/jjb/include-raw-deploy-archives.sh deleted file mode 100644 index 073aa3e6d..000000000 --- a/jjb/include-raw-deploy-archives.sh +++ /dev/null @@ -1,106 +0,0 @@ -#!/bin/bash - -set +e # Do not affect the build result if some part of archiving fails. - -ARCHIVES_DIR="$JENKINS_HOSTNAME/$JOB_NAME/$BUILD_NUMBER" -[ "$LOGS_SERVER" ] || LOGS_SERVER="https://logs.fd.io" -[ "$LOGS_REPO_URL" ] || LOGS_REPO_URL="https://nexus.fd.io/service/local/repositories/logs" - -echo "Build logs: <a href=\"$LOGS_SERVER/$SILO/$ARCHIVES_DIR\">$LOGS_SERVER/$SILO/$ARCHIVES_DIR</a>" - -mkdir .archives -cd .archives/ - -cat > deploy-archives.xml <<EOF -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>logs</groupId> - <artifactId>logs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> - - <build> - <plugins> - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-deploy-plugin</artifactId> - <version>2.8.2</version> - <configuration> - <skip>true</skip> - </configuration> - </plugin> - <plugin> - <groupId>org.sonatype.plugins</groupId> - <artifactId>maven-upload-plugin</artifactId> - <version>0.0.1</version> - <executions> - <execution> - <id>publish-site</id> - <phase>deploy</phase> - <goals> - <goal>upload-file</goal> - </goals> - <configuration> - <serverId>fdioproject-log-archives</serverId> - <repositoryUrl>$LOGS_REPO_URL/content-compressed</repositoryUrl> - <file>archives.zip</file> - <repositoryPath>$SILO</repositoryPath> - </configuration> - </execution> - </executions> - </plugin> - </plugins> - </build> -</project> -EOF - -mkdir -p $ARCHIVES_DIR -mkdir -p $WORKSPACE/archives -if [ ! -z "${{ARCHIVE_ARTIFACTS}}" ]; then - pushd $WORKSPACE - shopt -s globstar # Enable globstar to copy archives - archive_artifacts=$(echo ${{ARCHIVE_ARTIFACTS}}) - for f in $archive_artifacts; do - echo "Archiving $f" - mkdir -p $WORKSPACE/archives/$(dirname $f) - mv $f $WORKSPACE/archives/$f - done - shopt -u globstar # Disable globstar once archives are copied - popd -fi - - -# Ignore logging if archives doesn't exist -mv $WORKSPACE/archives/ $ARCHIVES_DIR > /dev/null 2>&1 -touch $ARCHIVES_DIR/_build-details.txt -echo "build-url: ${{BUILD_URL}}" >> $ARCHIVES_DIR/_build-details.txt -env > $ARCHIVES_DIR/_build-enviroment-variables.txt - -# capture system info -touch $ARCHIVES_DIR/_sys-info.txt -{{ - echo -e "uname -a:\n `uname -a` \n" - echo -e "df -h:\n `df -h` \n" - echo -e "free -m:\n `free -m` \n" - echo -e "nproc:\n `nproc` \n" - echo -e "lscpu:\n `lscpu` \n" - echo -e "ip addr:\n `/sbin/ip addr` \n" -}} 2>&1 | tee -a $ARCHIVES_DIR/_sys-info.txt - -# Magic string used to trim console logs at the appropriate level during wget -echo "-----END_OF_BUILD-----" -wget -q --timeout=60 -O $ARCHIVES_DIR/console.log ${{BUILD_URL}}consoleText -wget -q --timeout=60 -O $ARCHIVES_DIR/console-timestamp.log ${{BUILD_URL}}/timestamps?time=HH:mm:ss\&appendLog -sed -i '/^-----END_OF_BUILD-----$/,$d' $ARCHIVES_DIR/console.log -sed -i '/^.*-----END_OF_BUILD-----$/,$d' $ARCHIVES_DIR/console-timestamp.log - -gzip $ARCHIVES_DIR/*.txt $ARCHIVES_DIR/*.log -# find and gzip any 'text' files -find $ARCHIVES_DIR -type f -print0 \ - | xargs -0r file \ - | egrep -e ':.*text.*' \ - | cut -d: -f1 \ - | xargs -d'\n' -r gzip - -zip -r archives.zip $JENKINS_HOSTNAME/ -du -sh archives.zip diff --git a/jjb/jvpp/include-raw-jvpp-build.sh b/jjb/jvpp/include-raw-jvpp-build.sh deleted file mode 100755 index 3ccc97e09..000000000 --- a/jjb/jvpp/include-raw-jvpp-build.sh +++ /dev/null @@ -1,57 +0,0 @@ -#!/bin/bash -# basic build script example -set -xe -o pipefail - -OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') -OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') - -echo OS_ID: ${OS_ID} -echo OS_VERSION_ID: ${OS_VERSION_ID} - -# do nothing but print the current slave hostname -hostname -export CCACHE_DIR=/tmp/ccache -if [[ -d ${CCACHE_DIR} ]];then - echo ${CCACHE_DIR} exists - du -sk ${CCACHE_DIR} -else - echo ${CCACHE_DIR} does not exist. This must be a new slave. -fi - -echo "cat /etc/bootstrap.sha" -if [[ -f /etc/bootstrap.sha ]];then - cat /etc/bootstrap.sha -else - echo "Cannot find cat /etc/bootstrap.sha" -fi - -echo "cat /etc/bootstrap-functions.sha" -if [[ -f /etc/bootstrap-functions.sha ]];then - cat /etc/bootstrap-functions.sha -else - echo "Cannot find cat /etc/bootstrap-functions.sha" -fi - -echo "sha1sum of this script: ${0}" -sha1sum $0 - -echo "CC=${CC}" - -echo "Building using \"make package\"" -# ensure that we build from scratch -./clean.sh -[[ "x${DRYRUN}" == "xTrue" ]] || cd Requirements && make UNATTENDED=yes install-dep && cd .. -[[ "x${DRYRUN}" == "xTrue" ]] || pwd -if [[ "${OS_ID}" == "centos" ]]; then - [[ "x${DRYRUN}" == "xTrue" ]] || /opt/rh/devtoolset-7/enable - [[ "x${DRYRUN}" == "xTrue" ]] || cmake3 . -DCMAKE_PROGRAM_PATH:PATH="/opt/rh/devtoolset-7/root/bin" -else - [[ "x${DRYRUN}" == "xTrue" ]] || cmake . -fi - -[[ "x${DRYRUN}" == "xTrue" ]] || make package -# This will build deb or rpm JVPP package based on OS. Built packages are located in build-root/packages/ - -echo "*******************************************************************" -echo "* JVPP BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" diff --git a/jjb/jvpp/include-raw-jvpp-maven-push.sh b/jjb/jvpp/include-raw-jvpp-maven-push.sh deleted file mode 100755 index 9b0c517ad..000000000 --- a/jjb/jvpp/include-raw-jvpp-maven-push.sh +++ /dev/null @@ -1,44 +0,0 @@ -#!/bin/bash -set -xe -o pipefail -echo "*******************************************************************" -echo "* STARTING PUSH OF JVPP PACKAGES TO REPOS" -echo "* NOTHING THAT HAPPENS BELOW THIS POINT IS RELATED TO BUILD FAILURE" -echo "*******************************************************************" - -[[ "$MVN" ]] || MVN="/opt/apache/maven/bin/mvn" -GROUP_ID="io.fd.${PROJECT}" -BASEURL="${NEXUSPROXY}/content/repositories/fd.io." -BASEREPOID='fdio-' - -if [[ "${OS}" == "ubuntu1604" ]]; then - # Find the files - DEBS=$(find ./build-root/packages/ -type f -iname '*.deb') - - for i in ${DEBS} - do - push_deb "$i" - done -elif [[ "${OS}" == "ubuntu1804" ]]; then - # Find the files - JARS=$(find ./java -type f -iname '*.jar') - DEBS=$(find ./build-root/packages/ -type f -iname '*.deb') - for i in ${JARS} - do - push_jar "$i" - done - - for i in ${DEBS} - do - push_deb "$i" - done -elif [[ "${OS}" == "centos7" ]]; then - # Find the files - RPMS=$(find ./build-root/packages/ -type f -iname '*.rpm') - SRPMS=$(find ./build-root/packages/ -type f -iname '*.srpm') - SRCRPMS=$(find ./build-root/packages/ -type f -name '*.src.rpm') - for i in ${RPMS} ${SRPMS} ${SRCRPMS} - do - push_rpm "$i" - done -fi -# vim: ts=4 sw=4 sts=4 et ft=sh : diff --git a/jjb/jvpp/include-raw-jvpp-packetcloud-push.sh b/jjb/jvpp/include-raw-jvpp-packetcloud-push.sh deleted file mode 100755 index 2917606cc..000000000 --- a/jjb/jvpp/include-raw-jvpp-packetcloud-push.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/bash -# PCIO_CO is a Jenkins Global Environment variable - -set -x - -echo "STARTING JVPP PACKAGECLOUD PUSH" - -sleep 10 - -FACTER_OS=$(/usr/bin/facter operatingsystem) - -if [ -f ~/.packagecloud ]; then - case "$FACTER_OS" in - Ubuntu) - FACTER_LSBNAME=$(/usr/bin/facter lsbdistcodename) - DEBS=$(find ./build-root/packages/ -type f -iname '*.deb') - package_cloud push "${PCIO_CO}/${STREAM}/ubuntu/${FACTER_LSBNAME}/main/" ${DEBS} - ;; - CentOS) - FACTER_OSMAJREL=$(/usr/bin/facter operatingsystemmajrelease) - FACTER_ARCH=$(/usr/bin/facter architecture) - RPMS=$(find ./build-root/packages/ -type f -iregex '.*/.*\.\(s\)?rpm') - package_cloud push "${PCIO_CO}/${STREAM}/el/${FACTER_OSMAJREL}/os/${FACTER_ARCH}/" ${RPMS} - ;; - esac -fi diff --git a/jjb/jvpp/jvpp.yaml b/jjb/jvpp/jvpp.yaml deleted file mode 100644 index 034f67f8b..000000000 --- a/jjb/jvpp/jvpp.yaml +++ /dev/null @@ -1,199 +0,0 @@ ---- -- project: - name: jvpp - jobs: - - 'jvpp-verify-{stream}-{os}' - - 'jvpp-merge-{stream}-{os}' - project: 'jvpp' - os: - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - skip-site: 'false' - skip-jar-deploy: 'true' - vpp-job-prefix: '' - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - skip-site: 'false' - skip-jar-deploy: 'false' - vpp-job-prefix: 'beta-' - - centos7: - repo-os-part: 'centos7' - skip-site: 'true' - skip-jar-deploy: 'true' - vpp-job-prefix: '' - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - -- project: - name: jvpp-view - views: - - project-view - project-name: jvpp - -- job-template: - name: 'jvpp-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-us' - concurrent: true - archive-artifacts: '/tmp/vpp-failed-unittests/*/* **/core' - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - lf-update-java-alternatives: - java-version: openjdk11 - - shell: - !include-raw-escape: - - ../scripts/setup_jvpp_dev_env.sh - - include-raw-jvpp-build.sh - - publishers: - - lf-infra-publish - - naginator: - rerun-unstable-builds: false - max-failed-builds: 2 - fixed-delay: 90 - - email-notification: - email-prefix: '[jvpp]' - -- job-template: - name: 'jvpp-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-us' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn36' - - maven-exec: - maven-version: 'mvn36' - - stream-parameter: - stream: '{stream}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - reverse: - jobs: 'vpp-{vpp-job-prefix}merge-{stream}-{os}' - result: 'success' - - builders: - - lf-update-java-alternatives: - java-version: openjdk11 - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - - maven-target: - maven-version: 'mvn36' - goals: '--version' - settings: 'jvpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - shell: - !include-raw-escape: - - ../scripts/setup_jvpp_dev_env.sh - - include-raw-jvpp-build.sh - - provide-maven-settings: - settings-file: 'jvpp-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ./include-raw-jvpp-packetcloud-push.sh - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-jvpp-maven-push.sh - - publishers: - - lf-infra-publish - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 - - email-notification: - email-prefix: '[jvpp]' - -- project: - name: jvpp-info - project-name: jvpp - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-4c-4g - project: jvpp - branch: master diff --git a/jjb/nsh_sfc/include-raw-nsh_sfc-build.sh b/jjb/nsh_sfc/include-raw-nsh_sfc-build.sh deleted file mode 100644 index 98cbbd5a9..000000000 --- a/jjb/nsh_sfc/include-raw-nsh_sfc-build.sh +++ /dev/null @@ -1,44 +0,0 @@ -#!/bin/bash -# basic build script example -set -e -o pipefail -# do nothing but print the current slave hostname -hostname -export CCACHE_DIR=/tmp/ccache -if [ -d $CCACHE_DIR ];then - echo $CCACHE_DIR exists - du -sk $CCACHE_DIR -else - echo $CCACHE_DIR does not exist. This must be a new slave. -fi - -echo "cat /etc/bootstrap.sha" -if [ -f /etc/bootstrap.sha ];then - cat /etc/bootstrap.sha -else - echo "Cannot find /etc/bootstrap.sha" -fi - -echo "cat /etc/bootstrap-functions.sha" -if [ -f /etc/bootstrap-functions.sha ];then - cat /etc/bootstrap-functions.sha -else - echo "Cannot find /etc/bootstrap-functions.sha" -fi - -echo "sha1sum of this script: ${0}" -sha1sum $0 - -if [ -n "${MVN}" ] -then - export MAVEN_HOME=$(dirname ${MVN})/.. -else - export MAVEN_HOME="/opt/apache/maven/" -fi - -export PATH=${MAVEN_HOME}/bin:${PATH} - -scripts/ci/verify.sh - -echo "*******************************************************************" -echo "* NSH_SFC BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" diff --git a/jjb/nsh_sfc/include-raw-nsh_sfc-csit-functional-virl.sh b/jjb/nsh_sfc/include-raw-nsh_sfc-csit-functional-virl.sh deleted file mode 100644 index f2144c29c..000000000 --- a/jjb/nsh_sfc/include-raw-nsh_sfc-csit-functional-virl.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/bash -set -xeu -o pipefail - -# Clone csit and start tests -git clone https://gerrit.fd.io/r/csit - -# If the git clone fails, complain clearly and exit -if [ $? != 0 ]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/csit" - exit 1 -fi - -cd csit - -# execute nsh_sfc bootstrap script if it exists -if [ -e bootstrap-nsh_sfc-functional-virl.sh ] -then - # make sure that bootstrap-nsh_sfc-functional-virl.sh is executable - chmod +x bootstrap-nsh_sfc-functional-virl.sh - # run the script - ./bootstrap-nsh_sfc-functional-virl.sh -else - echo 'ERROR: No bootstrap-nsh_sfc-functional-virl.sh found' - exit 1 -fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/nsh_sfc/include-raw-nsh_sfc-csit-perf-hw.sh b/jjb/nsh_sfc/include-raw-nsh_sfc-csit-perf-hw.sh deleted file mode 100644 index 98b1d070e..000000000 --- a/jjb/nsh_sfc/include-raw-nsh_sfc-csit-perf-hw.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/bash - -set -xeu -o pipefail - -# Clone csit and start tests -git clone https://gerrit.fd.io/r/csit - -# If the git clone fails, complain clearly and exit -if [ $? != 0 ]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/csit" - exit 1 -fi - -cd csit - -# execute nsh_sfc bootstrap script if it exists -if [ ! -e bootstrap-verify-perf-nsh_sfc.sh ] -then - echo 'ERROR: No bootstrap-verify-perf-nsh_sfc.sh found' - exit 1 -fi - -# make sure that bootstrap-verify-perf.sh is executable -chmod +x bootstrap-verify-perf-nsh_sfc.sh -# run the script -./bootstrap-verify-perf-nsh_sfc.sh - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/nsh_sfc/include-raw-nsh_sfc-docs.sh b/jjb/nsh_sfc/include-raw-nsh_sfc-docs.sh deleted file mode 100644 index 119a41d41..000000000 --- a/jjb/nsh_sfc/include-raw-nsh_sfc-docs.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/bash -set -xe -o pipefail -[ "$PROJECT_NAME" ] || PROJECT_NAME="nsh_sfc" -[ "$DOCS_REPO_URL" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site" -[ "$PROJECT_PATH" ] || PROJECT_PATH=io/fd/${PROJECT_NAME} -[ "$DOC_DIR" ] || DOC_DIR=build-root/docs/html -[ "$SITE_DIR" ] || SITE_DIR=build-root/docs/deploy-site/ -[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" -[ "$VERSION" ] || VERSION=$(./nsh-plugin/packaging/scripts/version) - -make doxygen -if [[ ${JOB_NAME} == *merge* ]]; then - mkdir -p $(dirname ${RESOURCES_DIR}) - mv -f ${DOC_DIR} ${RESOURCES_DIR} - cd ${SITE_DIR} - find . -type f '(' -name '*.md5' -o -name '*.dot' -o -name '*.map' ')' -delete - cat > pom.xml << EOF - <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>io.fd.${PROJECT_NAME}</groupId> - <artifactId>docs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> - - <properties> - <generateReports>false</generateReports> - </properties> - - <build> - <extensions> - <extension> - <groupId>org.apache.maven.wagon</groupId> - <artifactId>wagon-webdav-jackrabbit</artifactId> - <version>2.9</version> - </extension> - </extensions> - </build> - <distributionManagement> - <site> - <id>fdio-site</id> - <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/${VERSION}</url> - </site> - </distributionManagement> - </project> -EOF - ${MVN} site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C - cd - -fi diff --git a/jjb/nsh_sfc/include-raw-nsh_sfc-pkg-push.sh b/jjb/nsh_sfc/include-raw-nsh_sfc-pkg-push.sh deleted file mode 100644 index 500433e4c..000000000 --- a/jjb/nsh_sfc/include-raw-nsh_sfc-pkg-push.sh +++ /dev/null @@ -1,44 +0,0 @@ -#!/bin/bash -# basic build script example -set -e -o pipefail -echo "Looking for jars/debs/rpms to publish" -if [ "${OS}" == "ubuntu1604" ]; then - # Find the files - DEBS=$(find . -type f -iname '*.deb') - echo "Found DEBS=${DEBS}" - for i in $DEBS - do - push_deb "$i" - done - - export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64/ - export JAVAC=${JAVA_HOME}/bin/javac - export PATH=${JAVA_HOME}/bin/:${PATH} - cd nsh-plugin/build/java/jvpp - $MVN deploy \ - -gs "$GLOBAL_SETTINGS_FILE" -s "$SETTINGS_FILE" - cd - - -elif [ "${OS}" == "ubuntu1604" ]; then - - # Find the files - DEBS=$(find . -type f -iname '*.deb') - echo "Found DEBS=${DEBS}" - for i in $DEBS - do - push_deb "$i" - done - -elif [ "${OS}" == "centos7" ]; then - # Find the files - RPMS=$(find . -type f -iname '*.rpm') - SRPMS=$(find . -type f -iname '*.srpm') - SRCRPMS=$(find . -type f -name '*.src.rpm') - echo "Found RPMS=${RPMS}" - echo "Found SRPMS=${SRPMS}" - echo "Found SRCRPMS=${SRCRPMS}" - for i in $RPMS $SRPMS $SRCRPMS - do - push_rpm "$i" - done -fi diff --git a/jjb/nsh_sfc/nsh_sfc.yaml b/jjb/nsh_sfc/nsh_sfc.yaml deleted file mode 100644 index 39d879acc..000000000 --- a/jjb/nsh_sfc/nsh_sfc.yaml +++ /dev/null @@ -1,641 +0,0 @@ ---- -- project: - name: nsh_sfc - jobs: - - 'nsh_sfc-verify-{stream}-{os}' - - 'nsh_sfc-merge-{stream}-{os}' - - 'nsh_sfc-integration-{stream}-{os}' - - 'nsh_sfc-verify-image-{stream}-{os}' - - 'nsh_sfc-verify-docs-{stream}' - - 'nsh_sfc-merge-docs-{stream}' - - project: 'nsh_sfc' - os: - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - - centos7: - repo-os-part: 'centos7' - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - '1609': - branch: 'stable/1609' - repo-stream-part: 'stable.1609' - - '1701': - branch: 'stable/1701' - repo-stream-part: 'stable.1701' - - '1704': - branch: 'stable/1704' - repo-stream-part: 'stable.1704' - - '1707': - branch: 'stable/1707' - repo-stream-part: 'stable.1707' - - '1710': - branch: 'stable/1710' - repo-stream-part: 'stable.1710' - - '1801': - branch: 'stable/1801' - repo-stream-part: 'stable.1801' - - '1804': - branch: 'stable/1804' - repo-stream-part: 'stable.1804' - - '1807': - branch: 'stable/1807' - repo-stream-part: 'stable.1807' -- project: - name: nsh_sfc-misc - jobs: - - 'nsh_sfc-csit-verify-perf-{stream}' - - 'nsh_sfc-csit-verify-func-{stream}-{os}-virl' - - project: 'nsh_sfc' - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - '1609': - branch: 'stable/1609' - repo-stream-part: 'stable.1609' - - '1701': - branch: 'stable/1701' - repo-stream-part: 'stable.1609' - - '1704': - branch: 'stable/1704' - repo-stream-part: 'stable.1704' - - '1707': - branch: 'stable/1707' - repo-stream-part: 'stable.1707' - - os: ubuntu1604 - -- project: - name: nsh-sfc-view - views: - - project-view - project-name: nsh_sfc - -- job-template: - name: 'nsh_sfc-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - jdk: openjdk8-{os} - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - maven-exec: - maven-version: 'mvn33-new' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'nsh_sfc-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - config-file-provider: - files: - - file-id: 'nsh_sfc-settings' - variable: 'SETTINGS_FILE' - - file-id: 'global-settings' - variable: 'GLOBAL_SETTINGS_FILE' - - shell: - !include-raw-escape: ../scripts/create_maven_env.sh - - inject: - properties-file: maven_env.txt - - shell: - !include-raw-escape: - - ../scripts/cleanup_vpp_plugin_dev_env.sh - - ../scripts/setup_vpp_plugin_dev_env.sh - - include-raw-nsh_sfc-build.sh - - ../scripts/cleanup_vpp_plugin_dev_env.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'nsh_sfc-verify-image-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - maven-exec: - maven-version: 'mvn33-new' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'verify-images' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'nsh_sfc-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - config-file-provider: - files: - - file-id: 'nsh_sfc-settings' - variable: 'SETTINGS_FILE' - - file-id: 'global-settings' - variable: 'GLOBAL_SETTINGS_FILE' - - shell: - !include-raw-escape: ../scripts/create_maven_env.sh - - inject: - properties-file: maven_env.txt - - shell: - !include-raw-escape: - - ../scripts/cleanup_vpp_plugin_dev_env.sh - - ../scripts/setup_vpp_plugin_dev_env.sh - - include-raw-nsh_sfc-build.sh - - ../scripts/cleanup_vpp_plugin_dev_env.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'nsh_sfc-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - jdk: openjdk8-{os} - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-exec: - maven-version: 'mvn33-new' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'nsh_sfc-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - config-file-provider: - files: - - file-id: 'nsh_sfc-settings' - variable: 'SETTINGS_FILE' - - file-id: 'global-settings' - variable: 'GLOBAL_SETTINGS_FILE' - - shell: - !include-raw-escape: ../scripts/create_maven_env.sh - - inject: - properties-file: maven_env.txt - - shell: - !include-raw-escape: - - ../scripts/cleanup_vpp_plugin_dev_env.sh - - ../scripts/setup_vpp_plugin_dev_env.sh - - include-raw-nsh_sfc-build.sh - - ../scripts/cleanup_vpp_plugin_dev_env.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'nsh_sfc-integration-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - jdk: openjdk8-{os} - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - maven-exec: - maven-version: 'mvn33-new' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - reverse: - jobs: 'vpp-merge-{stream}-{os},nsh_sfc-merge-{stream}-{os}' - result: 'success' - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'nsh_sfc-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - - config-file-provider: - files: - - file-id: 'nsh_sfc-settings' - variable: 'SETTINGS_FILE' - - file-id: 'global-settings' - variable: 'GLOBAL_SETTINGS_FILE' - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/home/jenkins/.packagecloud' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/home/jenkins/packagecloud_api' - - - shell: - !include-raw-escape: ../scripts/create_maven_env.sh - - inject: - properties-file: maven_env.txt - - shell: - !include-raw-escape: - - ../scripts/cleanup_vpp_plugin_dev_env.sh - - ../scripts/setup_vpp_plugin_dev_env.sh - - include-raw-nsh_sfc-build.sh - - ../scripts/cleanup_vpp_plugin_dev_env.sh - - ../scripts/maven_push_functions.sh - - include-raw-nsh_sfc-pkg-push.sh - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'nsh_sfc-verify-docs-{stream}' - - project-type: freestyle - node: ubuntu1604-builder-4c-4g - concurrent: true - jdk: openjdk8-ubuntu1604 - - build-discarder: - 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}' - - maven-exec: - maven-version: 'mvn33-new' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: include-raw-nsh_sfc-docs.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'nsh_sfc-merge-docs-{stream}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - jdk: openjdk8-{os} - archive-artifacts: '**/build-root/docs/html/*' - allow-empty: 'true' - fingerprint: false - only-if-success: true - default-excludes: false - - build-discarder: - 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}' - - os-parameter: - os: 'ubuntu1604' - - maven-exec: - maven-version: 'mvn33-new' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - reverse: - jobs: 'nsh_sfc-merge-{stream}-ubuntu1604' - result: 'success' - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'run-docs' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: include-raw-nsh_sfc-docs.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'nsh_sfc-csit-verify-perf-{stream}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - archive-artifacts: '**/csit/archive/*.*' - latest-only: false - - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.ubuntu.xenial.main' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers-non-activity-timeout: - build-timeout: 30 - - triggers: - - gerrit-trigger-manually-triggered: - name: '{project}' - branch: '{branch}' - comment-trigger-value: 'nsh_sfc_perf' - - builders: - - shell: - !include-raw-escape: include-raw-nsh_sfc-csit-perf-hw.sh - - pulishers: - - robot-report: - output-path: 'csit/archive' - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'nsh_sfc-csit-verify-func-{stream}-{os}-virl' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - archive-artifacts: '**/csit/archive/*.*' - latest-only: false - - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.ubuntu.xenial.main' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-manually-triggered: - name: '{project}' - branch: '{branch}' - comment-trigger-value: 'nsh_sfc_func' - - builders: - - shell: - !include-raw-escape: include-raw-nsh_sfc-csit-functional-virl.sh - - publishers: - - robot-report: - output-path: 'csit/archive' - - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- project: - name: nsh_sfc-info - project-name: nsh_sfc - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-4c-4g - project: nsh_sfc - branch: master diff --git a/jjb/opflexvpp/opflexvpp.yaml b/jjb/opflexvpp/opflexvpp.yaml deleted file mode 100644 index 5c5a93453..000000000 --- a/jjb/opflexvpp/opflexvpp.yaml +++ /dev/null @@ -1,15 +0,0 @@ ---- -- project: - name: opflexvpp-project-view - project-name: opflexvpp - views: - - project-view - -- project: - name: opflexvpp-info - project-name: opflexvpp - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-4c-4g - project: opflexvpp - branch: master diff --git a/jjb/puppet-fdio/puppet-fdio.yaml b/jjb/puppet-fdio/puppet-fdio.yaml deleted file mode 100644 index 4d705aebb..000000000 --- a/jjb/puppet-fdio/puppet-fdio.yaml +++ /dev/null @@ -1,130 +0,0 @@ ---- -- project: - name: puppet-fdio - jobs: - - 'puppet-module-unit' - - 'puppet-fdio-verify-beaker-{stream}-{os}' - project: 'puppet-fdio' - os: 'centos7' - repo-os-part: 'centos7' - - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - -- project: - name: puppet-fdio-view - views: - - project-view - project-name: puppet-fdio - -- job-template: - name: 'puppet-fdio-verify-unit-{puppet_version}-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - shell: | - ./scripts/prepare-node.sh - ./scripts/ci-unit-tests.sh {puppet_version} - -- job-group: - name: 'puppet-module-unit' - puppet_version: - - 3.6 - - 3.8 - - 4.0 - - 4.5 - - 'latest' - jobs: - - 'puppet-fdio-verify-unit-{puppet_version}-{stream}-{os}' - -- job-template: - name: 'puppet-fdio-verify-beaker-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - shell: | - ./scripts/prepare-node.sh - ./scripts/allow-local-ssh-root.sh - ./scripts/ci-beaker.sh {os} - - publishers: - - lf-infra-publish - -- project: - name: puppet-fdio-info - project-name: puppet-fdio - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-4c-4g - project: puppet-fdio - branch: master diff --git a/jjb/rpm_dpdk/include-raw-rpm_dpdk-pkg-build.sh b/jjb/rpm_dpdk/include-raw-rpm_dpdk-pkg-build.sh deleted file mode 100644 index c02eb437c..000000000 --- a/jjb/rpm_dpdk/include-raw-rpm_dpdk-pkg-build.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/bash -# basic build script example -set -e -o pipefail -# do nothing but print the current slave hostname -hostname - -echo "cat /etc/bootstrap.sha" -if [ -f /etc/bootstrap.sha ];then - cat /etc/bootstrap.sha -else - echo "Cannot find /etc/bootstrap.sha" -fi - -echo "cat /etc/bootstrap-functions.sha" -if [ -f /etc/bootstrap-functions.sha ];then - cat /etc/bootstrap-functions.sha -else - echo "Cannot find /etc/bootstrap-functions.sha" -fi - -echo "sha1sum of this script: ${0}" -sha1sum $0 - -scripts/ci/verify.sh - -echo "*******************************************************************" -echo "* rpm_dpdk BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" diff --git a/jjb/rpm_dpdk/include-raw-rpm_dpdk-pkg-push.sh b/jjb/rpm_dpdk/include-raw-rpm_dpdk-pkg-push.sh deleted file mode 100644 index b9b9c4deb..000000000 --- a/jjb/rpm_dpdk/include-raw-rpm_dpdk-pkg-push.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/bash -# basic build script example -set -e -o pipefail -echo "Looking for rpms to publish" -# Find the files -RPMS=$(find . -type f -iname '*.rpm') -SRPMS=$(find . -type f -iname '*.srpm') -SRCRPMS=$(find . -type f -name '*.src.rpm') -echo "Found RPMS=${RPMS}" -echo "Found SRPMS=${SRPMS}" -echo "Found SRCRPMS=${SRCRPMS}" -for i in $RPMS $SRPMS $SRCRPMS -do - push_rpm "$i" -done diff --git a/jjb/rpm_dpdk/rpm_dpdk.yaml b/jjb/rpm_dpdk/rpm_dpdk.yaml deleted file mode 100644 index 32adc6e12..000000000 --- a/jjb/rpm_dpdk/rpm_dpdk.yaml +++ /dev/null @@ -1,201 +0,0 @@ ---- -- project: - name: rpm_dpdk - jobs: - - 'rpm_dpdk-verify-{stream}-{os}' - - 'rpm_dpdk-merge-{stream}-{os}' - - 'rpm_dpdk-verify-image-{stream}-{os}' - - project: 'rpm_dpdk' - os: - - centos7: - repo-os-part: 'centos7' - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - -- project: - name: rpm_dpdk-view - views: - - project-view: - project-name: rpm_dpdk - -- job-template: - name: 'rpm_dpdk-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: - - include-raw-rpm_dpdk-pkg-build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'rpm_dpdk-verify-image-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'verify-images' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - builders: - - shell: - !include-raw-escape: - - include-raw-rpm_dpdk-pkg-build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- job-template: - name: 'rpm_dpdk-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - maven-exec: - maven-version: 'mvn33-new' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'rpm_dpdk-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - config-file-provider: - files: - - file-id: 'rpm_dpdk-settings' - variable: 'SETTINGS_FILE' - - file-id: 'global-settings' - variable: 'GLOBAL_SETTINGS_FILE' - - shell: - !include-raw-escape: - - ../scripts/maven_push_functions.sh - - include-raw-rpm_dpdk-pkg-build.sh - - include-raw-rpm_dpdk-pkg-push.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn33-new' - -- project: - name: rpm_dpdk-info - project-name: rpm_dpdk - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-4c-4g - project: rpm_dpdk - branch: master diff --git a/jjb/cicn/include-raw-cicn-libparc-build.sh b/jjb/scripts/cicn/build-libparc.sh index 4943501c1..967670e3b 100644 --- a/jjb/cicn/include-raw-cicn-libparc-build.sh +++ b/jjb/scripts/cicn/build-libparc.sh @@ -1,5 +1,5 @@ #!/bin/bash -# basic build script example +echo "---> jjb/scripts/cicn/build-libparc.sh" set -euxo pipefail IFS=$'\n\t' diff --git a/jjb/scripts/cicn/build-viper.sh b/jjb/scripts/cicn/build-viper.sh new file mode 100644 index 000000000..38018b779 --- /dev/null +++ b/jjb/scripts/cicn/build-viper.sh @@ -0,0 +1,8 @@ +#!/bin/bash +echo "---> jjb/scripts/cicn/build-viper.sh" +set -euxo pipefail +IFS=$'\n\t' + +pushd scripts +bash build-package.sh +popd diff --git a/jjb/scripts/cicn/docs-libparc.sh b/jjb/scripts/cicn/docs-libparc.sh new file mode 100644 index 000000000..0ca4effb9 --- /dev/null +++ b/jjb/scripts/cicn/docs-libparc.sh @@ -0,0 +1,38 @@ +#!/bin/bash +echo "---> jjb/scripts/cicn/docs-libparc.sh" +set -xe -o pipefail + +update_cmake_repo() { + cat /etc/resolv.conf + echo "nameserver 8.8.8.8" | sudo tee -a /etc/resolv.conf + cat /etc/resolv.conf + + CMAKE_INSTALL_SCRIPT_URL="https://cmake.org/files/v3.8/cmake-3.8.0-Linux-x86_64.sh" + CMAKE_INSTALL_SCRIPT="/tmp/install_cmake.sh" + curl ${CMAKE_INSTALL_SCRIPT_URL} > ${CMAKE_INSTALL_SCRIPT} + + sudo mkdir -p /opt/cmake + sudo bash ${CMAKE_INSTALL_SCRIPT} --skip-license --prefix=/opt/cmake + export PATH=/opt/cmake/bin:$PATH +} + +cd libparc + +[ "$DOC_DIR" ] || DOC_DIR="build/documentation/generated-documentation/html" +[ "$SITE_DIR" ] || SITE_DIR="build/documentation/deploy-site/" +[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources + +update_cmake_repo +mkdir -p build +pushd build +cmake -DDOC_ONLY=ON .. +make documentation +popd + +if [[ ${JOB_NAME} == *merge* ]]; then + mkdir -p $(dirname ${RESOURCES_DIR}) + mv -f ${DOC_DIR} ${RESOURCES_DIR} + cd ${SITE_DIR} + find . -type f '(' -name '*.md5' -o -name '*.dot' -o -name '*.map' ')' -delete + cd - +fi diff --git a/jjb/scripts/cleanup_vpp_plugin_dev_env.sh b/jjb/scripts/cleanup_vpp_plugin_dev_env.sh deleted file mode 100644 index 2fcdf7016..000000000 --- a/jjb/scripts/cleanup_vpp_plugin_dev_env.sh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/bash -set -e -o pipefail - -# Figure out what system we are running on -if [ -f /etc/lsb-release ];then - . /etc/lsb-release -elif [ -f /etc/redhat-release ];then - sudo yum install -y redhat-lsb - DISTRIB_ID=`lsb_release -si` - DISTRIB_RELEASE=`lsb_release -sr` - DISTRIB_CODENAME=`lsb_release -sc` - DISTRIB_DESCRIPTION=`lsb_release -sd` -fi -echo DISTRIB_ID: $DISTRIB_ID -echo DISTRIB_RELEASE: $DISTRIB_RELEASE -echo DISTRIB_CODENAME: $DISTRIB_CODENAME -echo DISTRIB_DESCRIPTION: $DISTRIB_DESCRIPTION - -function cleanup { - # Setup by installing vpp-dev and vpp-lib - if [ $DISTRIB_ID == "Ubuntu" ]; then - sudo rm -f /etc/apt/sources.list.d/99fd.io.list - sudo dpkg -r vpp-dev vpp-lib vpp-dev vpp-lib vpp vpp-dpdk-dev vpp-dpdk-dkms vpp-dbg vpp-ext-deps - elif [[ $DISTRIB_ID == "CentOS" ]]; then - sudo rm -f /etc/yum.repos.d/fdio-master.repo - sudo yum -y remove vpp-devel vpp-lib vpp vpp-ext-deps - fi -} - -trap cleanup EXIT -cleanup diff --git a/jjb/scripts/create_maven_env.sh b/jjb/scripts/create_maven_env.sh index 48a2da06f..cbc9f868b 100644 --- a/jjb/scripts/create_maven_env.sh +++ b/jjb/scripts/create_maven_env.sh @@ -1,3 +1,18 @@ #!/bin/bash +# Copyright (c) 2020 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/create_maven_env.sh" + echo "MAVEN_SETTINGS_OPTIONS=-s $SETTINGS_FILE -gs $GLOBAL_SETTINGS_FILE" > maven_env.txt diff --git a/jjb/scripts/csit/cpta.sh b/jjb/scripts/csit/cpta.sh deleted file mode 100644 index d6bc187b4..000000000 --- a/jjb/scripts/csit/cpta.sh +++ /dev/null @@ -1,87 +0,0 @@ -#!/bin/bash - -# Copyright (c) 2020 Cisco and/or its affiliates. -# 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. - -set -xe -o pipefail - -[ "${DOCS_REPO_URL}" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site" -[ "${PROJECT_PATH}" ] || PROJECT_PATH="io/fd/csit" -[ "${DOC_DIR}" ] || DOC_DIR="resources/tools/presentation" -[ "${BUILD_DIR}" ] || BUILD_DIR="${DOC_DIR}/_build" -[ "${SITE_DIR}" ] || SITE_DIR="build-root/docs/deploy-site" -[ "${RESOURCES_DIR}" ] || RESOURCES_DIR="${SITE_DIR}/src/site/resources/trending" -[ "${STATIC_VPP_DIR}" ] || STATIC_VPP_DIR="${RESOURCES_DIR}/_static/vpp" -[ "${MVN}" ] || MVN="/opt/apache/maven/bin/mvn" -[ "${FAILED_TESTS}" ] || FAILED_TESTS="${STATIC_VPP_DIR}/trending-failed-tests.txt" -[ "${REGRESSIONS}" ] || REGRESSIONS="${STATIC_VPP_DIR}/trending-regressions.txt" -[ "${PROGRESSIONS}" ] || PROGRESSIONS="${STATIC_VPP_DIR}/trending-progressions.txt" - -# Create a text file with email body in case the build fails: -cd "${WORKSPACE}" -mkdir -p "${STATIC_VPP_DIR}" -EMAIL_BODY="ERROR: The build number ${BUILD_NUMBER} of the job ${JOB_NAME} failed. For more information see: ${BUILD_URL}" -echo "${EMAIL_BODY}" > "${FAILED_TESTS}" -echo "${EMAIL_BODY}" > "${REGRESSIONS}" -echo "${EMAIL_BODY}" > "${PROGRESSIONS}" - -cd "${DOC_DIR}" -chmod +x ./run_cpta.sh -STATUS=$(./run_cpta.sh | tail -1) - -cd "${WORKSPACE}" -rm -rf "${SITE_DIR}/"* - -mkdir -p "${RESOURCES_DIR}" -ls "${RESOURCES_DIR}" -mv -f "${BUILD_DIR}/"* "${RESOURCES_DIR}" - -cd "${SITE_DIR}" - -cat > pom.xml << EOF -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>io.fd.csit</groupId> - <artifactId>docs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> - <properties> - <generateReports>false</generateReports> - </properties> - <build> - <extensions> - <extension> - <groupId>org.apache.maven.wagon</groupId> - <artifactId>wagon-webdav-jackrabbit</artifactId> - <version>2.10</version> - </extension> - </extensions> - </build> - <distributionManagement> - <site> - <id>fdio-site</id> - <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/${GERRIT_BRANCH}</url> - </site> - </distributionManagement> -</project> -EOF - -${MVN} site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C - -cd - - -if [ "${STATUS}" == "PASS" ]; then - exit 0 -else - exit 1 -fi diff --git a/jjb/scripts/csit/device-semiweekly.sh b/jjb/scripts/csit/device-semiweekly.sh index 10c3ed7a0..1086b5463 100644..100755 --- a/jjb/scripts/csit/device-semiweekly.sh +++ b/jjb/scripts/csit/device-semiweekly.sh @@ -13,19 +13,22 @@ # See the License for the specific language governing permissions and # limitations under the License. +echo "---> jjb/scripts/csit/device-semiweekly.sh" + set -exuo pipefail # Clone CSIT git repository and proceed with entry script located there. # # Variables read: # - WORKSPACE - Jenkins workspace to create csit subdirectory in. +# - GIT_URL - Git clone URL # - BRANCH_ID - CSIT operational branch to be used for test. # Directories updated: # - ${WORKSPACE}/csit - Created, holding a checked out CSIT repository. # - Multiple other side effects by entry script(s), see CSIT repository. cd "${WORKSPACE}" -git clone https://gerrit.fd.io/r/csit --depth=1 --no-single-branch --no-checkout +git clone "${GIT_URL}/csit" --depth=1 --no-single-branch --no-checkout # Check BRANCH_ID value. if [[ -z "${BRANCH_ID-}" ]]; then echo "BRANCH_ID not provided => 'oper' belonging to master will be used." @@ -45,3 +48,4 @@ git checkout "${BRANCH_NAME}" popd csit_entry_dir="${WORKSPACE}/csit/resources/libraries/bash/entry" source "${csit_entry_dir}/bootstrap_vpp_device.sh" +cp -R "${WORKSPACE}/csit/archives" "${WORKSPACE}/archives" || true diff --git a/jjb/scripts/csit/device-verify.sh b/jjb/scripts/csit/device-verify.sh index f26e6beba..5ccd2a580 100644 --- a/jjb/scripts/csit/device-verify.sh +++ b/jjb/scripts/csit/device-verify.sh @@ -13,6 +13,8 @@ # See the License for the specific language governing permissions and # limitations under the License. +echo "---> jjb/scripts/csit/device-verify.sh" + set -exuo pipefail csit_entry_dir="${WORKSPACE}/resources/libraries/bash/entry" diff --git a/jjb/scripts/csit/dmm-functional-virl.sh b/jjb/scripts/csit/dmm-functional-virl.sh deleted file mode 100644 index fcc0a49ad..000000000 --- a/jjb/scripts/csit/dmm-functional-virl.sh +++ /dev/null @@ -1,40 +0,0 @@ -#!/bin/bash - -# Copyright (c) 2018 Huawei Technologies Co.,Ltd. -# Copyright (c) 2020 Cisco and/or its affiliates. -# 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. - -set -xeu -o pipefail - -# Clone dmm and start tests -git clone https://gerrit.fd.io/r/dmm - -# If the git clone fails, complain clearly and exit -if [ $? != 0 ]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/dmm" - exit 1 -fi - -# execute DMM bootstrap script if it exists -if [ -e bootstrap-DMM.sh ] -then - # make sure that bootstrap-DMM.sh is executable - chmod +x bootstrap-DMM.sh - # run the script - ./bootstrap-DMM.sh -else - echo 'ERROR: No bootstrap-DMM.sh found' - exit 1 -fi - -# vim: ts=4 ts=4 sts=4 et :
\ No newline at end of file diff --git a/jjb/scripts/csit/docs.sh b/jjb/scripts/csit/docs.sh deleted file mode 100644 index ebd8546b8..000000000 --- a/jjb/scripts/csit/docs.sh +++ /dev/null @@ -1,76 +0,0 @@ -#!/bin/bash - -# Copyright (c) 2020 Cisco and/or its affiliates. -# 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. - -set -xe -o pipefail - -[ "$DOCS_REPO_URL" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site" -[ "$PROJECT_PATH" ] || PROJECT_PATH=io/fd/csit -[ "$DOC_DIR" ] || DOC_DIR=resources/tools/doc_gen -[ "$BUILD_DIR" ] || BUILD_DIR=${DOC_DIR}/_build -[ "$SITE_DIR" ] || SITE_DIR=build-root/docs/deploy-site -[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources/doc -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" - -cd ${DOC_DIR} -chmod +x ./run_doc.sh -./run_doc.sh ${GERRIT_BRANCH} - -retval=$? -if [ ${retval} -ne "0" ]; then - echo "Documentation generation failed!" -exit ${retval} -fi - -if [[ ${JOB_NAME} == *merge* ]]; then - - cd ${WORKSPACE} - - mkdir -p ${RESOURCES_DIR} - mv -f ${BUILD_DIR}/* ${RESOURCES_DIR} - cd ${SITE_DIR} - - cat > pom.xml << EOF - <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>io.fd.csit</groupId> - <artifactId>docs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> - <properties> - <generateReports>false</generateReports> - </properties> - <build> - <extensions> - <extension> - <groupId>org.apache.maven.wagon</groupId> - <artifactId>wagon-webdav-jackrabbit</artifactId> - <version>2.10</version> - </extension> - </extensions> - </build> - <distributionManagement> - <site> - <id>fdio-site</id> - <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/${GERRIT_BRANCH}</url> - </site> - </distributionManagement> - </project> -EOF - - ${MVN} site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C - - cd - - -fi diff --git a/jjb/scripts/csit/hc2vpp-verify-func.sh b/jjb/scripts/csit/hc2vpp-verify-func.sh deleted file mode 100644 index 3e3c63e07..000000000 --- a/jjb/scripts/csit/hc2vpp-verify-func.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/bash - -# Copyright (c) 2020 Cisco and/or its affiliates. -# 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. - -# Parse optional arguments from gerrit comment trigger -for i in ${GERRIT_EVENT_COMMENT_TEXT}; do - case ${i} in - *honeycomb=*) - hc_version=`echo "${i}" | cut -d = -f2-` - ;; - *) - ;; - esac -done - -# If HC variable is set, check honeycomb version. -if [[ -n "${hc_version}" ]]; then - if [[ "${hc_version}" == *"-release" ]]; then - # we are going to test release build. All release - # packages should be already present in release repo - STREAM="release" - echo "STREAM set to: ${STREAM}" - fi -fi - -# execute csit bootstrap script if it exists -if [[ ! -e bootstrap-hc2vpp-integration.sh ]] -then - echo 'ERROR: No bootstrap-hc2vpp-integration.sh found' - exit 1 -else - # make sure that bootstrap.sh is executable - chmod +x bootstrap-hc2vpp-integration.sh - # run the script - ./bootstrap-hc2vpp-integration.sh ${STREAM} ${OS} -fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/scripts/csit/nsh_sfc-functional-virl.sh b/jjb/scripts/csit/nsh_sfc-functional-virl.sh deleted file mode 100644 index d90003d0c..000000000 --- a/jjb/scripts/csit/nsh_sfc-functional-virl.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash - -# Copyright (c) 2020 Cisco and/or its affiliates. -# 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. - -set -xeu -o pipefail - -# execute nsh_sfc bootstrap script if it exists -if [ -e bootstrap-nsh_sfc-functional-virl.sh ] -then - # make sure that bootstrap-nsh_sfc-functional-virl.sh is executable - chmod +x bootstrap-nsh_sfc-functional-virl.sh - # run the script - if [ ${STREAM} == 'master' ]; then - ./bootstrap-nsh_sfc-functional-virl.sh ${STREAM} ${OS} - else - ./bootstrap-nsh_sfc-functional-virl.sh 'stable.'${STREAM} ${OS} - fi -else - echo 'ERROR: No bootstrap-nsh_sfc-functional-virl.sh found' - exit 1 -fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/scripts/csit/perf-timed.sh b/jjb/scripts/csit/perf-timed.sh index 76fabd58f..10925b04f 100644..100755 --- a/jjb/scripts/csit/perf-timed.sh +++ b/jjb/scripts/csit/perf-timed.sh @@ -13,12 +13,15 @@ # See the License for the specific language governing permissions and # limitations under the License. +echo "---> jjb/scripts/csit/perf-timed.sh" + set -exuo pipefail # Clone CSIT git repository and proceed with entry script located there. # # Variables read: # - WORKSPACE - Jenkins workspace to create csit subdirectory in. +# - GIT_URL - Git clone URL # - GERRIT_BRANCH - Jenkins configured GERRIT_BRANCH parameter equal to required # CSIT branch. # - CSIT_REF - Override ref of CSIT git repository to checkout. @@ -27,10 +30,10 @@ set -exuo pipefail # - Multiple other side effects by entry script(s), see CSIT repository. cd "${WORKSPACE}" -git clone https://gerrit.fd.io/r/csit --depth=1 --no-single-branch --no-checkout +git clone "${GIT_URL}/csit" --depth=1 --no-single-branch --no-checkout pushd "${WORKSPACE}/csit" if [[ -n "${CSIT_REF-}" ]]; then - git fetch --depth=1 https://gerrit.fd.io/r/csit "${CSIT_REF}" + git fetch --depth=1 "${GIT_URL}/csit" "${CSIT_REF}" git checkout FETCH_HEAD else git checkout "${GERRIT_BRANCH}" @@ -38,3 +41,4 @@ fi popd csit_entry_dir="${WORKSPACE}/csit/resources/libraries/bash/entry" source "${csit_entry_dir}/with_oper_for_vpp.sh" "bootstrap_verify_perf.sh" +cp -R "${WORKSPACE}/csit/archives" "${WORKSPACE}/archives" || true diff --git a/jjb/scripts/csit/perf-verify.sh b/jjb/scripts/csit/perf-verify.sh index c68a88126..859859414 100644 --- a/jjb/scripts/csit/perf-verify.sh +++ b/jjb/scripts/csit/perf-verify.sh @@ -13,11 +13,14 @@ # See the License for the specific language governing permissions and # limitations under the License. +echo "---> jjb/scripts/csit/perf-verify.sh" + set -exuo pipefail +# TODO: Figure out how old CSIT branches need the processing here. if [[ ${GERRIT_EVENT_TYPE} == 'comment-added' ]]; then TRIGGER=`echo ${GERRIT_EVENT_COMMENT_TEXT} \ - | grep -oE '(perftest$|perftest[[:space:]].+$)'` + | grep -oE '(perftest$|perftest[[:space:]].+$)' || true` else TRIGGER='' fi diff --git a/jjb/scripts/csit/report.sh b/jjb/scripts/csit/report.sh deleted file mode 100644 index b2ea0f966..000000000 --- a/jjb/scripts/csit/report.sh +++ /dev/null @@ -1,76 +0,0 @@ -#!/bin/bash - -# Copyright (c) 2020 Cisco and/or its affiliates. -# 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. - -set -xe -o pipefail - -[ "$DOCS_REPO_URL" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site" -[ "$PROJECT_PATH" ] || PROJECT_PATH=io/fd/csit -[ "$DOC_DIR" ] || DOC_DIR=resources/tools/presentation -[ "$BUILD_DIR" ] || BUILD_DIR=${DOC_DIR}/_build -[ "$SITE_DIR" ] || SITE_DIR=build-root/docs/deploy-site -[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources/report -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" - -cd ${DOC_DIR} -chmod +x ./run_report.sh -./run_report.sh ${GERRIT_BRANCH} - -retval=$? -if [ ${retval} -ne "0" ]; then - echo "Report generation failed!" -exit ${retval} -fi - -if [[ ${JOB_NAME} == *merge* ]]; then - - cd ${WORKSPACE} - - mkdir -p ${RESOURCES_DIR} - mv -f ${BUILD_DIR}/* ${RESOURCES_DIR} - cd ${SITE_DIR} - - cat > pom.xml << EOF - <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>io.fd.csit</groupId> - <artifactId>docs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> - <properties> - <generateReports>false</generateReports> - </properties> - <build> - <extensions> - <extension> - <groupId>org.apache.maven.wagon</groupId> - <artifactId>wagon-webdav-jackrabbit</artifactId> - <version>2.10</version> - </extension> - </extensions> - </build> - <distributionManagement> - <site> - <id>fdio-site</id> - <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/${GERRIT_BRANCH}</url> - </site> - </distributionManagement> - </project> -EOF - - ${MVN} site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C - - cd - - -fi diff --git a/jjb/scripts/csit/vpp-functional-multilink.sh b/jjb/scripts/csit/terraform-aws-eb-version-deploy.sh index 5cf2454eb..3bc683b91 100644 --- a/jjb/scripts/csit/vpp-functional-multilink.sh +++ b/jjb/scripts/csit/terraform-aws-eb-version-deploy.sh @@ -1,6 +1,6 @@ #!/bin/bash -# Copyright (c) 2020 Cisco and/or its affiliates. +# Copyright (c) 2023 Cisco and/or its affiliates. # 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: @@ -13,16 +13,9 @@ # See the License for the specific language governing permissions and # limitations under the License. -# execute csit bootstrap script if it exists -if [ -e bootstrap-multilink.sh ] -then - # make sure that bootstrap.sh is executable - chmod +x bootstrap-multilink.sh - # run the script - ./bootstrap-multilink.sh -else - echo 'ERROR: No bootstrap-multilink.sh found' - exit 1 -fi +echo "---> jjb/scripts/csit/terraform-aws-eb-version-deploy.sh" -# vim: ts=4 ts=4 sts=4 et : +set -exuo pipefail + +csit_entry_dir="${WORKSPACE}/resources/libraries/bash/entry" +source "${csit_entry_dir}/bootstrap_aws_eb_version_deploy.sh" diff --git a/jjb/dmm/include-raw-dmm-test-checkstyle.sh b/jjb/scripts/csit/terraform-aws-eb-version-verify.sh index 90b307141..7a9f16261 100644 --- a/jjb/dmm/include-raw-dmm-test-checkstyle.sh +++ b/jjb/scripts/csit/terraform-aws-eb-version-verify.sh @@ -1,5 +1,6 @@ #!/bin/bash -# Copyright (c) 2018 Huawei Technologies Co.,Ltd. + +# Copyright (c) 2023 Cisco and/or its affiliates. # 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: @@ -12,18 +13,9 @@ # See the License for the specific language governing permissions and # limitations under the License. -if grep 'checkstyle' CMakeLists.txt > /dev/null -then - cd build/ - cmake .. - make checkstyle - if [ $? -eq 0 ]; then - echo "DMM checkstyle is SUCCESS" - else - echo "DMM checkstyle has FAILED" - exit 1 - fi -else - echo "Can't find checkstyle target in CMakeLists.txt- skipping test checkstyle" - exit 1 -fi
\ No newline at end of file +echo "---> jjb/scripts/csit/terraform-aws-eb-version-verify.sh" + +set -exuo pipefail + +csit_entry_dir="${WORKSPACE}/resources/libraries/bash/entry" +source "${csit_entry_dir}/bootstrap_aws_eb_version_verify.sh" diff --git a/jjb/scripts/csit/tldk-functional-virl.sh b/jjb/scripts/csit/tldk-functional-virl.sh deleted file mode 100644 index 8e732a517..000000000 --- a/jjb/scripts/csit/tldk-functional-virl.sh +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/bash - -# Copyright (c) 2020 Cisco and/or its affiliates. -# 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. - -set -xeu -o pipefail - -# Clone tldk and start tests -git clone https://gerrit.fd.io/r/tldk - -# If the git clone fails, complain clearly and exit -if [ $? != 0 ]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/tldk" - exit 1 -fi - -# execute tldk bootstrap script if it exists -if [ -e bootstrap-TLDK.sh ] -then - # make sure that bootstrap-TLDK.sh is executable - chmod +x bootstrap-TLDK.sh - # run the script - ./bootstrap-TLDK.sh -else - echo 'ERROR: No bootstrap-TLDK.sh found' - exit 1 -fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/scripts/csit/tox.sh b/jjb/scripts/csit/tox.sh index 32ccb5c00..6a0c02b41 100644 --- a/jjb/scripts/csit/tox.sh +++ b/jjb/scripts/csit/tox.sh @@ -17,6 +17,8 @@ # We do not use source command, to make sure # the called script choses the interpreter it needs. +echo "---> jjb/scripts/csit/tox.sh" + set -exuo pipefail ${WORKSPACE}/resources/libraries/bash/entry/tox.sh diff --git a/jjb/hicn/include-raw-hicn-extras-build.sh b/jjb/scripts/hicn/build-extras.sh index bcf913be0..c1e0e3e1e 100644 --- a/jjb/hicn/include-raw-hicn-extras-build.sh +++ b/jjb/scripts/hicn/build-extras.sh @@ -2,6 +2,8 @@ # basic build script example set -euxo pipefail +echo "---> jjb/scripts/hicn/build-extras.sh" + pushd scripts bash ./build-extras.sh popd diff --git a/jjb/cicn/include-raw-cicn-viper-build.sh b/jjb/scripts/hicn/build-vpp-latest.sh index 92bf809e4..444f9b699 100644 --- a/jjb/cicn/include-raw-cicn-viper-build.sh +++ b/jjb/scripts/hicn/build-vpp-latest.sh @@ -1,8 +1,7 @@ #!/bin/bash # basic build script example set -euxo pipefail -IFS=$'\n\t' pushd scripts -bash build-package.sh +bash ./build-packages.sh vpp_master popd diff --git a/jjb/hicn/include-raw-hicn-build.sh b/jjb/scripts/hicn/build.sh index e1d20a48e..8dd150a74 100644 --- a/jjb/hicn/include-raw-hicn-build.sh +++ b/jjb/scripts/hicn/build.sh @@ -2,6 +2,8 @@ # basic build script example set -euxo pipefail +echo "---> jjb/scripts/hicn/build.sh" + pushd scripts bash ./build-packages.sh popd diff --git a/jjb/hicn/include-raw-hicn-checkstyle.sh b/jjb/scripts/hicn/checkstyle.sh index 636590e7a..451950ebb 100644 --- a/jjb/hicn/include-raw-hicn-checkstyle.sh +++ b/jjb/scripts/hicn/checkstyle.sh @@ -1,5 +1,7 @@ #!/bin/bash +echo "---> jjb/scripts/hicn/checkstyle.sh" + if [ -f ./scripts/checkstyle.sh ];then bash scripts/checkstyle.sh else diff --git a/jjb/scripts/hicn/docs.sh b/jjb/scripts/hicn/docs.sh new file mode 100644 index 000000000..e927f0bbc --- /dev/null +++ b/jjb/scripts/hicn/docs.sh @@ -0,0 +1,14 @@ +#!/bin/bash +set -xe -o pipefail + +DOC_DIR="docs/build/html" +SITE_DIR_ROOT="build/doc" +SITE_DIR="${SITE_DIR_ROOT}/deploy-site" + +echo "---> jjb/scripts/hicn/docs.sh" + +bash scripts/build-packages.sh sphinx + +mkdir -p "${SITE_DIR_ROOT}" +mv -f "${DOC_DIR}" "${SITE_DIR}" +find "${SITE_DIR}" -type f '(' -name '*.md5' -o -name '*.dot' -o -name '*.map' ')' -delete diff --git a/jjb/scripts/hicn/functest.sh b/jjb/scripts/hicn/functest.sh new file mode 100644 index 000000000..e520c78ce --- /dev/null +++ b/jjb/scripts/hicn/functest.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# basic build script example +set -euxo pipefail + +echo "---> jjb/scripts/hicn/functest.sh" + +pushd scripts +bash ./functional-tests.sh +popd diff --git a/jjb/scripts/hicn/sonar.sh b/jjb/scripts/hicn/sonar.sh new file mode 100644 index 000000000..2f2060cc3 --- /dev/null +++ b/jjb/scripts/hicn/sonar.sh @@ -0,0 +1,8 @@ +#!/bin/bash +set -euxo pipefail + +echo "---> jjb/scripts/hicn/sonar.sh" + +pushd scripts +bash ./build-sonar.sh +popd diff --git a/jjb/scripts/maven_push_functions.sh b/jjb/scripts/maven_push_functions.sh index 6627615a6..d26b71422 100644 --- a/jjb/scripts/maven_push_functions.sh +++ b/jjb/scripts/maven_push_functions.sh @@ -1,4 +1,20 @@ #!/bin/bash + +# Copyright (c) 2020 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/maven_push_functions.sh" + set -xe -o pipefail echo "*******************************************************************" echo "* STARTING PUSH OF PACKAGES TO REPOS" diff --git a/jjb/scripts/packagecloud_promote.sh b/jjb/scripts/packagecloud_promote.sh index 8523e6cf0..6a138b419 100644 --- a/jjb/scripts/packagecloud_promote.sh +++ b/jjb/scripts/packagecloud_promote.sh @@ -1,5 +1,20 @@ #!/bin/bash +# Copyright (c) 2020 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/packagecloud_promote.sh" + stage_repo="https://packagecloud.io/api/v1/repos/fdio/staging" curl --netrc-file /home/jenkins/packagecloud_api $stage_repo/packages.json | \ python -mjson.tool >filenames.txt diff --git a/jjb/scripts/packagecloud_push.sh b/jjb/scripts/packagecloud_push.sh index 95ea92ed9..80226aa04 100644..100755 --- a/jjb/scripts/packagecloud_push.sh +++ b/jjb/scripts/packagecloud_push.sh @@ -1,39 +1,113 @@ #!/bin/bash -# PCIO_CO is a Jenkins Global Environment variable -set -x +# Copyright (c) 2021 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/packagecloud_push.sh" + +set -euxo pipefail + +line="*************************************************************************" + +# Nothing was built if this is a merge job being run when +# the git HEAD id is not the same as the Gerrit New Revision ID +if [[ ${JOB_NAME} == *merge* ]] && [ -n "${GERRIT_NEWREV:-}" ] && + [ "$GERRIT_NEWREV" != "$GIT_COMMIT" ] ; then + echo -e "\n$line\nSkipping package push. A newer patch has been merged.\n$line\n" + exit 0 +fi + +DRYRUN="${DRYRUN:-}" +if [ "${DRYRUN,,}" = "true" ] ; then + echo -e "\n$line\nSkipping package push because DRYRUN is '${DRYRUN,,}'.\n$line\n" + exit 0 +fi echo "STARTING PACKAGECLOUD PUSH" sleep 10 -if [ -f /usr/bin/zypper ]; then - FACTER_OS="openSUSE" -else - FACTER_OS=$(/usr/bin/facter operatingsystem) -fi +FACTER_OS=$(/usr/bin/facter operatingsystem) +push_cmd="" +push_ext_deps_cmd="" +ext_deps_pkg="" +downloads_dir="/root/Downloads" + +create_deb_push_cmds() +{ + local distro="$1" + + if [ "$distro" = "debian" ] || [ "$distro" = "ubuntu" ] ; then + FACTER_LSBNAME=$(/usr/bin/facter lsbdistcodename) + DEBS=$(find . -type f -iname '*.deb' | grep -v vpp-ext-deps | xargs || true) + push_cmd="package_cloud push ${PCIO_CO}/${STREAM}/${distro}/${FACTER_LSBNAME}/main/ ${DEBS}" + ext_deps_ver="$(dpkg -l vpp-ext-deps | mawk '/vpp-ext-deps/{print $3}' || true)" + ext_deps_pkg="$(find . -type f -iname 'vpp-ext-deps*.deb' | grep $ext_deps_ver || find $downloads_dir -type f -iname 'vpp-ext-deps*.deb' | grep $ext_deps_ver || true)" + if [ -n "$ext_deps_pkg}" ] ; then + push_ext_deps_cmd="package_cloud push ${PCIO_CO}/${STREAM}/${distro}/${FACTER_LSBNAME}/main/ ${ext_deps_pkg}" + fi + else + echo "ERROR: Unknown distro: '$distro'" + return 1 + fi +} +create_rpm_push_cmds() +{ + FACTER_OSMAJREL=$(/usr/bin/facter operatingsystemmajrelease) + FACTER_ARCH=$(/usr/bin/facter architecture) + RPMS=$(find . -type f -iregex '.*/.*\.\(s\)?rpm' | grep -v vpp-ext-deps | xargs || true) + push_cmd="package_cloud push ${PCIO_CO}/${STREAM}/el/${FACTER_OSMAJREL}/os/${FACTER_ARCH}/ ${RPMS}" + ext_deps_ver="$(dnf list vpp-ext-deps | mawk '/vpp-ext-deps/{print $2}' || true)" + ext_deps_pkg="$(find . -type f -iname 'vpp-ext-deps*.rpm' | grep $ext_deps_ver || find $downloads_dir -type f -iname 'vpp-ext-deps*.rpm' | grep $ext_deps_ver || true)" + if [ -n "$ext_deps_pkg" ] ; then + push_ext_deps_cmd="package_cloud push ${PCIO_CO}/${STREAM}/el/${FACTER_OSMAJREL}/os/${FACTER_ARCH}/ ${ext_deps_pkg}" + fi +} + +# PCIO_CO and SILO are Jenkins Global Environment variables defined in +# .../ci-management/jenkins-config/global-vars-*.sh if [ -f ~/.packagecloud ]; then case "$FACTER_OS" in - Ubuntu) - FACTER_LSBNAME=$(/usr/bin/facter lsbdistcodename) - DEBS=$(find . -type f -iname '*.deb') - package_cloud push "${PCIO_CO}/${STREAM}/ubuntu/${FACTER_LSBNAME}/main/" ${DEBS} - ;; - CentOS) - FACTER_OSMAJREL=$(/usr/bin/facter operatingsystemmajrelease) - FACTER_ARCH=$(/usr/bin/facter architecture) - RPMS=$(find . -type f -iregex '.*/.*\.\(s\)?rpm') - package_cloud push "${PCIO_CO}/${STREAM}/el/${FACTER_OSMAJREL}/os/${FACTER_ARCH}/" ${RPMS} - ;; - openSUSE) - # Use /etc/os-release on openSUSE to get $VERSION - . /etc/os-release - RPMS=$(find . -type f -iregex '.*/.*\.\(s\)?rpm' | grep -v 'vpp-ext-deps') - VPP_EXT_RPMS=$(find . -type f -iregex '.*/.*\.\(s\)?rpm' | grep 'vpp-ext-deps') - package_cloud push "${PCIO_CO}/${STREAM}/opensuse/${VERSION}/" ${RPMS} - # This file may have already been uploaded. Don't error out if it exists. - package_cloud push "${PCIO_CO}/${STREAM}/opensuse/${VERSION}/" ${VPP_EXT_RPMS} --skip-errors - ;; + Debian) + create_deb_push_cmds debian + ;; + Ubuntu) + create_deb_push_cmds ubuntu + ;; + CentOS) + create_rpm_push_cmds + ;; + *) + echo -e "\n$line\n* ERROR: Unsupported OS '$FACTER_OS'\n* PACKAGECLOUD PUSH FAILED!\n$line\n" + exit 1 + ;; esac + if [ "${SILO,,}" = "sandbox" ] ; then + echo "SANDBOX: skipping '$push_cmd'" + if [ -n "$push_ext_deps_cmd" ] ; then + echo "SANDBOX: skipping '$push_ext_deps_cmd'" + fi + else + $push_cmd + if [ -n "$push_ext_deps_cmd" ] ; then + $push_ext_deps_cmd || true + fi + fi +else + echo "ERROR: Missing '~/.packagecloud' for user '$(id)'" + echo "PACKAGECLOUD PUSH FAILED!" + exit 1 fi + +echo -e "\n$line\n* PACKAGECLOUD PUSH COMPLETE\n$line\n" diff --git a/jjb/scripts/post_build_deploy_archives.sh b/jjb/scripts/post_build_deploy_archives.sh new file mode 100755 index 000000000..a332f21e5 --- /dev/null +++ b/jjb/scripts/post_build_deploy_archives.sh @@ -0,0 +1,93 @@ +#!/bin/bash + +# Copyright (c) 2021 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/post_build_deploy_archives.sh" + +set +e # Do not affect the build result if some part of archiving fails. +WS_ARCHIVES_DIR="$WORKSPACE/archives" +BUILD_ENV_LOG="$WS_ARCHIVES_DIR/_build-enviroment-variables.log" + +if curl --output robot-plugin.zip "$BUILD_URL/robot/report/*zip*/robot-plugin.zip"; then + unzip -d ./archives robot-plugin.zip +fi + +# Generate gdb-command script to output vpp stack traceback from core files. +gdb_cmdfile="/tmp/gdb-commands" +cat >$gdb_cmdfile <<'__END__' +# Usage: +# gdb $BINFILE $CORE -ex 'source -v gdb-commands' -ex quit + +set pagination off +thread apply all bt + +define printstack + set $i=0 + while $i < 15 + frame $i + x/i $pc + info locals + info reg + set $i = $i + 1 + end +end +thread apply all printstack + +# info proc mappings + +__END__ + +STACKTRACE="" +# Returns stacktrace filename in STACKTRACE +generate_vpp_stacktrace_and_delete_core() { + local corefile="$1" + echo "Uncompressing core file $file" + gunzip "$corefile" + corefile="${corefile::(-3)}" + if grep -qe 'debug' <<< "$WORKSPACE" ; then + local binfile="$WORKSPACE/build-root/install-vpp_debug-native/vpp/bin/vpp" + else + local binfile="$WORKSPACE/build-root/install-vpp-native/vpp/bin/vpp" + fi + + echo "Generating stack trace from core file: $corefile" + STACKTRACE="${corefile}.stacktrace" + gdb "$binfile" $corefile -ex 'source -v /tmp/gdb-commands' -ex quit > $STACKTRACE + # remove the core to save space + echo "Removing core file: $corefile" + rm -f "$corefile" + # Dump stacktrace to console log + if [ -f "$STACKTRACE" ] ; then + echo -e "\n=====[ $STACKTRACE ]=====\n$(cat $STACKTRACE)\n=====[ $STACKTRACE ]=====\n" + gzip "$STACKTRACE" + else + echo "Stacktrace file not generated!" + STACKTRACE="" + fi +} + +mkdir -p "$WS_ARCHIVES_DIR" + +# generate stack trace for VPP core files for upload instead of core file. +if [ -d "$WORKSPACE/build-root" ] ; then + for file in $(find $WS_ARCHIVES_DIR -type f -name 'core*.gz') ; do + generate_vpp_stacktrace_and_delete_core $file + done +fi + +# Remove any socket files in archive +find $WS_ARCHIVES_DIR -type s -exec rm -rf {} \; + +echo "Workspace archived artifacts:" +ls -alR $WS_ARCHIVES_DIR diff --git a/jjb/scripts/post_build_executor_info.sh b/jjb/scripts/post_build_executor_info.sh new file mode 100755 index 000000000..d81b613ed --- /dev/null +++ b/jjb/scripts/post_build_executor_info.sh @@ -0,0 +1,58 @@ +#!/bin/bash + +# Copyright (c) 2021 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/post_build_executor_info.sh" + +# Output executor runtime attributes [again] in case the job fails prior to +# running setup_executor_env.sh +long_line="************************************************************************" +OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_ARCH=$(uname -m) + +# Requires all nomad client machines to run the following command +# and mount /scratch/nomad into the docker container: +# sudo mkdir -p /scratch/nomad && echo "$(hostname)-$(uname -m)" | sudo tee /scratch/nomad/nomad-client +nomad_client_file="/scratch/nomad/nomad-client" +if [ -f "$nomad_client_file" ] ; then + NOMAD_CLIENT="$(cat $nomad_client_file)" +else + NOMAD_CLIENT="Unknown" +fi + +echo "$long_line" +echo "Executor Runtime Attributes:" +echo "OS: $OS_ID-$OS_VERSION_ID" +echo " $(uname -a)" +echo "Number CPUs: $(nproc)" +echo "Arch: $OS_ARCH" +echo "Nomad Client Hostname: $NOMAD_CLIENT" +echo "Container ID: $(hostname)" +echo "$long_line" +echo -e "lscpu:\n$(lscpu)" +echo "$long_line" +echo -e "df -h:\n$(df -h)" +echo "$long_line" +echo -e "free -m:\n$(free -m)" + +if [ -n "$(which ccache)" ] ; then + echo "$long_line" + echo "ccache statistics:" + [ -n "${CCACHE_DISABLE:-}" ] && echo "CCACHE_DISABLE = '$CCACHE_DISABLE'" + [ -n "${CCACHE_DIR:-}" ] && echo "CCACHE_DIR = '$CCACHE_DIR'" + ccache -s +fi + +echo "$long_line" diff --git a/jjb/scripts/publish_cov.sh b/jjb/scripts/publish_cov.sh new file mode 100644 index 000000000..cdbbcdd86 --- /dev/null +++ b/jjb/scripts/publish_cov.sh @@ -0,0 +1,51 @@ +#!/bin/bash + +# Copyright (c) 2023 Cisco and/or its affiliates. +# 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. + +echo "---> publish_cov.sh" + +set -exuo pipefail + +CDN_URL="s3-docs-7day.fd.io" +bucket="vpp-docs-7day-retention" +# Use the same bucket path as logs so that the code coverage report can be viewed by +# s/s3-logs/s3-docs-7day/ in the URL after selecting the logs URL from +# the jenkins job page. +bucket_path="$JENKINS_HOSTNAME/$JOB_NAME/$BUILD_NUMBER/" + +if [[ ${JOB_NAME} == *verify* ]]; then + case "${JOB_NAME}" in + *"vpp-cov"*) + workspace_dir="${WORKSPACE}/build-root/test-coverage/html" + ;; + *) + die "Unknown job: ${JOB_NAME}" + esac +else + die "Unknown job: ${JOB_NAME}" +fi + +export TF_VAR_workspace_dir="$workspace_dir" +export TF_VAR_bucket_path="$bucket_path" +export TF_VAR_bucket="$bucket" +export AWS_SHARED_CREDENTIALS_FILE=$HOME/.aws/credentials +export AWS_DEFAULT_REGION="us-east-1" + +echo "INFO: archiving test coverage to S3 bucket '$bucket'" +pushd .. +terraform init -no-color +terraform apply -no-color -auto-approve +popd + +echo "S3 Test Coverage: <a href=\"https://${CDN_URL}/${bucket_path}\">https://${CDN_URL}/${bucket_path}</a>" diff --git a/jjb/scripts/publish_docs.sh b/jjb/scripts/publish_docs.sh new file mode 100755 index 000000000..63bb5bc89 --- /dev/null +++ b/jjb/scripts/publish_docs.sh @@ -0,0 +1,83 @@ +#!/bin/bash + +# Copyright (c) 2022 Cisco and/or its affiliates. +# 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. + +echo "---> publish_docs.sh" + +set -exuo pipefail + +CDN_URL="s3-docs.fd.io" +bucket="fdio-docs-s3-cloudfront-index" + +if [[ ${JOB_NAME} == *merge* ]]; then + case "${JOB_NAME}" in + *"csit-trending"*) + workspace_dir="${WORKSPACE}/resources/tools/presentation/_build" + bucket_path="/csit/${GERRIT_BRANCH}/trending/" + ;; + *"csit-report"*) + workspace_dir="${WORKSPACE}/resources/tools/presentation/_build" + bucket_path="/csit/${GERRIT_BRANCH}/report/" + ;; + *"csit-docs"*) + workspace_dir="${WORKSPACE}/resources/tools/doc_gen/_build" + bucket_path="/csit/${GERRIT_BRANCH}/docs/" + ;; + *"hicn-docs"*) + hicn_release="$(git describe --long --match "v*" | cut -d- -f1 | sed -e 's/^v//')" + workspace_dir="${WORKSPACE}/build/doc/deploy-site" + bucket_path="/hicn/${hicn_release}/" + ;; + *"vpp-docs"*) + vpp_release="$(${WORKSPACE}/build-root/scripts/version rpm-version)" + workspace_dir="${WORKSPACE}/build-root/docs/html" + bucket_path="/vpp/${vpp_release}/" + ;; + *) + die "Unknown job: ${JOB_NAME}" + esac +elif [[ ${JOB_NAME} == *verify* ]]; then + bucket="vpp-docs-7day-retention" + # Use the same bucket path as logs so that the docs can be viewed by + # s/s3-logs/s3-docs-7day/ in the URL after selecting the logs URL from + # the jenkins job page. + bucket_path="$JENKINS_HOSTNAME/$JOB_NAME/$BUILD_NUMBER/" + case "${JOB_NAME}" in + *"hicn-docs"*) + workspace_dir="${WORKSPACE}/build/doc/deploy-site" + ;; + *"vpp-docs"*) + CDN_URL="s3-docs-7day.fd.io" + workspace_dir="${WORKSPACE}/build-root/docs/html" + ;; + *) + die "Unknown job: ${JOB_NAME}" + esac +else + die "Unknown job: ${JOB_NAME}" +fi + +export TF_VAR_workspace_dir="$workspace_dir" +export TF_VAR_bucket_path="$bucket_path" +export TF_VAR_bucket="$bucket" +export AWS_SHARED_CREDENTIALS_FILE=$HOME/.aws/credentials +export AWS_DEFAULT_REGION="us-east-1" + +echo "INFO: archiving docs to S3 bucket '$bucket'" +pushd .. +terraform init -no-color +terraform apply -no-color -auto-approve +popd + +echo "S3 docs: <a href=\"https://${CDN_URL}/${bucket_path}\">https://${CDN_URL}/${bucket_path}</a>" diff --git a/jjb/scripts/publish_library_py.sh b/jjb/scripts/publish_library_py.sh new file mode 100644 index 000000000..1cbeb23c0 --- /dev/null +++ b/jjb/scripts/publish_library_py.sh @@ -0,0 +1,318 @@ +#!/bin/bash + +# Copyright (c) 2021 Cisco and/or its affiliates. +# 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. + +echo "---> publish_library_py.sh" + +set -exuo pipefail + +PYTHON_SCRIPT="/w/workspace/publish_library.py" + +pip3 install boto3 +mkdir -p $(dirname "$PYTHON_SCRIPT") + +cat >$PYTHON_SCRIPT <<'END_OF_PYTHON_SCRIPT' +#!/usr/bin/python3 + +"""S3 publish library.""" + +import glob +import gzip +import logging +import os +import shutil +import subprocess +import sys +import tempfile + +import boto3 +from botocore.exceptions import ClientError +import requests +import six + + +logging.basicConfig( + format=u"%(levelname)s: %(message)s", + stream=sys.stdout, + level=logging.INFO +) +logging.getLogger(u"botocore").setLevel(logging.INFO) + + +FILE_TYPE = { + u"xml": u"application/xml", + u"html": u"text/html", + u"txt": u"text/plain", + u"log": u"text/plain", + u"css": u"text/css", + u"md": u"text/markdown", + u"rst": u"text/x-rst", + u"csv": u"text/csv", + u"svg": u"image/svg+xml", + u"jpg": u"image/jpeg", + u"png": u"image/png", + u"gif": u"image/gif", + u"js": u"application/javascript", + u"pdf": u"application/pdf", + u"json": u"application/json", + u"otf": u"font/otf", + u"ttf": u"font/ttf", + u"woff": u"font/woff", + u"woff2": u"font/woff2" +} + + +def compress_text(src_dpath): + """Compress all text files in directory. + + :param src_dpath: Input dir path. + :type src_dpath: str + """ + save_dir = os.getcwd() + os.chdir(src_dpath) + + compress_types = [ + "**/*.html", + "**/*.log", + "**/*.txt", + "**/*.xml", + "**/*.json" + ] + paths = [] + for _type in compress_types: + search = os.path.join(src_dpath, _type) + paths.extend(glob.glob(search, recursive=True)) + + for _file in paths: + # glob may follow symlink paths that open can't find + if os.path.exists(_file): + gz_file = u"{}.gz".format(_file) + with open(_file, "rb") as src, gzip.open(gz_file, "wb") as dest: + shutil.copyfileobj(src, dest) + os.remove(_file) + + os.chdir(save_dir) + + +def copy_archives(workspace): + """Copy files or directories in a $WORKSPACE/archives to the current + directory. + + :params workspace: Workspace directery with archives directory. + :type workspace: str + """ + archives_dir = os.path.join(workspace, u"archives") + dest_dir = os.getcwd() + + logging.debug(u"Copying files from " + archives_dir + u" to " + dest_dir) + + if os.path.exists(archives_dir): + if os.path.isfile(archives_dir): + logging.error(u"Target is a file, not a directory.") + raise RuntimeError(u"Not a directory.") + else: + logging.debug("Archives dir {} does exist.".format(archives_dir)) + for item in os.listdir(archives_dir): + src = os.path.join(archives_dir, item) + dst = os.path.join(dest_dir, item) + try: + if os.path.isdir(src): + shutil.copytree(src, dst, symlinks=False, ignore=None) + else: + shutil.copy2(src, dst) + except shutil.Error as e: + logging.error(e) + raise RuntimeError(u"Could not copy " + src) + else: + logging.error(u"Archives dir does not exist.") + raise RuntimeError(u"Missing directory " + archives_dir) + + +def upload(s3_resource, s3_bucket, src_fpath, s3_path): + """Upload single file to destination bucket. + + :param s3_resource: S3 storage resource. + :param s3_bucket: S3 bucket name. + :param src_fpath: Input file path. + :param s3_path: Destination file path on remote storage. + :type s3_resource: Object + :type s3_bucket: str + :type src_fpath: str + :type s3_path: str + """ + def is_gzip_file(filepath): + with open(filepath, u"rb") as test_f: + return test_f.read(2) == b"\x1f\x8b" + + if os.path.isdir(src_fpath): + return + if os.path.isfile(src_fpath): + file_name, file_extension = os.path.splitext(src_fpath) + content_encoding = u"" + content_type = u"application/octet-stream" + if is_gzip_file(src_fpath): + file_name, file_extension = os.path.splitext(file_name) + content_encoding = "gzip" + content_type = FILE_TYPE.get( + file_extension.strip("."), + u"application/octet-stream" + ) + + extra_args = dict() + extra_args[u"ContentType"] = content_type + if content_encoding: + extra_args[u"ContentEncoding"] = content_encoding + + try: + s3_resource.Bucket(s3_bucket).upload_file( + src_fpath, s3_path, ExtraArgs=extra_args + ) + logging.info(u"Successfully uploaded to " + s3_path) + except ClientError as e: + logging.error(e) + + +def upload_recursive(s3_resource, s3_bucket, src_fpath, s3_path): + """Recursively uploads input folder to destination. + + Example: + - s3_bucket: logs.fd.io + - src_fpath: /workspace/archives. + - s3_path: /hostname/job/id/ + + :param s3_resource: S3 storage resource. + :param s3_bucket: S3 bucket name. + :param src_fpath: Input folder path. + :param s3_path: S3 destination path. + :type s3_resource: Object + :type s3_bucket: str + :type src_fpath: str + :type s3_path: str + """ + for path, _, files in os.walk(src_fpath): + for file in files: + _path = path.replace(src_fpath, u"") + _src_fpath = path + u"/" + file + _s3_path = os.path.normpath(s3_path + u"/" + _path + u"/" + file) + upload( + s3_resource=s3_resource, + s3_bucket=s3_bucket, + src_fpath=_src_fpath, + s3_path=_s3_path + ) + + +def deploy_docs(s3_bucket, s3_path, docs_dir): + """Ship docs dir content to S3 bucket. Requires the s3 bucket to exist. + + :param s3_bucket: Name of S3 bucket. Eg: lf-project-date + :param s3_path: Path on S3 bucket to place the docs. Eg: + csit/${GERRIT_BRANCH}/report + :param docs_dir: Directory in which to recursively upload content. + :type s3_bucket: Object + :type s3_path: str + :type docs_dir: str + """ + try: + s3_resource = boto3.resource( + u"s3", + endpoint_url=os.environ[u"AWS_ENDPOINT_URL"] + ) + except KeyError: + s3_resource = boto3.resource( + u"s3" + ) + + upload_recursive( + s3_resource=s3_resource, + s3_bucket=s3_bucket, + src_fpath=docs_dir, + s3_path=s3_path + ) + + +def deploy_s3(s3_bucket, s3_path, build_url, workspace): + """Add logs and archives to temp directory to be shipped to S3 bucket. + Fetches logs and system information and pushes them and archives to S3 + for log archiving. + Requires the s3 bucket to exist. + + :param s3_bucket: Name of S3 bucket. Eg: lf-project-date + :param s3_path: Path on S3 bucket place the logs and archives. Eg: + $JENKINS_HOSTNAME/$JOB_NAME/$BUILD_NUMBER + :param build_url: URL of the Jenkins build. Jenkins typically provides this + via the $BUILD_URL environment variable. + :param workspace: Directory in which to search, typically in Jenkins this is + $WORKSPACE + :type s3_bucket: Object + :type s3_path: str + :type build_url: str + :type workspace: str + """ + try: + s3_resource = boto3.resource( + u"s3", + endpoint_url=os.environ[u"AWS_ENDPOINT_URL"] + ) + except KeyError: + s3_resource = boto3.resource( + u"s3" + ) + + previous_dir = os.getcwd() + work_dir = tempfile.mkdtemp(prefix="backup-s3.") + os.chdir(work_dir) + + # Copy archive files to tmp dir. + copy_archives(workspace) + + # Create additional build logs. + with open(u"_build-details.log", u"w+") as f: + f.write(u"build-url: " + build_url) + + # Magic string used to trim console logs at the appropriate level during + # wget. + MAGIC_STRING = u"-----END_OF_BUILD-----" + logging.info(MAGIC_STRING) + + resp = requests.get(build_url + u"/consoleText") + with open(u"console.log", u"w+", encoding=u"utf-8") as f: + f.write( + six.text_type(resp.content.decode(u"utf-8").split(MAGIC_STRING)[0]) + ) + + query = u"time=HH:mm:ss&appendLog" + resp = requests.get(build_url + u"/timestamps?" + query) + with open(u"console-timestamp.log", u"w+", encoding=u"utf-8") as f: + f.write( + six.text_type(resp.content.decode(u"utf-8").split(MAGIC_STRING)[0]) + ) + + compress_text(work_dir) + + upload_recursive( + s3_resource=s3_resource, + s3_bucket=s3_bucket, + src_fpath=work_dir, + s3_path=s3_path + ) + + os.chdir(previous_dir) + shutil.rmtree(work_dir) + + +if __name__ == u"__main__": + globals()[sys.argv[1]](*sys.argv[2:]) + +END_OF_PYTHON_SCRIPT diff --git a/jjb/scripts/csit/nsh_sfc-perf-hw.sh b/jjb/scripts/publish_logs.sh index 6f2eb3bdd..a567106ad 100644 --- a/jjb/scripts/csit/nsh_sfc-perf-hw.sh +++ b/jjb/scripts/publish_logs.sh @@ -1,6 +1,6 @@ #!/bin/bash -# Copyright (c) 2020 Cisco and/or its affiliates. +# Copyright (c) 2021 Cisco and/or its affiliates. # 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: @@ -13,20 +13,18 @@ # See the License for the specific language governing permissions and # limitations under the License. -# execute nsh_sfc bootstrap script if it exists -if [ ! -e bootstrap-verify-perf-nsh_sfc.sh ] -then - echo 'ERROR: No bootstrap-verify-perf-nsh_sfc.sh found' - exit 1 -fi - -# make sure that bootstrap-verify-perf.sh is executable -chmod +x bootstrap-verify-perf-nsh_sfc.sh -# run the script -if [ ${STREAM} == 'master' ]; then - ./bootstrap-verify-perf-nsh_sfc.sh ${STREAM} ${OS} -else - ./bootstrap-verify-perf-nsh_sfc.sh 'stable.'${STREAM} ${OS} -fi - -# vim: ts=4 ts=4 sts=4 et : +echo "---> publish_logs.sh" + +PYTHON_SCRIPT="/w/workspace/publish_library.py" + +mkdir -p "$WORKSPACE/archives" + +s3_path="$JENKINS_HOSTNAME/$JOB_NAME/$BUILD_NUMBER/" + +echo "INFO: S3 path $s3_path" + +echo "INFO: archiving logs to S3" +python3 $PYTHON_SCRIPT deploy_s3 "$S3_BUCKET" "$s3_path" \ + "$BUILD_URL" "$WORKSPACE" + +echo "S3 build logs: <a href=\"https://$CDN_URL/$s3_path\">https://$CDN_URL/$s3_path</a>" diff --git a/jjb/scripts/setup_executor_env.sh b/jjb/scripts/setup_executor_env.sh new file mode 100755 index 000000000..727824909 --- /dev/null +++ b/jjb/scripts/setup_executor_env.sh @@ -0,0 +1,119 @@ +#!/bin/bash + +# Copyright (c) 2020 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/setup_executor_env.sh" + +set -e -o pipefail + +OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_ARCH=$(uname -m) +dockerfile="/scratch/docker-build/Dockerfile" +file_delimiter="----- %< -----" +long_line="************************************************************************" +downloads_cache="/root/Downloads" + +# Requires all nomad client machines to run the following command +# and mount /scratch/nomad into the docker container: +# sudo mkdir -p /scratch/nomad && echo "$(hostname)-$(uname -m)" | sudo tee /scratch/nomad/nomad-client +nomad_client_file="/scratch/nomad/nomad-client" +if [ -f "$nomad_client_file" ] ; then + NOMAD_CLIENT="$(cat $nomad_client_file)" +else + NOMAD_CLIENT="Unknown" +fi + +# Node info +echo "$long_line" +echo "Executor Runtime Attributes:" +echo "OS: $OS_ID-$OS_VERSION_ID" +echo "Arch: $OS_ARCH" +echo "Nomad Client Hostname: $NOMAD_CLIENT" +echo "Container ID: $(hostname)" + +echo "$long_line" +if [ -f "$dockerfile" ] ; then + echo -e "Executor Dockerfile: ${dockerfile}\n${file_delimiter}" + cat $dockerfile + echo "$file_delimiter" +else + echo "Unknown Executor: '$dockerfile' not found!" +fi + +# Performance analysis +perf_trials=2 +perf_interval=1 +if [ "$OS_ID" == "ubuntu" ] || [ "$OS_ID" = "debian" ] ; then + SYSSTAT_PATH="/var/log/sysstat" +elif [ "$OS_ID" == "centos" ] ; then + if [ "$OS_VERSION_ID" = "7" ] ; then + SYSSTAT_PATH="/var/log/sa/sa02" + else + SYSSTAT_PATH="/var/log/sa" + fi +fi +echo "$long_line" +echo "Virtual memory stat" +vmstat ${perf_interval} ${perf_trials} +echo "CPU time breakdowns per CPU" +mpstat -P ALL ${perf_interval} ${perf_trials} +echo "Per-process summary" +pidstat ${perf_interval} ${perf_trials} +echo "Block device stats" +iostat -xz ${perf_interval} ${perf_trials} +echo "Memory utilization" +free -m +echo "Network interface throughput" +sar -n DEV -o ${SYSSTAT_PATH} ${perf_interval} ${perf_trials} +echo "TCP metrics" +sar -n TCP,ETCP -o ${SYSSTAT_PATH} ${perf_interval} ${perf_trials} + +# SW stack +echo "$long_line" +echo "Executor package list:" +if [ "$OS_ID" == "ubuntu" ] || [ "$OS_ID" = "debian" ] ; then + dpkg-query -W -f='${binary:Package}\t${Version}\n' | column -t || true +elif [ "$OS_ID" == "centos" ] ; then + yum list installed || true +fi + +echo "$long_line" +echo "Python3 package list:" +pip3 list 2>/dev/null | column -t || true + +echo "$long_line" +echo "Executor Downloads cache '$downloads_cache':" +ls -lh "$downloads_cache" || true + +echo "$long_line" +echo "DNS nameserver config in '/etc/resolv.conf':" +cat /etc/resolv.conf || true + +echo "$long_line" +if [ -n "$(which ccache || true)" ] ; then + if [ -z "${CCACHE_DIR:-}" ] || [ ! -d "$CCACHE_DIR" ] ; then + echo "CCACHE_DIR='$CCACHE_DIR' is missing, disabling CCACHE..." + export CCACHE_DISABLE="1" + fi + if [ -n "${CCACHE_DISABLE:-}" ] ; then + echo "CCACHE_DISABLE = '$CCACHE_DISABLE'" + fi + echo "ccache statistics:" + ccache -s +else + echo "WARNING: ccache is not installed!" + export CCACHE_DISABLE="1" +fi +echo "$long_line" diff --git a/jjb/scripts/setup_jvpp_dev_env.sh b/jjb/scripts/setup_jvpp_dev_env.sh deleted file mode 100644 index 9017f0db6..000000000 --- a/jjb/scripts/setup_jvpp_dev_env.sh +++ /dev/null @@ -1,58 +0,0 @@ -#!/bin/bash -set -e -o pipefail - -# Figure out what system we are running on -if [[ -f /etc/lsb-release ]];then - . /etc/lsb-release -elif [[ -f /etc/redhat-release ]];then - sudo yum install -y redhat-lsb - DISTRIB_ID=`lsb_release -si` - DISTRIB_RELEASE=`lsb_release -sr` - DISTRIB_CODENAME=`lsb_release -sc` - DISTRIB_DESCRIPTION=`lsb_release -sd` -fi -echo DISTRIB_ID: $DISTRIB_ID -echo DISTRIB_RELEASE: $DISTRIB_RELEASE -echo DISTRIB_CODENAME: $DISTRIB_CODENAME -echo DISTRIB_DESCRIPTION: $DISTRIB_DESCRIPTION - -JVPP_VERSION=`./version` -echo JVPP_VERSION: $JVPP_VERSION -# Check release version -if [[ "$JVPP_VERSION" == *"-release" ]]; then - # at the time when JVPP release packages are being build, - # vpp release packages are already promoted to release repository. - # Therefore we need to switch to release repository in order to download - # correct vpp package versions - STREAM="release" -fi - -function setup { - if ! [[ -z ${REPO_NAME} ]]; then - echo "INSTALLING VPP-DPKG-DEV from apt/yum repo" - REPO_URL="https://packagecloud.io/fdio/${STREAM}" - echo "REPO_URL: ${REPO_URL}" - # Setup by installing vpp-dev and vpp-lib - if [[ "$DISTRIB_ID" == "Ubuntu" ]]; then - if ! [[ "${STREAM}" == "master" ]]; then - echo "stable branch - clearing all fdio repos. new one will be installed." - sudo rm -f /etc/apt/sources.list.d/fdio_*.list - fi - if [[ -f /etc/apt/sources.list.d/99fd.io.list ]];then - echo "Deleting: /etc/apt/sources.list.d/99fd.io.list" - sudo rm /etc/apt/sources.list.d/99fd.io.list - fi - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.deb.sh | sudo bash - sudo apt-get -y --force-yes install libvppinfra libvppinfra-dev vpp vpp-dev vpp-plugin-core || true - elif [[ "$DISTRIB_ID" == "CentOS" ]]; then - if [[ -f /etc/yum.repos.d/fdio-master.repo ]]; then - echo "Deleting: /etc/yum.repos.d/fdio-master.repo" - sudo rm /etc/yum.repos.d/fdio-master.repo - fi - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.rpm.sh | sudo bash - sudo yum -y install vpp-devel vpp-lib vpp-plugins || true - fi - fi -} - -setup
\ No newline at end of file diff --git a/jjb/scripts/setup_vpp_dpdk_dev_env.sh b/jjb/scripts/setup_vpp_dpdk_dev_env.sh deleted file mode 100644 index c98f6def4..000000000 --- a/jjb/scripts/setup_vpp_dpdk_dev_env.sh +++ /dev/null @@ -1,69 +0,0 @@ -#!/bin/bash -set -e -o pipefail - -OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') -OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') - -function setup { - if ! [ -z ${REPO_NAME} ]; then - echo "INSTALLING VPP-DPKG-DEV from apt/yum repo" - REPO_URL="https://packagecloud.io/fdio/${STREAM}" - echo "REPO_URL: ${REPO_URL}" - # Setup by installing vpp-dev and vpp-lib - if [ "$OS_ID" == "ubuntu" ]; then - if ! [ "${STREAM}" == "master" ]; then - echo "tree not master deleting packagecloud repo pointer" - sudo rm -f /etc/apt/sources.list.d/fdio_master.list - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.deb.sh | sudo bash - fi - if [ -f /etc/apt/sources.list.d/99fd.io.list ];then - echo "Deleting: /etc/apt/sources.list.d/99fd.io.list" - sudo rm /etc/apt/sources.list.d/99fd.io.list - fi - sudo apt-get update -qq || true - sudo apt-get -y --force-yes install vpp-dpdk-dev || true - sudo apt-get -y --force-yes install vpp-dpdk-dkms || true - sudo apt-get -y --force-yes install vpp-ext-deps || true - elif [ "$OS_ID" == "centos" ]; then - if [ -f /etc/yum.repos.d/fdio-master.repo ]; then - echo "Deleting: /etc/yum.repos.d/fdio-master.repo" - sudo rm /etc/yum.repos.d/fdio-master.repo - fi - if ! [ "${STREAM}" == "master" ]; then - echo "tree not master deleting packagecloud repo pointer" - sudo rm -f /etc/yum.repos.d/fdio_master.repo - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.rpm.sh | sudo bash - fi - sudo yum -y install vpp-dpdk-devel || true - sudo yum -y install vpp-ext-deps || true - elif [ "$OS_ID" == "opensuse" ]; then - REPO_URL="${NEXUSPROXY}/content/repositories/fd.io.${REPO_NAME}" - echo "REPO_URL: ${REPO_URL}" - sudo cat << EOF > fdio-master.repo -[fdio-master] -name=fd.io master branch latest merge -baseurl=${REPO_URL} -enabled=1 -gpgcheck=0 -EOF - sudo mv fdio-master.repo /etc/yum/repos.d/fdio-master.repo - sudo yum -y install vpp-dpdk-devel || true - sudo yum -y install vpp-ext-deps || true - elif [ "$OS_ID" == "opensuse-leap" ]; then - REPO_URL="${NEXUSPROXY}/content/repositories/fd.io.${REPO_NAME}" - echo "REPO_URL: ${REPO_URL}" - sudo cat << EOF > fdio-master.repo -[fdio-master] -name=fd.io master branch latest merge -baseurl=${REPO_URL} -enabled=1 -gpgcheck=0 -EOF - sudo mv fdio-master.repo /etc/yum/repos.d/fdio-master.repo - sudo yum -y install vpp-dpdk-devel || true - sudo yum -y install vpp-ext-deps || true - fi - fi -} - -setup diff --git a/jjb/scripts/setup_vpp_ext_deps.sh b/jjb/scripts/setup_vpp_ext_deps.sh new file mode 100755 index 000000000..077dca163 --- /dev/null +++ b/jjb/scripts/setup_vpp_ext_deps.sh @@ -0,0 +1,67 @@ +#!/bin/bash + +# Copyright (c) 2022 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/setup_vpp_ext_deps.sh" + +# Normally we would have the settings in any bash script stricter: +# set -e -o pipefail +# +# But there is a corner case scenario that triggers an error, +# namely when a new packagecloud repo is created, it is completely +# empty. Then the installation fails. However, since this +# script is an optimization, it is okay for it to fail without failing +# the entire job. +# +# Therefore, we do not use the "-e" here. + +set -o pipefail + +OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') + +echo "Installing vpp-ext-deps..." +REPO_URL="https://packagecloud.io/fdio/${STREAM}" +echo "REPO_URL: $REPO_URL" +INSTALL_URL="https://packagecloud.io/install/repositories/fdio/${STREAM}" +echo "INSTALL_URL: $INSTALL_URL" + +downloads_dir="/root/Downloads" + +# Setup by installing vpp-dev and vpp-lib +if [ "${OS_ID,,}" == "ubuntu" ] || [ "${OS_ID,,}" == "debian" ] ; then + if [ "${STREAM}" != "master" ]; then + echo "stream '${STREAM}' is not master: replacing packagecloud apt sources list with stream specific list" + sudo apt-get -y remove vpp-ext-deps || true + sudo rm -f /etc/apt/sources.list.d/fdio_master.list + curl -s $INSTALL_URL/script.deb.sh | sudo bash || true + fi + sudo apt-get update -qq || true + vpp_ext_deps_version="$(apt-cache show vpp-ext-deps | mawk '/Version/ {print $2}' | head -1)" + vpp_ext_deps_arch="$(apt-cache show vpp-ext-deps | mawk '/Architecture/ {print $2}' | head -1)" + vpp_ext_deps_pkg="vpp-ext-deps_${vpp_ext_deps_version}_${vpp_ext_deps_arch}.deb" + if [ -f "$downloads_dir/$vpp_ext_deps_pkg" ] ; then + echo "Installing cached vpp-ext-deps pkg: $downloads_dir/$vpp_ext_deps_pkg" + sudo dpkg -i "$downloads_dir/$vpp_ext_deps_pkg" || true + else + echo "Installing vpp-ext-deps from packagecloud.io" + force_opts="--allow-downgrades --allow-remove-essential --allow-change-held-packages" + sudo apt-get -y $force_opts install vpp-ext-deps || true + fi + echo "Removing packagecloud.io repository references and running apt-get update" + sudo rm -f /etc/apt/sources.list.d/fdio_*.list + sudo apt-get update -qq || true +else + echo "ERROR: Unsupported OS '$OS_ID'!" +fi diff --git a/jjb/scripts/setup_vpp_plugin_dev_env.sh b/jjb/scripts/setup_vpp_plugin_dev_env.sh deleted file mode 100644 index 1b92adb84..000000000 --- a/jjb/scripts/setup_vpp_plugin_dev_env.sh +++ /dev/null @@ -1,43 +0,0 @@ -#!/bin/bash -set -e -o pipefail - -#!/bin/bash -set -e -o pipefail - -# Figure out what system we are running on -if [ -f /etc/lsb-release ];then - . /etc/lsb-release -elif [ -f /etc/redhat-release ];then - sudo yum install -y redhat-lsb - DISTRIB_ID=`lsb_release -si` - DISTRIB_RELEASE=`lsb_release -sr` - DISTRIB_CODENAME=`lsb_release -sc` - DISTRIB_DESCRIPTION=`lsb_release -sd` -fi -echo DISTRIB_ID: $DISTRIB_ID -echo DISTRIB_RELEASE: $DISTRIB_RELEASE -echo DISTRIB_CODENAME: $DISTRIB_CODENAME -echo DISTRIB_DESCRIPTION: $DISTRIB_DESCRIPTION - -function setup { - REPO_URL="${NEXUSPROXY}/content/repositories/fd.io.${REPO_NAME}" - echo "REPO_URL: ${REPO_URL}" - # Setup by installing vpp-dev and vpp-lib - if [ $DISTRIB_ID == "Ubuntu" ]; then - echo "deb ${REPO_URL} ./" | sudo tee /etc/apt/sources.list.d/99fd.io.list - sudo apt-get update - sudo apt-get -y --force-yes install vpp-dev vpp-lib - elif [[ $DISTRIB_ID == "CentOS" ]]; then - sudo cat << EOF > fdio-master.repo -[fdio-master] -name=fd.io master branch latest merge -baseurl=${REPO_URL} -enabled=1 -gpgcheck=0 -EOF - sudo mv fdio-master.repo /etc/yum.repos.d/fdio-master.repo - sudo yum -y install vpp-devel vpp-lib - fi -} - -setup
\ No newline at end of file diff --git a/jjb/scripts/setup_vpp_ubuntu_docker_test.sh b/jjb/scripts/setup_vpp_ubuntu_docker_test.sh index bdc1257f6..548ac5660 100644..100755 --- a/jjb/scripts/setup_vpp_ubuntu_docker_test.sh +++ b/jjb/scripts/setup_vpp_ubuntu_docker_test.sh @@ -1,17 +1,22 @@ #!/bin/bash + ############################################################################## -# Copyright (c) 2018 The Linux Foundation and others. +# Copyright (c) 2021 The Linux Foundation 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 "---> jjb/scripts/setup_vpp_ubuntu_docker_test.sh" + set -e -o pipefail OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') -if ! [ -z ${DOCKER_TEST} ] ; then +if [ -n ${DOCKER_TEST} ] ; then # for 4 cores: # framework.VppTestCase.MIN_REQ_SHM + (num_cores * framework.VppTestCase.SHM_PER_PROCESS) # 1073741824 == 1024M (1073741824 >> 20) @@ -22,55 +27,6 @@ if ! [ -z ${DOCKER_TEST} ] ; then # that 2048M is enough MEM=2048M fi - sudo mount -o remount /dev/shm -o size=${MEM} || true - echo "/dev/shm remounted" -fi - -##container server node detection -grep search /etc/resolv.conf || true - -if [ "${OS_ID}" == "ubuntu" ]; then - dpkg-query -W -f='${binary:Package}\t${Version}\n' || true - echo "************************************************************************" - echo "pip list:" - pip list || true - echo "************************************************************************" - echo "Contents of /var/cache/vpp/python/virtualenv/lib/python2.7/site-packages:" - ls -lth /var/cache/vpp/python/virtualenv/lib/python2.7/site-packages || true - echo "************************************************************************" - echo "Contents of br Downloads:" - ls -lth /w/Downloads || true - echo "************************************************************************" - echo "Contents of /w/dpdk for test folks:" - echo "************************************************************************" - ls -lth /w/dpdk || true -elif [ "${OS_ID}" == "centos" ]; then - yum list installed || true - pip list || true -elif [ "${OS_ID}" == "opensuse" ]; then - yum list installed || true - pip list || true -elif [ "${OS_ID}" == "opensuse-leap" ]; then - yum list installed || true - pip list || true -fi - -##This will remove any previously installed dpdk for old branch builds - -if [ "${GERRIT_BRANCH}" != "master" ]; then - if [ "${OS_ID}" == "ubuntu" ]; then - sudo apt-get -y remove vpp-dpdk-dev || true - sudo apt-get -y remove vpp-dpdk-dkms || true - sudo apt-get -y remove vpp-ext-deps || true - elif [ "${OS_ID}" == "centos" ]; then - sudo yum -y erase vpp-dpdk-devel || true - sudo yum -y erase vpp-ext-deps || true - sudo yum clean all || true - elif [ "${OS_ID}" == "opensuse" ]; then - sudo yum -y erase vpp-dpdk-devel || true - sudo yum -y erase vpp-ext-deps || true - elif [ "${OS_ID}" == "opensuse-leap" ]; then - sudo yum -y erase vpp-dpdk-devel || true - sudo yum -y erase vpp-ext-deps || true - fi + sudo mount -o remount /dev/shm -o size=${MEM} || true + echo "/dev/shm remounted with size='${MEM}'" fi diff --git a/jjb/scripts/terraform_s3_docs_ship.sh b/jjb/scripts/terraform_s3_docs_ship.sh new file mode 100644 index 000000000..7b2542ae4 --- /dev/null +++ b/jjb/scripts/terraform_s3_docs_ship.sh @@ -0,0 +1,99 @@ +#!/bin/bash + +# Copyright (c) 2021 Cisco and/or its affiliates. +# 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. + +echo "---> terraform_s3_docs_ship.sh" + +set -exuo pipefail + +cat >"/w/workspace/main.tf" <<'END_OF_TERRAFORM_SCRIPT' +terraform { + required_providers { + aws = { + source = "hashicorp/aws" + version = "5.18.1" + } + } +} + +provider "aws" { + region = "us-east-1" + profile = "default" + s3_use_path_style = false + skip_credentials_validation = true + skip_metadata_api_check = true + skip_requesting_account_id = true +} + +locals { + mime_types = { + xml = "application/xml", + html = "text/html", + txt = "text/plain", + log = "text/plain", + css = "text/css", + md = "text/markdown", + rst = "text/x-rst", + csv = "text/csv", + svg = "image/svg+xml", + jpg = "image/jpeg", + png = "image/png", + gif = "image/gif", + js = "application/javascript", + pdf = "application/pdf" + json = "application/json", + otf = "font/otf", + ttf = "font/ttf", + woff = "font/woff", + woff2 = "font/woff2" + } +} + +variable "workspace_dir" { + description = "Workspace base directory" + type = string +} + +variable "file_match_pattern" { + description = "File matching pattern" + type = string + default = "**/*" +} + +variable "bucket" { + description = "S3 bucket name" + type = string +} + +variable "bucket_path" { + description = "S3 bucket path to key" + type = string +} + +resource "aws_s3_bucket_object" "object" { + for_each = fileset(var.workspace_dir, var.file_match_pattern) + + bucket = var.bucket + key = "${var.bucket_path}${each.value}" + source = "${var.workspace_dir}/${each.value}" + + cache_control = "no-store,max-age=0,s-maxage=0" + etag = filemd5("${var.workspace_dir}/${each.value}") + content_type = lookup( + local.mime_types, + regex("\\.(?P<extension>[A-Za-z0-9]+)$", each.value).extension, + "application/octet-stream" + ) +} +END_OF_TERRAFORM_SCRIPT diff --git a/jjb/scripts/vpp/api-checkstyle.sh b/jjb/scripts/vpp/api-checkstyle.sh index 90740337e..a1c2f84a1 100644 --- a/jjb/scripts/vpp/api-checkstyle.sh +++ b/jjb/scripts/vpp/api-checkstyle.sh @@ -1,5 +1,20 @@ #!/bin/bash +# Copyright (c) 2020 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/vpp/api-checkstyle.sh" + VPP_CRC_CHECKER="extras/scripts/crcchecker.py" VPP_CRC_CHECKER_CMD="$VPP_CRC_CHECKER --check-patchset" @@ -11,13 +26,12 @@ send_notify() { } if [ -f $VPP_CRC_CHECKER ]; then + # API checker complains if the git repo is not clean. + # Help diagnosing those issues easier + git --no-pager diff echo "Running $VPP_CRC_CHECKER_CMD" if $VPP_CRC_CHECKER_CMD; then echo "API check successful" - - # for now - notify the same room during the monitoring period about the successes as well - WEBEX_TEAMS_MESSAGE="API check successful for $GERRIT_REFSPEC - see $BUILD_URL" - send_notify else RET_CODE=$? echo "API check failed: ret code $RET_CODE; please read https://wiki.fd.io/view/VPP/ApiChangeProcess and discuss with ayourtch@gmail.com if unsure how to proceed" diff --git a/jjb/scripts/vpp/build.sh b/jjb/scripts/vpp/build.sh index 68fa30d1a..850d61003 100644 --- a/jjb/scripts/vpp/build.sh +++ b/jjb/scripts/vpp/build.sh @@ -1,90 +1,139 @@ #!/bin/bash -# basic build script example -set -xe -o pipefail -OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') -OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +# Copyright (c) 2021 Cisco and/or its affiliates. +# 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. -echo OS_ID: $OS_ID -echo OS_VERSION_ID: $OS_VERSION_ID +echo "---> jjb/scripts/vpp/build.sh" -# do nothing but print the current slave hostname -hostname -export CCACHE_DIR=/tmp/ccache -if [ -d $CCACHE_DIR ];then - echo $CCACHE_DIR exists - du -sk $CCACHE_DIR -else - echo $CCACHE_DIR does not exist. This must be a new slave. -fi - -echo "cat /etc/bootstrap.sha" -if [ -f /etc/bootstrap.sha ];then - cat /etc/bootstrap.sha -else - echo "Cannot find cat /etc/bootstrap.sha" -fi +set -euxo pipefail -echo "cat /etc/bootstrap-functions.sha" -if [ -f /etc/bootstrap-functions.sha ];then - cat /etc/bootstrap-functions.sha -else - echo "Cannot find cat /etc/bootstrap-functions.sha" +line="*************************************************************************" +# Don't build anything if this is a merge job being run when +# the git HEAD id is not the same as the Gerrit New Revision id. +if [[ ${JOB_NAME} == *merge* ]] && [ -n "${GERRIT_NEWREV:-}" ] && + [ "$GERRIT_NEWREV" != "$GIT_COMMIT" ] ; then + echo -e "\n$line\nSkipping build. A newer patch has been merged.\n$line\n" + exit 0 fi -echo "sha1sum of this script: ${0}" -sha1sum $0 - -echo "CC=${CC}" -echo "IS_CSIT_VPP_JOB=${IS_CSIT_VPP_JOB}" -# If and only if we are doing verify *after* make verify was made to work -# and we are not a CSIT job just building packages, then use make verify, -# else use make pkg-verify. +OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_ARCH=$(uname -m) +DRYRUN="${DRYRUN:-}" +IS_CSIT_VPP_JOB="${IS_CSIT_VPP_JOB:-}" +MAKE_PARALLEL_FLAGS="${MAKE_PARALLEL_FLAGS:-}" +MAKE_PARALLEL_JOBS="${MAKE_PARALLEL_JOBS:-}" +MAKE_TEST_OS="${MAKE_TEST_OS:-ubuntu-22.04}" +MAKE_TEST_MULTIWORKER_OS="${MAKE_TEST_MULTIWORKER_OS:-debian-11}" +VPPAPIGEN_TEST_OS="${VPPAPIGEN_TEST_OS:-${MAKE_TEST_OS}}" +BUILD_RESULT="SUCCESSFULLY COMPLETED" +BUILD_ERROR="" +RETVAL="0" -if [ "x${MAKE_PARALLEL_FLAGS}" != "x" ] -then +if [ -n "${MAKE_PARALLEL_FLAGS}" ] ; then echo "Building VPP. Number of cores for build set with" \ "MAKE_PARALLEL_FLAGS='${MAKE_PARALLEL_FLAGS}'." -elif [ "x${MAKE_PARALLEL_JOBS}" != "x" ] -then +elif [ -n "${MAKE_PARALLEL_JOBS}" ] ; then echo "Building VPP. Number of cores for build set with" \ "MAKE_PARALLEL_JOBS='${MAKE_PARALLEL_JOBS}'." else - echo "Building VPP. Number of cores not set, " \ - "using build default ($(grep -c ^processor /proc/cpuinfo))." + echo "Building VPP. Number of cores not set," \ + "using build default ($(grep -c ^processor /proc/cpuinfo))." fi -if [ "x${MAKE_PARALLEL_JOBS}" != "x" ] -then - export TEST_JOBS="${MAKE_PARALLEL_JOBS}" - echo "Testing VPP with ${TEST_JOBS} cores." -else - export TEST_JOBS="auto" - echo "Testing VPP with automatically calculated number of cores. " \ - "See test logs for the exact number." -fi +make_build_test() { + if ! make UNATTENDED=yes install-dep ; then + BUILD_ERROR="FAILED 'make install-dep'" + return + fi + if ! make UNATTENDED=yes install-ext-deps ; then + BUILD_ERROR="FAILED 'make install-ext-deps'" + return + fi + if [ -f extras/scripts/build_static_vppctl.sh ]; then + if ! extras/scripts/build_static_vppctl.sh ; then + BUILD_ERROR="FAILED 'extras/scripts/build_static_vppctl.sh'" + return + fi + fi + if ! make UNATTENDED=yes test-dep ; then + BUILD_ERROR="FAILED 'make test-dep'" + return + fi + if ! make UNATTENDED=yes pkg-verify ; then + BUILD_ERROR="FAILED 'make pkg-verify'" + return + fi + if [ "${IS_CSIT_VPP_JOB,,}" == "true" ] ; then + # CSIT jobs don't need to run make test + return + fi + if [ -n "${MAKE_PARALLEL_JOBS}" ] ; then + TEST_JOBS="${MAKE_PARALLEL_JOBS}" + echo "Testing VPP with ${TEST_JOBS} cores." + else + TEST_JOBS="auto" + echo "Testing VPP with automatically calculated number of cores. " \ + "See test logs for the exact number." + fi + if grep -q "${OS_ID}-${OS_VERSION_ID}" <<< "${VPPAPIGEN_TEST_OS}"; then + if ! src/tools/vppapigen/test_vppapigen.py ; then + BUILD_ERROR="FAILED src/tools/vppapigen/test_vppapigen.py" + return + fi + fi + if grep -q "${OS_ID}-${OS_VERSION_ID}" <<< "${MAKE_TEST_OS}"; then + if ! make COMPRESS_FAILED_TEST_LOGS=yes TEST_JOBS="$TEST_JOBS" RETRIES=3 test ; then + BUILD_ERROR="FAILED 'make test'" + return + fi + else + echo "Skip running 'make test' on ${OS_ID}-${OS_VERSION_ID}" + fi + if grep -q "${OS_ID}-${OS_VERSION_ID}" <<< "${MAKE_TEST_MULTIWORKER_OS}"; then + if git grep -q VPP_WORKER_CONFIG ; then + if ! make VPP_WORKER_CONFIG="workers 2" COMPRESS_FAILED_TEST_LOGS=yes \ + RETRIES=3 TEST_JOBS="$TEST_JOBS" test ; then + BUILD_ERROR="FAILED 'make test' with VPP_WORKER_CONFIG='workers 2'" + return + else + echo -e "\n* VPP ${OS_ID^^}-${OS_VERSION_ID}-${OS_ARCH^^}" \ + "MULTIWORKER MAKE TEST SUCCESSFULLY COMPLETED\n" + fi + elif git grep -q VPP_WORKER_COUNT ; then + if ! make VPP_WORKER_COUNT="2" COMPRESS_FAILED_TEST_LOGS=yes \ + RETRIES=3 TEST_JOBS="$TEST_JOBS" test ; then + BUILD_ERROR="FAILED 'make test' with VPP_WORKER_CONFIG='workers 2'" + return + else + echo -e "\n* VPP ${OS_ID^^}-${OS_VERSION_ID}-${OS_ARCH^^}" \ + "MULTIWORKER MAKE TEST SUCCESSFULLY COMPLETED\n" + fi + else + echo "Skip running MULTIWORKER MAKE TEST on ${OS_ID}-${OS_VERSION_ID}" + fi + else + echo "Skip running MULTIWORKER MAKE TEST on ${OS_ID}-${OS_VERSION_ID}" + fi +} -if (git log --oneline | grep 37682e1 > /dev/null 2>&1) && \ - [ "x${IS_CSIT_VPP_JOB}" != "xTrue" ] -then - echo "Building using \"make verify\"" - [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes verify -else - echo "Building using \"make pkg-verify\"" - [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes pkg-verify +if [ "${DRYRUN,,}" != "true" ] ; then + make_build_test fi - -if [ "x${VPP_REPO}" == "x1" ]; then - if [ "x${REBASE_NEEDED}" == "x1" ]; then - echo "This patch to vpp is based on an old point in the tree that is likely" - echo "to fail verify." - echo "PLEASE REBASE PATCH ON THE CURRENT HEAD OF THE VPP REPO" - exit 1 - fi +if [ -n "$BUILD_ERROR" ] ; then + BUILD_RESULT="$BUILD_ERROR" + RETVAL="1" fi - -local_arch=$(uname -m) - -echo "*******************************************************************" -echo "* VPP ${local_arch^^} BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" +echo -e "\n$line\n* VPP ${OS_ID^^}-${OS_VERSION_ID}-${OS_ARCH^^}" \ + "BUILD $BUILD_RESULT\n$line\n" +exit $RETVAL diff --git a/jjb/scripts/vpp/check_crc.sh b/jjb/scripts/vpp/check_crc.sh index 04e53966d..c0a9d507d 100644..100755 --- a/jjb/scripts/vpp/check_crc.sh +++ b/jjb/scripts/vpp/check_crc.sh @@ -13,22 +13,25 @@ # See the License for the specific language governing permissions and # limitations under the License. +echo "---> jjb/scripts/vpp/check_crc.sh" + set -exuo pipefail # Clone CSIT git repository and proceed with entry script located there. # # Variables read: # - WORKSPACE - Jenkins workspace to create csit subdirectory in. +# - GIT_URL - Git clone URL # - CSIT_REF - Override ref of CSIT git repository to checkout. # Directories updated: # - ${WORKSPACE}/csit - Created, holding a checked out CSIT repository. # - Multiple other side effects by entry script(s), see CSIT repository. cd "${WORKSPACE}" -git clone https://gerrit.fd.io/r/csit --depth=1 --no-single-branch --no-checkout +git clone "${GIT_URL}/csit" --depth=1 --no-single-branch --no-checkout pushd "${WORKSPACE}/csit" if [[ -n "${CSIT_REF-}" ]]; then - git fetch --depth=1 https://gerrit.fd.io/r/csit "${CSIT_REF}" + git fetch --depth=1 "${GIT_URL}/csit" "${CSIT_REF}" git checkout FETCH_HEAD else git checkout HEAD diff --git a/jjb/scripts/vpp/checkstyle.sh b/jjb/scripts/vpp/checkstyle.sh index 7c520dd99..00fc8bdb8 100644..100755 --- a/jjb/scripts/vpp/checkstyle.sh +++ b/jjb/scripts/vpp/checkstyle.sh @@ -1,5 +1,38 @@ #!/bin/bash -# jjb/vpp/include-raw-vpp-checkstyle.sh + +# Copyright (c) 2020 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/vpp/checkstyle.sh" + +# If mlx_rdma_dpdk_matrix.txt file has been updated in the current changeset, +# verify the current rdma-core_version and dpdk_version exist in the matrix +# file +LINE="*******************************************************************" +BUILD_EXT_DIR="build/external" +MATRIX_FILE="$BUILD_EXT_DIR/mlx_rdma_dpdk_matrix.txt" +PKGS_DIR="$BUILD_EXT_DIR/packages" +if git show --stat | grep -q "$MATRIX_FILE" ; then + RDMA_CORE_VERSION="$(grep rdma-core_version $PKGS_DIR/rdma-core.mk | grep -v '(' | mawk '{print $3}')" + DPDK_VERSION="$(grep dpdk_version $PKGS_DIR/dpdk.mk | grep -v '(' | mawk '{print $3}')" + CURRENT_MATRIX="rdma=$RDMA_CORE_VERSION dpdk=$DPDK_VERSION" + if grep -q "$CURRENT_MATRIX" "$MATRIX_FILE"; then + echo -e "$LINE\n* DPDK/RDMA-CORE matrix file update successfully verified\n$LINE" + else + echo -e "$LINE\n* ERROR: 'rdma=$RDMA_CORE_VERSION dpdk=$DPDK_VERSION' not found in $MATRIX_FILE!\n$LINE" + exit 1 + fi +fi if [ -n "$(grep -E '^checkstyle:' Makefile)" ] then diff --git a/jjb/scripts/vpp/commitmsg.sh b/jjb/scripts/vpp/commitmsg.sh index d926ff5dd..479f35136 100644 --- a/jjb/scripts/vpp/commitmsg.sh +++ b/jjb/scripts/vpp/commitmsg.sh @@ -1,7 +1,22 @@ #!/bin/bash -if [ -f extras/scripts/check_commit_msg.sh ];then - echo "Running extras/scripts/check_commit_msg.sh" +# Copyright (c) 2020 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/vpp/commitmsg.sh" + +if [ -f extras/scripts/check_commit_msg.sh ] ; then + echo "Running extras/scripts/check_commit_msg.sh" extras/scripts/check_commit_msg.sh else echo "Cannot find cat extras/scripts/check_commit_msg.sh - skipping commit message check" diff --git a/jjb/scripts/vpp/copy_archives.sh b/jjb/scripts/vpp/copy_archives.sh new file mode 100644 index 000000000..dafcd4aef --- /dev/null +++ b/jjb/scripts/vpp/copy_archives.sh @@ -0,0 +1,38 @@ +#!/usr/bin/env bash + +# Copyright (c) 2023 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/vpp/copy_archives.sh" + +set -xuo pipefail +set +e + +# Copy robot archives from perf job to where archive macro needs them. +# +# This has to be a script separate from csit-perf.sh, run as publisher, +# because otherwise it is not easily possible to ensure this is executed +# also when there is a test case failure. +# +# This can be removed when all CSIT branches use correct archive directory. +# For fixed CSIT, the copy will fail, so errors are ignored everywhere. +# +# Variables read: +# - WORKSPACE - Jenkins workspace to create csit subdirectory in. +# Directories updated: +# - ${WORKSPACE}/archives/csit_* - Test results for various VPP builds are here. +# e.g. csit_current and csit_parent for vpp per-patch perf job. + +mkdir -p "${WORKSPACE}/archives" +# Using asterisk as bisect job creates variable number of directories. +cp -Rv "${WORKSPACE}/csit_"* "${WORKSPACE}/archives" diff --git a/jjb/scripts/vpp/cov-build.sh b/jjb/scripts/vpp/cov-build.sh new file mode 100644 index 000000000..15f86c3bf --- /dev/null +++ b/jjb/scripts/vpp/cov-build.sh @@ -0,0 +1,106 @@ +#!/bin/bash + +# Copyright (c) 2023 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/vpp/cov-build.sh" + +set -euxo pipefail + +line="*************************************************************************" +# Don't build anything if this is a merge job. +if [[ ${JOB_NAME} == *merge* ]] ; then + echo -e "\n$line\nSkipping build." + exit 0 +fi + +OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_ARCH=$(uname -m) +DRYRUN="${DRYRUN:-}" +IS_CSIT_VPP_JOB="${IS_CSIT_VPP_JOB:-}" +MAKE_PARALLEL_FLAGS="${MAKE_PARALLEL_FLAGS:-}" +MAKE_PARALLEL_JOBS="${MAKE_PARALLEL_JOBS:-}" +MAKE_TEST_OS="${MAKE_TEST_OS:-ubuntu-22.04}" +MAKE_TEST_MULTIWORKER_OS="${MAKE_TEST_MULTIWORKER_OS:-debian-11}" +VPPAPIGEN_TEST_OS="${VPPAPIGEN_TEST_OS:-${MAKE_TEST_OS}}" +BUILD_RESULT="SUCCESSFULLY COMPLETED" +BUILD_ERROR="" +RETVAL="0" + +if [ -n "${MAKE_PARALLEL_FLAGS}" ] ; then + echo "Building VPP. Number of cores for build set with" \ + "MAKE_PARALLEL_FLAGS='${MAKE_PARALLEL_FLAGS}'." +elif [ -n "${MAKE_PARALLEL_JOBS}" ] ; then + echo "Building VPP. Number of cores for build set with" \ + "MAKE_PARALLEL_JOBS='${MAKE_PARALLEL_JOBS}'." +else + echo "Building VPP. Number of cores not set," \ + "using build default ($(grep -c ^processor /proc/cpuinfo))." +fi + +make_test_coverage_report() { + if ! make UNATTENDED=yes install-dep ; then + BUILD_ERROR="FAILED 'make install-dep'" + return + fi + if ! make UNATTENDED=yes install-ext-deps ; then + BUILD_ERROR="FAILED 'make install-ext-deps'" + return + fi + if ! make UNATTENDED=yes test-dep ; then + BUILD_ERROR="FAILED 'make test-dep'" + return + fi + if ! make UNATTENDED=yes CCACHE_DISABLE=1 pkg-verify ; then + BUILD_ERROR="FAILED 'make pkg-verify'" + return + fi + if [ "${IS_CSIT_VPP_JOB,,}" == "true" ] ; then + # CSIT jobs don't need to run make test + return + fi + if [ -n "${MAKE_PARALLEL_JOBS}" ] ; then + TEST_JOBS="${MAKE_PARALLEL_JOBS}" + echo "Testing VPP with ${TEST_JOBS} cores." + else + TEST_JOBS="auto" + echo "Testing VPP with automatically calculated number of cores. " \ + "See test logs for the exact number." + fi + if grep -q "${OS_ID}-${OS_VERSION_ID}" <<< "${VPPAPIGEN_TEST_OS}"; then + if ! src/tools/vppapigen/test_vppapigen.py ; then + BUILD_ERROR="FAILED src/tools/vppapigen/test_vppapigen.py" + return + fi + fi + if grep -q "${OS_ID}-${OS_VERSION_ID}" <<< "${MAKE_TEST_OS}"; then + if ! make COMPRESS_FAILED_TEST_LOGS=yes TEST_JOBS="$TEST_JOBS" CCACHE_DISABLE=1 test-cov ; then + BUILD_ERROR="FAILED 'make test-cov'" + return + fi + else + echo "Skip running 'make test-cov' on ${OS_ID}-${OS_VERSION_ID}" + fi +} + +if [ "${DRYRUN,,}" != "true" ] ; then + make_test_coverage_report +fi +if [ -n "$BUILD_ERROR" ] ; then + BUILD_RESULT="$BUILD_ERROR" + RETVAL="1" +fi +echo -e "\n$line\n* VPP ${OS_ID^^}-${OS_VERSION_ID}-${OS_ARCH^^}" \ + "TEST COVERAGE REPORT $BUILD_RESULT\n$line\n" +exit $RETVAL diff --git a/jjb/scripts/vpp/coverity.sh b/jjb/scripts/vpp/coverity.sh deleted file mode 100644 index 47a316a89..000000000 --- a/jjb/scripts/vpp/coverity.sh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/bash -FILE="scan.txt" -OUTPUT="output.txt" - -wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb -dpkg -i google-chrome-stable_current_amd64.deb || true -apt-get install -f -y - -google-chrome --headless --disable-gpu -dump-dom --no-sandbox https://scan.coverity.com/projects/fd-io-vpp > $FILE - -grep -i '<dt>Newly detected</dt>' $FILE || exit 42 - -NEW=$(grep -i -B 1 '<dt>Newly detected</dt>' $FILE | grep -Eo '[0-9]{1,4}') -ELIM=$(grep -i -B 1 '<dt>Eliminated</dt>' $FILE | grep -Eo '[0-9]{1,4}') -OUT=$(grep -i -B 1 '<dt>Outstanding</dt>' $FILE | grep -Eo '[0-9]{1,4}') - -#ls -lg $FILE -#cat $FILE - -if [ "${OUT}" == "0" ]; then - echo 'Current outstanding issues are zero' > $OUTPUT - echo "Newly detected: $NEW" >> $OUTPUT - echo "Eliminated: $ELIM" >> $OUTPUT - echo "More details can be found at https://scan.coverity.com/projects/fd-io-vpp/view_defects" >> $OUTPUT -else - echo "Current number of outstanding issues are $OUT Failing job" - echo "Current number of outstanding issues are $OUT" > $OUTPUT - echo "Newly detected: $NEW" >> $OUTPUT - echo "Eliminated: $ELIM" >> $OUTPUT - echo "More details can be found at https://scan.coverity.com/projects/fd-io-vpp/view_defects" >> $OUTPUT - exit 1 -fi diff --git a/jjb/scripts/vpp/csit-bisect.sh b/jjb/scripts/vpp/csit-bisect.sh new file mode 100644 index 000000000..0a264dbc8 --- /dev/null +++ b/jjb/scripts/vpp/csit-bisect.sh @@ -0,0 +1,38 @@ +#!/usr/bin/env bash + +# Copyright (c) 2023 Cisco and/or its affiliates. +# 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. + +set -exuo pipefail + +# Clone CSIT git repository and proceed with entry script located there. +# +# Variables read: +# - WORKSPACE - Jenkins workspace to create csit subdirectory in. +# - CSIT_REF - Override ref of CSIT git repository to checkout. +# Directories updated: +# - ${WORKSPACE}/csit - Created, holding a checked out CSIT repository. +# - Multiple other side effects by entry script(s), see CSIT repository. + +cd "${WORKSPACE}" +git clone https://gerrit.fd.io/r/csit --depth=1 --no-single-branch --no-checkout +pushd "${WORKSPACE}/csit" +if [[ -n "${CSIT_REF-}" ]]; then + git fetch --depth=1 https://gerrit.fd.io/r/csit "${CSIT_REF}" + git checkout FETCH_HEAD +else + git checkout HEAD +fi +popd +csit_entry_dir="${WORKSPACE}/csit/resources/libraries/bash/entry" +source "${csit_entry_dir}/with_oper_for_vpp.sh" "bisect.sh" diff --git a/jjb/scripts/vpp/csit-device.sh b/jjb/scripts/vpp/csit-device.sh index af54c9dc4..989193001 100644..100755 --- a/jjb/scripts/vpp/csit-device.sh +++ b/jjb/scripts/vpp/csit-device.sh @@ -13,22 +13,25 @@ # See the License for the specific language governing permissions and # limitations under the License. +echo "---> jjb/scripts/vpp/csit-device.sh" + set -exuo pipefail # Clone CSIT git repository and proceed with entry script located there. # # Variables read: # - WORKSPACE - Jenkins workspace to create csit subdirectory in. +# - GIT_URL - Git clone URL # - CSIT_REF - Override ref of CSIT git repository to checkout. # Directories updated: # - ${WORKSPACE}/csit - Created, holding a checked out CSIT repository. # - Multiple other side effects by entry script(s), see CSIT repository. cd "${WORKSPACE}" -git clone https://gerrit.fd.io/r/csit --depth=1 --no-single-branch --no-checkout +git clone "${GIT_URL}/csit" --depth=1 --no-single-branch --no-checkout pushd "${WORKSPACE}/csit" if [[ -n "${CSIT_REF-}" ]]; then - git fetch --depth=1 https://gerrit.fd.io/r/csit "${CSIT_REF}" + git fetch --depth=1 "${GIT_URL}/csit" "${CSIT_REF}" git checkout FETCH_HEAD else git checkout HEAD diff --git a/jjb/scripts/vpp/csit-perf.sh b/jjb/scripts/vpp/csit-perf.sh index 17a9d39bc..ee0b500c6 100644..100755 --- a/jjb/scripts/vpp/csit-perf.sh +++ b/jjb/scripts/vpp/csit-perf.sh @@ -13,22 +13,25 @@ # See the License for the specific language governing permissions and # limitations under the License. +echo "---> jjb/scripts/vpp/csit-perf.sh" + set -exuo pipefail # Clone CSIT git repository and proceed with entry script located there. # # Variables read: # - WORKSPACE - Jenkins workspace to create csit subdirectory in. +# - GIT_URL - Git clone URL # - CSIT_REF - Override ref of CSIT git repository to checkout. # Directories updated: # - ${WORKSPACE}/csit - Created, holding a checked out CSIT repository. # - Multiple other side effects by entry script(s), see CSIT repository. cd "${WORKSPACE}" -git clone https://gerrit.fd.io/r/csit --depth=1 --no-single-branch --no-checkout +git clone "${GIT_URL}/csit" --depth=1 --no-single-branch --no-checkout pushd "${WORKSPACE}/csit" if [[ -n "${CSIT_REF-}" ]]; then - git fetch --depth=1 https://gerrit.fd.io/r/csit "${CSIT_REF}" + git fetch --depth=1 "${GIT_URL}/csit" "${CSIT_REF}" git checkout FETCH_HEAD else git checkout HEAD diff --git a/jjb/scripts/vpp/debug-build.sh b/jjb/scripts/vpp/debug-build.sh index cdf1d0760..68338df56 100644 --- a/jjb/scripts/vpp/debug-build.sh +++ b/jjb/scripts/vpp/debug-build.sh @@ -1,49 +1,78 @@ #!/bin/bash -# basic build script example -set -xe -o pipefail -OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') -OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +# Copyright (c) 2021 Cisco and/or its affiliates. +# 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. -echo OS_ID: $OS_ID -echo OS_VERSION_ID: $OS_VERSION_ID +echo "---> jjb/scripts/vpp/debug-build.sh" -# do nothing but print the current slave hostname -hostname - -echo "cat /etc/bootstrap.sha" -if [ -f /etc/bootstrap.sha ];then - cat /etc/bootstrap.sha -else - echo "Cannot find cat /etc/bootstrap.sha" -fi - -echo "cat /etc/bootstrap-functions.sha" -if [ -f /etc/bootstrap-functions.sha ];then - cat /etc/bootstrap-functions.sha -else - echo "Cannot find cat /etc/bootstrap-functions.sha" -fi - -echo "sha1sum of this script: ${0}" -sha1sum $0 +set -euxo pipefail +line="*************************************************************************" +OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_ARCH=$(uname -m) +DRYRUN="${DRYRUN:-}" +MAKE_PARALLEL_JOBS="${MAKE_PARALLEL_JOBS:-}" +BUILD_RESULT="SUCCESSFULLY COMPLETED" +BUILD_ERROR="" +RETVAL="0" # run with ASAN on +# disable ASAN for now in the debug build - it's broken with PAPI +# in make test transitioning to unix sockets # export VPP_EXTRA_CMAKE_ARGS='-DVPP_ENABLE_SANITIZE_ADDR=ON' -# clang is not working with ASAN right now - see change 27268 -# apparently gcc neither... -# export CC=gcc - - - -make UNATTENDED=yes install-dep -make UNATTENDED=yes install-ext-deps -make UNATTENDED=yes build -make UNATTENDED=yes TEST_JOBS=auto test-debug +make_build_test_debug() { + if ! make UNATTENDED=yes install-dep ; then + BUILD_ERROR="FAILED 'make install-dep'" + return + fi + if ! make UNATTENDED=yes install-ext-deps ; then + BUILD_ERROR="FAILED 'make install-ext-deps'" + return + fi + if ! make UNATTENDED=yes build ; then + BUILD_ERROR="FAILED 'make build'" + return + fi + if grep -q "${OS_ID}-${OS_VERSION_ID}" <<< "${MAKE_TEST_OS}"; then + if [ -n "${MAKE_PARALLEL_JOBS}" ] ; then + TEST_JOBS="${MAKE_PARALLEL_JOBS}" + echo "Testing VPP with ${TEST_JOBS} cores." + else + TEST_JOBS="auto" + echo "Testing VPP with automatically calculated number of cores. " \ + "See test logs for the exact number." + fi + if ! make UNATTENDED=yes COMPRESS_FAILED_TEST_LOGS=yes \ + TEST_JOBS="$TEST_JOBS" test-debug ; then + BUILD_ERROR="FAILED 'make UNATTENDED=yes COMPRESS_FAILED_TEST_LOGS=yes TEST_JOBS=$TEST_JOBS test-debug'" + return + fi + else + echo "Skip running 'make test-debug' on ${OS_ID}-${OS_VERSION_ID}" + fi +} - -echo "*******************************************************************" -echo "* VPP debug/asan test BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" +# clang is not working with ASAN right now - see change 27268 +# also, it does not work with gcc-7, we need gcc-8 at least +# on ubuntu 20.04 executor the gcc is gcc9 +if [ "${DRYRUN,,}" != "true" ] ; then + make_build_test_debug +fi +if [ -n "$BUILD_ERROR" ] ; then + BUILD_RESULT="$BUILD_ERROR" + RETVAL="1" +fi +echo -e "\n$line\n* VPP ${OS_ID^^}-${OS_VERSION_ID}-${OS_ARCH^^} DEBUG BUILD $BUILD_RESULT\n$line\n" +exit $RETVAL diff --git a/jjb/scripts/vpp/docs.sh b/jjb/scripts/vpp/docs.sh index 608f8f979..52b920e31 100644..100755 --- a/jjb/scripts/vpp/docs.sh +++ b/jjb/scripts/vpp/docs.sh @@ -1,50 +1,29 @@ #!/bin/bash -set -xe -o pipefail -[ "$DOCS_REPO_URL" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site" -[ "$PROJECT_PATH" ] || PROJECT_PATH=io/fd/vpp -[ "$DOC_FILE" ] || DOC_FILE=vpp.docs.zip -[ "$DOC_DIR" ] || DOC_DIR=build-root/docs/html -[ "$SITE_DIR" ] || SITE_DIR=build-root/docs/deploy-site/ -[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" -[ "$VERSION" ] || VERSION=$(./build-root/scripts/version rpm-version) -make doxygen +# Copyright (c) 2022 Cisco and/or its affiliates. +# 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. -if [[ ${JOB_NAME} == *merge* ]]; then - mkdir -p $(dirname ${RESOURCES_DIR}) - mv -f ${DOC_DIR} ${RESOURCES_DIR} - cd ${SITE_DIR} - find . -type f '(' -name '*.md5' -o -name '*.dot' -o -name '*.map' ')' -delete - cat > pom.xml << EOF - <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>io.fd.vpp</groupId> - <artifactId>docs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> +echo "---> jjb/scripts/vpp/docs.sh" - <properties> - <generateReports>false</generateReports> - </properties> +set -euxo pipefail - <build> - <extensions> - <extension> - <groupId>org.apache.maven.wagon</groupId> - <artifactId>wagon-webdav-jackrabbit</artifactId> - <version>2.10</version> - </extension> - </extensions> - </build> - <distributionManagement> - <site> - <id>fdio-site</id> - <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/${VERSION}</url> - </site> - </distributionManagement> - </project> -EOF - ${MVN} -B site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C - cd - +line="*************************************************************************" +# Don't build anything if this is a merge job being run when +# the git HEAD id is not the same as the Gerrit New Revision id. +if [[ ${JOB_NAME} == *merge* ]] && [ -n "${GERRIT_NEWREV:-}" ] && + [ "$GERRIT_NEWREV" != "$GIT_COMMIT" ] ; then + echo -e "\n$line\nSkipping docs build. A newer patch has been merged.\n$line\n" + exit 0 fi + +make UNATTENDED=yes docs diff --git a/jjb/scripts/csit/vpp-functional-virl.sh b/jjb/scripts/vpp/docs_spell.sh index f2e38e8e1..4b6a97851 100644..100755 --- a/jjb/scripts/csit/vpp-functional-virl.sh +++ b/jjb/scripts/vpp/docs_spell.sh @@ -1,6 +1,6 @@ #!/bin/bash -# Copyright (c) 2020 Cisco and/or its affiliates. +# Copyright (c) 2022 Cisco and/or its affiliates. # 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: @@ -13,16 +13,11 @@ # See the License for the specific language governing permissions and # limitations under the License. -# execute csit bootstrap script if it exists -if [ -e bootstrap.sh ] +echo "---> jjb/scripts/vpp/docs_spell.sh" + +if grep -qE '^docs\-%' Makefile && grep -qE '^spell' docs/Makefile then - # make sure that bootstrap.sh is executable - chmod +x bootstrap.sh - # run the script - ./bootstrap.sh + make docs-spell else - echo 'ERROR: No bootstrap.sh found' - exit 1 + echo "Can't find docs-spell target in Makefile - skipping docs-spell" fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/scripts/vpp/dpdk-rdma-version-mismatch.sh b/jjb/scripts/vpp/dpdk-rdma-version-mismatch.sh new file mode 100644 index 000000000..b2248064b --- /dev/null +++ b/jjb/scripts/vpp/dpdk-rdma-version-mismatch.sh @@ -0,0 +1,33 @@ +#!/bin/bash + +# Copyright (c) 2022 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/vpp/dpdk-rdma-version-mismatch.sh" + +set -euxo pipefail + +line="*************************************************************************" +EXTERNAL_BUILD_DIR="$WORKSPACE/build/external" +RETVAL="0" +MISMATCH_RESULT="INCLUDED IN" + +make -C "$EXTERNAL_BUILD_DIR" build-deb +source "$EXTERNAL_BUILD_DIR/dpdk_mlx_default.sh" || true + +if [ "${DPDK_MLX_DEFAULT-}" = "n" ] ; then + MISMATCH_RESULT="MISSING FROM" + RETVAL="1" +fi +echo -e "\n$line\n* MLX DPDK DRIVER $MISMATCH_RESULT VPP-EXT-DEPS PACKAGE\n$line\n" +exit $RETVAL diff --git a/jjb/scripts/vpp/gcc-build.sh b/jjb/scripts/vpp/gcc-build.sh new file mode 100644 index 000000000..9bd6d4ff7 --- /dev/null +++ b/jjb/scripts/vpp/gcc-build.sh @@ -0,0 +1,78 @@ +#!/bin/bash + +# Copyright (c) 2022 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/vpp/gcc-build.sh" + +set -euxo pipefail + +line="*************************************************************************" +OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') +OS_ARCH=$(uname -m) +DRYRUN="${DRYRUN:-}" +BUILD_RESULT="SUCCESSFULLY COMPLETED" +BUILD_ERROR="" +RETVAL="0" +export CC=gcc + +make_build_release_build_test_gcov_sanity() { + if ! make UNATTENDED=yes install-dep ; then + BUILD_ERROR="FAILED 'make install-dep'" + return + fi + if ! make UNATTENDED=yes install-ext-deps ; then + BUILD_ERROR="FAILED 'make install-ext-deps'" + return + fi + if ! make UNATTENDED=yes CCACHE_DISABLE=1 build-release ; then + BUILD_ERROR="FAILED 'make build-release'" + return + fi + if ! make UNATTENDED=yes CCACHE_DISABLE=1 build ; then + BUILD_ERROR="FAILED 'make build'" + return + fi + if [ -n "${MAKE_PARALLEL_JOBS}" ] ; then + TEST_JOBS="${MAKE_PARALLEL_JOBS}" + echo "Testing VPP with ${TEST_JOBS} cores." + else + TEST_JOBS="auto" + echo "Testing VPP with automatically calculated number of cores. " \ + "See test logs for the exact number." + fi + # TODO: Add 'smoke test' env var to select smoke test cases + # then update this accordingly. For now pick a few basic suites... + MAKE_TEST_SUITES="vlib vppinfra vpe_api vapi cli bihash" + for suite in $MAKE_TEST_SUITES ; do + if ! make UNATTENDED=yes CCACHE_DISABLE=1 TESTS_GCOV=1 TEST_JOBS="$TEST_JOBS" TEST=$suite test ; then + BUILD_ERROR="FAILED 'make TEST=$suite test'!" + return + fi + if ! make UNATTENDED=yes CCACHE_DISABLE=1 TESTS_GCOV=1 TEST_JOBS="$TEST_JOBS" TEST=$suite test-debug ; then + BUILD_ERROR="FAILED 'make TEST=$suite test-debug'!" + return + fi + done +} + +if [ "${DRYRUN,,}" != "true" ] ; then + make_build_release_build_test_gcov_sanity +fi +if [ -n "$BUILD_ERROR" ] ; then + BUILD_RESULT="$BUILD_ERROR" + RETVAL="1" +fi +echo -e "\n$line\n* VPP ${OS_ID^^}-${OS_VERSION_ID}-${OS_ARCH^^} GCC BUILD $BUILD_RESULT\n$line\n" +exit $RETVAL diff --git a/jjb/scripts/vpp/make-test-docs.sh b/jjb/scripts/vpp/make-test-docs.sh deleted file mode 100644 index 1f82ab502..000000000 --- a/jjb/scripts/vpp/make-test-docs.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/bash -set -xe -o pipefail -[ "$DOCS_REPO_URL" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site" -[ "$PROJECT_PATH" ] || PROJECT_PATH=io/fd/vpp -[ "$DOC_DIR" ] || DOC_DIR=build-root/build-test/doc/html -[ "$SITE_DIR" ] || SITE_DIR=build-root/docs/deploy-site -[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources/vpp_make_test -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" -[ "$VERSION" ] || VERSION=$(./build-root/scripts/version rpm-version) - -make test-doc - -if [[ ${JOB_NAME} == *merge* ]]; then - mkdir -p ${RESOURCES_DIR} - mv -f ${DOC_DIR} ${RESOURCES_DIR} - cd ${SITE_DIR} - - cat > pom.xml << EOF - <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>io.fd.vpp</groupId> - <artifactId>docs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> - - <properties> - <generateReports>false</generateReports> - </properties> - - <build> - <extensions> - <extension> - <groupId>org.apache.maven.wagon</groupId> - <artifactId>wagon-webdav-jackrabbit</artifactId> - <version>2.10</version> - </extension> - </extensions> - </build> - <distributionManagement> - <site> - <id>fdio-site</id> - <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/${VERSION}</url> - </site> - </distributionManagement> - </project> -EOF - ${MVN} -B site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C - cd - -fi diff --git a/jjb/scripts/vpp/maven-push.sh b/jjb/scripts/vpp/maven-push.sh deleted file mode 100644 index 6ce3b2c06..000000000 --- a/jjb/scripts/vpp/maven-push.sh +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/bash -set -xe -o pipefail -echo "*******************************************************************" -echo "* STARTING PUSH OF PACKAGES TO REPOS" -echo "* NOTHING THAT HAPPENS BELOW THIS POINT IS RELATED TO BUILD FAILURE" -echo "*******************************************************************" - -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" -GROUP_ID="io.fd.${PROJECT}" -BASEURL="${NEXUSPROXY}/content/repositories/fd.io." -BASEREPOID='fdio-' - -if [ "${OS}" == "ubuntu1604" ]; then - # Find the files - JARS=$(find . -type f -iname '*.jar') - DEBS=$(find . -type f -iname '*.deb') - for i in $JARS - do - push_jar "$i" - done - - for i in $DEBS - do - push_deb "$i" - done -elif [ "${OS}" == "ubuntu1804" ]; then - # Find the files - JARS=$(find . -type f -iname '*.jar') - DEBS=$(find . -type f -iname '*.deb') - for i in $JARS - do - push_jar "$i" - done - - for i in $DEBS - do - push_deb "$i" - done -elif [ "${OS}" == "centos7" ]; then - # Find the files - RPMS=$(find . -type f -iname '*.rpm') - SRPMS=$(find . -type f -iname '*.srpm') - SRCRPMS=$(find . -type f -name '*.src.rpm') - for i in $RPMS $SRPMS $SRCRPMS - do - push_rpm "$i" - done -elif [ "${OS}" == "opensuse" ]; then - # Find the files - RPMS=$(find . -type f -iname '*.rpm') - for i in $RPMS - do - push_rpm "$i" - done -fi -# vim: ts=4 sw=4 sts=4 et ft=sh : diff --git a/jjb/scripts/vpp/sphinx-docs.sh b/jjb/scripts/vpp/sphinx-docs.sh deleted file mode 100644 index 749728731..000000000 --- a/jjb/scripts/vpp/sphinx-docs.sh +++ /dev/null @@ -1,50 +0,0 @@ -#!/bin/bash -set -xe -o pipefail -[ "$DOCS_REPO_URL" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site" -[ "$PROJECT_PATH" ] || PROJECT_PATH=io/fd/vpp -[ "$DOC_FILE" ] || DOC_FILE=vpp.docs.zip -[ "$DOC_DIR" ] || DOC_DIR=./docs/_build/html -[ "$SITE_DIR" ] || SITE_DIR=build-root/docs/deploy-site -[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources -[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn" -[ "$VERSION" ] || VERSION=$(./build-root/scripts/version rpm-version) - -make docs-venv -CONFIRM=-y FORCE=--force-yes make docs - -if [[ ${JOB_NAME} == *merge* ]]; then - mkdir -p $(dirname ${RESOURCES_DIR}) - mv -f ${DOC_DIR} ${RESOURCES_DIR} - cd ${SITE_DIR} - cat > pom.xml << EOF - <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>io.fd.vpp</groupId> - <artifactId>docs</artifactId> - <version>1.0.0</version> - <packaging>pom</packaging> - - <properties> - <generateReports>false</generateReports> - </properties> - - <build> - <extensions> - <extension> - <groupId>org.apache.maven.wagon</groupId> - <artifactId>wagon-webdav-jackrabbit</artifactId> - <version>2.10</version> - </extension> - </extensions> - </build> - <distributionManagement> - <site> - <id>fdio-site</id> - <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/v${VERSION}</url> - </site> - </distributionManagement> - </project> -EOF - ${MVN} -B site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C - cd - -fi diff --git a/jjb/scripts/vpp/test-checkstyle.sh b/jjb/scripts/vpp/test-checkstyle.sh index bdc843114..3f0bc9a06 100644 --- a/jjb/scripts/vpp/test-checkstyle.sh +++ b/jjb/scripts/vpp/test-checkstyle.sh @@ -1,5 +1,19 @@ #!/bin/bash -# jjb/vpp/include-raw-vpp-test-checkstyle.sh + +# Copyright (c) 2020 Cisco and/or its affiliates. +# 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. + +echo "---> jjb/scripts/vpp/test-checkstyle.sh" if [ -n "$(grep -E '^test-checkstyle:' Makefile)" ] then diff --git a/jjb/sweetcomb/include-raw-sweetcomb-build.sh b/jjb/sweetcomb/include-raw-sweetcomb-build.sh deleted file mode 100644 index 639d7fd5e..000000000 --- a/jjb/sweetcomb/include-raw-sweetcomb-build.sh +++ /dev/null @@ -1,54 +0,0 @@ -#!/bin/bash -# basic build script example -set -xe -o pipefail - -##container server node detection -grep search /etc/resolv.conf || true - -OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') -OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') - -echo OS_ID: $OS_ID -echo OS_VERSION_ID: $OS_VERSION_ID - -function setup { - if ! [ -z ${REPO_NAME} ]; then - echo "INSTALLING VPP-DPKG-DEV from apt/yum repo" - REPO_URL="https://packagecloud.io/fdio/${STREAM}" - echo "REPO_URL: ${REPO_URL}" - # Setup by installing vpp-dev and vpp-lib - if [ "$OS_ID" == "ubuntu" ]; then - if [ -f /etc/apt/sources.list.d/99fd.io.list ];then - echo "Deleting: /etc/apt/sources.list.d/99fd.io.list" - sudo rm /etc/apt/sources.list.d/99fd.io.list - fi - if [ -f /etc/apt/sources.list.d/fdio_master.list ];then - echo "Deleting: /etc/apt/sources.list.d/fdio_master.list" - sudo rm /etc/apt/sources.list.d/fdio_master.list - fi - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.deb.sh | sudo bash - elif [ "$OS_ID" == "centos" ]; then - if [ -f /etc/yum.repos.d/fdio-master.repo ]; then - echo "Deleting: /etc/yum.repos.d/fdio-master.repo" - sudo rm /etc/yum.repos.d/fdio-master.repo - fi - if [ -f /etc/yum.repos.d/fdio_master.repo ]; then - echo "Deleting: /etc/yum.repos.d/fdio_master.repo" - sudo rm /etc/yum.repos.d/fdio_master.repo - fi - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.rpm.sh | sudo bash - fi - fi -} - -setup - -echo "Building using \"make build-root/build.sh\"" -[ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes install-dep -[ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes install-dep-extra -[ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes install-vpp -[ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes build-package - -echo "*******************************************************************" -echo "* SWEETCOMB BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" diff --git a/jjb/sweetcomb/include-raw-sweetcomb-checkstyle.sh b/jjb/sweetcomb/include-raw-sweetcomb-checkstyle.sh deleted file mode 100644 index 258c9e7e2..000000000 --- a/jjb/sweetcomb/include-raw-sweetcomb-checkstyle.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash - -if [ -f build-root/scripts/checkstyle.sh ];then - build-root/scripts/checkstyle.sh -else - echo "Cannot find cat build-root/scripts/checkstyle.sh - skipping checkstyle" -fi diff --git a/jjb/sweetcomb/include-raw-sweetcomb-test.sh b/jjb/sweetcomb/include-raw-sweetcomb-test.sh deleted file mode 100644 index 3abdf52a2..000000000 --- a/jjb/sweetcomb/include-raw-sweetcomb-test.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/bash -# basic build script example -set -xe -o pipefail - -##container server node detection -grep search /etc/resolv.conf || true - -OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') -OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') - -echo OS_ID: $OS_ID -echo OS_VERSION_ID: $OS_VERSION_ID - -echo "Building using \"make build-root/build.sh\"" -[ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes install-test-extra -[ "x${DRYRUN}" == "xTrue" ] || make build-scvpp -[ "x${DRYRUN}" == "xTrue" ] || make build-plugins -[ "x${DRYRUN}" == "xTrue" ] || useradd user -[ "x${DRYRUN}" == "xTrue" ] || bash -c "echo -e \"user\nuser\" | passwd user" -[ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes test-plugins - -echo "*******************************************************************" -echo "* SWEETCOMB TEST SUCCESSFULLY COMPLETED" -echo "*******************************************************************" - diff --git a/jjb/sweetcomb/sweetcomb.yaml b/jjb/sweetcomb/sweetcomb.yaml deleted file mode 100644 index 24761b292..000000000 --- a/jjb/sweetcomb/sweetcomb.yaml +++ /dev/null @@ -1,273 +0,0 @@ ---- -######################################################################### -# -# Copyright (c) 2018 Intel and/or its affiliates. -# 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. -######################################################################### - -- project: - name: sweetcomb - jobs: - - 'sweetcomb-verify-{stream}-{os}' - - 'sweetcomb-merge-{stream}-{os}' - # - 'sweetcomb-test-{stream}-ubuntu1604' - - project: 'sweetcomb' - os: - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - - centos7: - repo-os-part: 'centos7' - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - '2001': - branch: 'stable/2001' - repo-stream-part: 'stable.2001' - - '1908': - branch: 'stable/1908' - repo-stream-part: 'stable.1908' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - - '1901': - branch: 'stable/1901' - repo-stream-part: 'stable.1901' - - vom: - branch: 'vom' - repo-stream-part: 'vom' - -- project: - name: sweetcomb-view - views: - - project-view - project-name: sweetcomb - -- job-template: - name: 'sweetcomb-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-us' - concurrent: true - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: 120 - - triggers: - - gerrit-trigger-checkstyle: - name: '{project}' - branch: '{branch}' - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - - shell: - !include-raw-escape: include-raw-sweetcomb-checkstyle.sh - - shell: - !include-raw-escape: - - include-raw-sweetcomb-build.sh - publishers: - - lf-infra-publish - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 - -- job-template: - name: 'sweetcomb-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-us' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - stream-parameter: - stream: '{stream}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - - shell: - !include-raw-escape: include-raw-sweetcomb-checkstyle.sh - - shell: - !include-raw-escape: - - include-raw-sweetcomb-build.sh - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - publishers: - - lf-infra-publish - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 - -- job-template: - name: 'sweetcomb-test-{stream}-ubuntu1604' - - project-type: freestyle - node: 'ubuntu1604-us' - concurrent: true - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: 'ubuntu1604' - - repo-name-parameter: - repo-name: '{repo-stream-part}.ubuntu.xenial.main' - - stream-parameter: - stream: '{stream}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: 120 - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - - shell: - !include-raw-escape: - - include-raw-sweetcomb-build.sh - - include-raw-sweetcomb-test.sh - publishers: - - lf-infra-publish - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 - -- project: - name: sweetcomb-info - project-name: sweetcomb - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-2c-2g - project: sweetcomb - branch: master - -- project: - name: sweetcomb-sonar - project: sweetcomb - project-name: sweetcomb - mvn-settings: sweetcomb-settings - sonarcloud: true - sonarcloud-project-organization: '{sonarcloud_project_organization}' - sonarcloud-api-token: '{sonarcloud_api_token}' - sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}' - branch: master - build-node: centos7-docker-2c-2g - jobs: - - gerrit-maven-sonar diff --git a/jjb/tldk/gtest-build.sh b/jjb/tldk/gtest-build.sh deleted file mode 100755 index f5a27e0f2..000000000 --- a/jjb/tldk/gtest-build.sh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/bash -set -e -o pipefail -echo $WORKSPACE -git clone -v https://github.com/google/googletest.git --branch release-1.10.0 \ -$WORKSPACE/googletest -cmake $WORKSPACE/googletest/CMakeLists.txt -make -C $WORKSPACE/googletest -echo GTEST_DIR=$WORKSPACE/googletest/googletest > gtest-env.prop -echo GMOCK_DIR=$WORKSPACE/googletest/googlemock >> gtest-env.prop - -echo "*******************************************************************" -echo "* GTEST BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" - diff --git a/jjb/tldk/include-raw-build.sh b/jjb/tldk/include-raw-build.sh deleted file mode 100755 index d2baf0cf4..000000000 --- a/jjb/tldk/include-raw-build.sh +++ /dev/null @@ -1,58 +0,0 @@ -#!/bin/bash -# basic build script example -set -e -o pipefail -# do nothing but print the current slave hostname -hostname -export CCACHE_DIR=/tmp/ccache -if [ -d $CCACHE_DIR ];then - echo $CCACHE_DIR exists - du -sk $CCACHE_DIR -else - echo $CCACHE_DIR does not exist. This must be a new slave. -fi - -echo "cat /etc/bootstrap.sha" -if [ -f /etc/bootstrap.sha ];then - cat /etc/bootstrap.sha -else - echo "Cannot find /etc/bootstrap.sha" -fi - -echo "cat /etc/bootstrap-functions.sha" -if [ -f /etc/bootstrap-functions.sha ];then - cat /etc/bootstrap-functions.sha -else - echo "Cannot find /etc/bootstrap-functions.sha" -fi - -echo "sha1sum of this script: ${0}" -sha1sum $0 - -# Make TLDK -make - -echo "*******************************************************************" -echo "* TLDK BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" - -# Run unit tests application -sudo $WORKSPACE/x86_64-native-linuxapp-gcc/app/gtest-rfc --lcores=0 -n 2 - -echo "*******************************************************************" -echo "* TLDK UNIT TESTS SUCCESSFUL" -echo "*******************************************************************" - -if [ -f "$WORKSPACE/examples/l4fwd/test/run_test.sh" ] -then - export ETH_DEV="tap" - export L4FWD_PATH=$WORKSPACE/x86_64-native-linuxapp-gcc/app/l4fwd - export L4FWD_FECORE=0 - export L4FWD_BECORE=1 - - sudo -E /bin/bash $WORKSPACE/examples/l4fwd/test/run_test.sh -46a - - echo "*****************************************************************" - echo "* TLDK OFO/LOST SEGMENT TESTS SUCCESSFUL" - echo "*****************************************************************" -fi - diff --git a/jjb/tldk/include-raw-tldk-csit-functional-virl.sh b/jjb/tldk/include-raw-tldk-csit-functional-virl.sh deleted file mode 100644 index 547a000f7..000000000 --- a/jjb/tldk/include-raw-tldk-csit-functional-virl.sh +++ /dev/null @@ -1,52 +0,0 @@ -#!/bin/bash -# Copyright (c) 2017 Cisco and/or its affiliates. -# 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. - -set -xeu -o pipefail - -# Clone tldk and start tests -git clone https://gerrit.fd.io/r/tldk - -# If the git clone fails, complain clearly and exit -if [ $? != 0 ]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/tldk" - exit 1 -fi - -# Clone csit and start tests -git clone https://gerrit.fd.io/r/csit - -# If the git clone fails, complain clearly and exit -if [ $? != 0 ]; then - echo "Failed to run: git clone https://gerrit.fd.io/r/csit" - exit 1 -fi - -# Move the tldk to the csit dir -sudo mv -f ./tldk/ ./csit/ - -cd csit - -# execute nsh_sfc bootstrap script if it exists -if [ -e bootstrap-TLDK.sh ] -then - # make sure that bootstrap-TLDK.sh is executable - chmod +x bootstrap-TLDK.sh - # run the script - ./bootstrap-TLDK.sh -else - echo 'ERROR: No bootstrap-TLDK.sh found' - exit 1 -fi - -# vim: ts=4 ts=4 sts=4 et : diff --git a/jjb/tldk/tldk.yaml b/jjb/tldk/tldk.yaml deleted file mode 100644 index 1cf861359..000000000 --- a/jjb/tldk/tldk.yaml +++ /dev/null @@ -1,264 +0,0 @@ -# Copyright (c) 2017 Cisco and/or its affiliates. -# 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. - ---- -- project: - name: tldk - jobs: - - '{project}-verify-{stream}-{os}' - - '{project}-merge-{stream}-{os}' - - '{project}-verify-image-{stream}-{os}' - - 'tldk-csit-verify-func-{stream}-{os}-virl' - - project: 'tldk' - os: - - ubuntu1604 - stream: - - master: - branch: 'master' - - dev-next-socket: - branch: 'dev-next-socket' - -- project: - name: tldk-view - view: - - project-view - project-name: tldk - -- job-template: - name: '{project}-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: gtest-build.sh - - inject: - properties-file: gtest-env.prop - - shell: - !include-raw-escape: include-raw-build.sh - - publishers: - - lf-infra-publish - -- job-template: - name: '{project}-verify-image-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'verify-images' - projects: - - project-compare-type: 'ANT' - project-pattern: '{project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - builders: - - shell: - !include-raw-escape: gtest-build.sh - - inject: - properties-file: gtest-env.prop - - shell: - !include-raw-escape: include-raw-build.sh - - publishers: - - lf-infra-publish - -- job-template: - name: '{project}-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-builder-4c-4g' - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: gtest-build.sh - - inject: - properties-file: gtest-env.prop - - shell: - !include-raw-escape: include-raw-build.sh - - publishers: - - lf-infra-publish - -- job-template: - name: 'tldk-csit-verify-func-{stream}-{os}-virl' - - project-type: freestyle - node: '{os}-builder-4c-4g' - concurrent: true - archive-artifacts: > - **/csit/report.html - **/csit/log.html - **/csit/output.xml - latest-only: false - - build-discarder: - 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}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-manually-triggered: - name: '{project}' - branch: '{branch}' - comment-trigger-value: 'verify-tldk-func' - - builders: - - shell: - !include-raw-escape: include-raw-tldk-csit-functional-virl.sh - - publishers: - - robot-report: - output-path: '' - - lf-infra-publish - -- project: - name: tldk-info - project-name: tldk - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-2c-2g - project: tldk - branch: master - -- project: - name: tldk-sonar - project: tldk - project-name: tldk - mvn-settings: tldk-settings - sonarcloud: true - sonarcloud-project-organization: '{sonarcloud_project_organization}' - sonarcloud-api-token: '{sonarcloud_api_token}' - sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}' - branch: master - build-node: centos7-docker-2c-2g - jobs: - - gerrit-maven-sonar diff --git a/jjb/trex/trex.yaml b/jjb/trex/trex.yaml deleted file mode 100644 index a72634c64..000000000 --- a/jjb/trex/trex.yaml +++ /dev/null @@ -1,21 +0,0 @@ - ---- -# TRex project has moved to github long time ago. -# https://github.com/cisco-system-traffic-generator/trex-core/blob/master/CONTRIBUTING.md - -# TODO: Do we even need the INFO.yaml job if fd.io git is outdated? - -- project: - name: trex-view - views: - - project-view - project-name: trex - -- project: - name: trex-info - project-name: trex - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-4c-4g - project: trex - branch: master diff --git a/jjb/udpi/include-raw-udpi-build.sh b/jjb/udpi/include-raw-udpi-build.sh deleted file mode 100644 index 7e9b3c0ca..000000000 --- a/jjb/udpi/include-raw-udpi-build.sh +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/bash -# basic build script example -set -xe -o pipefail - -##container server node detection -grep search /etc/resolv.conf || true - -OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') -OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') - -echo OS_ID: $OS_ID -echo OS_VERSION_ID: $OS_VERSION_ID - -function setup { - if ! [ -z ${REPO_NAME} ]; then - echo "INSTALLING VPP-DPKG-DEV from apt/yum repo" - REPO_URL="https://packagecloud.io/fdio/${STREAM}" - echo "REPO_URL: ${REPO_URL}" - # Setup by installing vpp-dev and vpp-lib - if [ "$OS_ID" == "ubuntu" ]; then - if [ -f /etc/apt/sources.list.d/99fd.io.list ];then - echo "Deleting: /etc/apt/sources.list.d/99fd.io.list" - sudo rm /etc/apt/sources.list.d/99fd.io.list - fi - if [ -f /etc/apt/sources.list.d/fdio_master.list ];then - echo "Deleting: /etc/apt/sources.list.d/fdio_master.list" - sudo rm /etc/apt/sources.list.d/fdio_master.list - fi - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.deb.sh | sudo bash - elif [ "$OS_ID" == "centos" ]; then - if [ -f /etc/yum.repos.d/fdio-master.repo ]; then - echo "Deleting: /etc/yum.repos.d/fdio-master.repo" - sudo rm /etc/yum.repos.d/fdio-master.repo - fi - if [ -f /etc/yum.repos.d/fdio_master.repo ]; then - echo "Deleting: /etc/yum.repos.d/fdio_master.repo" - sudo rm /etc/yum.repos.d/fdio_master.repo - fi - curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.rpm.sh | sudo bash - fi - fi -} - -setup - -echo "Building using \"make build-root/build.sh\"" -[ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes install-dep -[ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes build-install-package-hyperscan -[ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes build-package - -echo "*******************************************************************" -echo "* UDPI BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" diff --git a/jjb/udpi/include-raw-udpi-checkstyle.sh b/jjb/udpi/include-raw-udpi-checkstyle.sh deleted file mode 100644 index 8f9dd1af3..000000000 --- a/jjb/udpi/include-raw-udpi-checkstyle.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash - -if [ -f scripts/checkstyle.sh ];then - scripts/checkstyle.sh -else - echo "Cannot find cat build-root/scripts/checkstyle.sh - skipping checkstyle" -fi diff --git a/jjb/udpi/udpi.yaml b/jjb/udpi/udpi.yaml deleted file mode 100644 index fa2b7eee3..000000000 --- a/jjb/udpi/udpi.yaml +++ /dev/null @@ -1,204 +0,0 @@ ---- -######################################################################### -# -# Copyright (c) 2019 Intel and/or its affiliates. -# 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. -######################################################################### - -- project: - name: udpi - jobs: - - 'udpi-verify-{stream}-{os}' - - 'udpi-merge-{stream}-{os}' - - project: 'udpi' - os: - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' - - centos7: - repo-os-part: 'centos7' - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - '2001': - branch: 'stable/2001' - repo-stream-part: 'stable.2001' - -- project: - name: udpi-view - views: - - project-view - project-name: udpi - -- job-template: - name: 'udpi-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-us' - concurrent: true - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: 120 - - triggers: - - gerrit-trigger-checkstyle: - name: '{project}' - branch: '{branch}' - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - - shell: - !include-raw-escape: include-raw-udpi-checkstyle.sh - - shell: - !include-raw-escape: - - include-raw-udpi-build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 - -- job-template: - name: 'udpi-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}-us' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - stream-parameter: - stream: '{stream}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - - shell: - !include-raw-escape: include-raw-udpi-checkstyle.sh - - shell: - !include-raw-escape: - - include-raw-udpi-build.sh - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - - naginator: - rerun-unstable-builds: false - max-failed-builds: 1 - fixed-delay: 90 - -- project: - name: udpi-info - project-name: udpi - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-2c-2g - project: udpi - branch: master - -- project: - name: udpi-sonar - project: udpi - project-name: udpi - mvn-settings: udpi-settings - sonarcloud: true - sonarcloud-project-organization: '{sonarcloud_project_organization}' - sonarcloud-api-token: '{sonarcloud_api_token}' - sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}' - branch: master - build-node: centos7-docker-2c-2g - jobs: - - gerrit-maven-sonar diff --git a/jjb/vpp/docs.yaml b/jjb/vpp/docs.yaml index e48662a7a..006801f41 100644 --- a/jjb/vpp/docs.yaml +++ b/jjb/vpp/docs.yaml @@ -2,76 +2,40 @@ - project: name: docs jobs: - - 'vpp-docs-merge-{stream}' - - 'vpp-docs-verify-{stream}' - - 'vpp-make-test-docs-merge-{stream}' - - 'vpp-make-test-docs-verify-{stream}' + - 'vpp-docs-verify-{stream}-{os}-{executor-arch}' + - 'vpp-docs-merge-{stream}-{os}-{executor-arch}' + - 'vpp-docsonly-verify-{stream}-{os}-{executor-arch}' + - 'vpp-docsonly-merge-{stream}-{os}-{executor-arch}' project: 'vpp' + executor-arch: 'x86_64' os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - stream: - - master: - branch: 'master' - repo-stream-part: 'master' - - '1901': - branch: 'stable/1901' - repo-stream-part: 'stable.1901' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - - '1908': - branch: 'stable/1908' - repo-stream-part: 'stable.1908' - - '2001': - branch: 'stable/2001' - repo-stream-part: 'stable.2001' - - '2005': - branch: 'stable/2005' - repo-stream-part: 'stable.2005' - - type: - - short - - long - -- project: - name: sphinx - jobs: - - 'vpp-sphinx-docs-merge-{stream}' - - 'vpp-sphinx-docs-verify-{stream}' - - project: 'vpp' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - + - 'ubuntu2204' stream: - - master: + - 'master': branch: 'master' - repo-stream-part: 'master' - type: - - short - - long + branch-refspec: '' + - '2310': + branch: 'stable/2310' + branch-refspec: '' + - '2402': + branch: 'stable/2402' + branch-refspec: '' - job-template: - name: 'vpp-docs-verify-{stream}' + name: 'vpp-docs-verify-{stream}-{os}-{executor-arch}' project-type: freestyle - node: ubuntu1804-us + node: 'builder-{os}-prod-{executor-arch}' concurrent: true allow-empty: 'true' fingerprint: false only-if-success: true default-excludes: false - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: @@ -79,11 +43,11 @@ - gerrit-parameter: branch: '{branch}' - os-parameter: - os: 'ubuntu1804' - - maven-exec: - maven-version: 'mvn33-new' + os: '{os}' - stream-parameter: stream: '{stream}' + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' scm: - gerrit-trigger-scm: @@ -101,16 +65,9 @@ branch: '{branch}' builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh - shell: !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh @@ -119,27 +76,23 @@ - ../scripts/vpp/docs.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish-docs-7day + - fdio-infra-publish - job-template: - name: 'vpp-docs-merge-{stream}' + name: 'vpp-docs-merge-{stream}-{os}-{executor-arch}' project-type: freestyle - node: ubuntu1804-us + node: 'builder-{os}-prod-{executor-arch}' concurrent: false - archive-artifacts: '**/build-root/docs/html/*' allow-empty: 'true' fingerprint: false only-if-success: true default-excludes: false - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" parameters: - project-parameter: @@ -147,14 +100,9 @@ - gerrit-parameter: branch: '{branch}' - os-parameter: - os: 'ubuntu1804' - - maven-exec: - maven-version: 'mvn33-new' + os: '{os}' - stream-parameter: stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - description: Artifacts to archive to the logs server. scm: - gerrit-trigger-scm: @@ -168,7 +116,7 @@ triggers: - reverse: - jobs: 'vpp-merge-{stream}-ubuntu1804' + jobs: 'vpp-merge-{stream}-{os}-{executor-arch}' result: 'success' - gerrit: server-name: 'Primary' @@ -188,16 +136,9 @@ notbuilt: true builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh - shell: !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh @@ -206,37 +147,31 @@ - ../scripts/vpp/docs.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish-docs + - fdio-infra-publish - job-template: - name: 'vpp-sphinx-docs-verify-{stream}' + name: 'vpp-docsonly-verify-{stream}-{os}-{executor-arch}' project-type: freestyle - node: ubuntu1804-us + node: 'builder-{os}-prod-{executor-arch}' concurrent: true allow-empty: 'true' fingerprint: false only-if-success: true default-excludes: false - build-discarder: - 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}' - os-parameter: - os: 'ubuntu1804' - - maven-exec: - maven-version: 'mvn33-new' + os: '{os}' - stream-parameter: stream: '{stream}' + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' scm: - gerrit-trigger-scm: @@ -252,219 +187,67 @@ - gerrit: server-name: 'Primary' trigger-on: + - patchset-created-event: + exclude-drafts: 'true' + exclude-trivial-rebase: 'false' + exclude-no-code-change: 'false' + - draft-published-event - comment-added-contains-event: - comment-contains-value: 'run-sphinx-docs-verify' + comment-contains-value: 'recheck-docsonly' projects: - project-compare-type: 'ANT' project-pattern: '{project}' branches: - branch-compare-type: 'ANT' branch-pattern: '**/{branch}' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true + file-paths: + - compare-type: 'REG_EXP' + pattern: '.*docs/.*' + override-votes: true + gerrit-build-notbuilt-verified-value: 0 + gerrit-build-successful-verified-value: 1 + builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' - shell: !include-raw-escape: - - ../scripts/setup_vpp_ubuntu_docker_test.sh + - ../scripts/setup_executor_env.sh - shell: !include-raw-escape: - - ../scripts/vpp/sphinx-docs.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'vpp-sphinx-docs-merge-{stream}' - - project-type: freestyle - node: ubuntu1804-us - concurrent: false - archive-artifacts: 'docs/_build/html/*' - allow-empty: 'true' - fingerprint: false - only-if-success: true - default-excludes: false - - build-discarder: - 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}' - - os-parameter: - os: 'ubuntu1804' - - maven-exec: - maven-version: 'mvn33-new' - - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit: - server-name: 'Primary' - trigger-on: - - comment-added-contains-event: - comment-contains-value: 'run-sphinx-docs-merged' - skip-vote: - successful: true - failed: true - unstable: true - notbuilt: true - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' + - ../scripts/vpp/commitmsg.sh - shell: !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - - ../scripts/vpp/sphinx-docs.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'vpp-make-test-docs-verify-{stream}' - - project-type: freestyle - node: ubuntu1804-us - concurrent: true - allow-empty: 'true' - fingerprint: false - only-if-success: true - default-excludes: false - - build-discarder: - 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}' - - os-parameter: - os: 'ubuntu1804' - - maven-exec: - maven-version: 'mvn33-new' - - stream-parameter: - stream: '{stream}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-checkstyle: - name: '{project}' - branch: '{branch}' - - builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/setup_vpp_ubuntu_docker_test.sh + - ../scripts/vpp/docs.sh - shell: !include-raw-escape: - - ../scripts/vpp/make-test-docs.sh + - ../scripts/vpp/docs_spell.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish-docs-7day + - fdio-infra-publish - job-template: - name: 'vpp-make-test-docs-merge-{stream}' + name: 'vpp-docsonly-merge-{stream}-{os}-{executor-arch}' project-type: freestyle - node: ubuntu1804-us - concurrent: false - archive-artifacts: '**/build-root/build-test/doc/html/*' + node: 'builder-{os}-prod-{executor-arch}' + concurrent: true allow-empty: 'true' fingerprint: false only-if-success: true default-excludes: false - - build-discarder: - 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}' - os-parameter: - os: 'ubuntu1804' - - maven-exec: - maven-version: 'mvn33-new' + os: '{os}' - stream-parameter: stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. scm: - gerrit-trigger-scm: @@ -477,44 +260,44 @@ build-timeout: '{build-timeout}' triggers: - - reverse: - jobs: 'vpp-merge-{stream}-ubuntu1804' - result: 'success' - gerrit: server-name: 'Primary' trigger-on: + - change-merged-event - comment-added-contains-event: - comment-contains-value: 'run-docs' + comment-contains-value: 'remerge-docsonly' projects: - project-compare-type: 'ANT' project-pattern: '{project}' branches: - branch-compare-type: 'ANT' branch-pattern: '**/{branch}' + file-paths: + - compare-type: 'REG_EXP' + pattern: '.*docs/.*' skip-vote: successful: true - failed: true - unstable: true - notbuilt: true + failed: false + unstable: false + notbuilt: false builders: - - maven-target: - maven-version: 'mvn33-new' - goals: '--version' - settings: 'vpp-settings' - settings-type: cfp - global-settings: 'global-settings' - global-settings-type: cfp - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/vpp/commitmsg.sh - shell: !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - - ../scripts/vpp/make-test-docs.sh + - ../scripts/vpp/docs.sh + - shell: + !include-raw-escape: + - ../scripts/vpp/docs_spell.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish-docs + - fdio-infra-publish diff --git a/jjb/vpp/vpp.yaml b/jjb/vpp/vpp.yaml index 0bad3f1a6..62975f004 100644 --- a/jjb/vpp/vpp.yaml +++ b/jjb/vpp/vpp.yaml @@ -1,216 +1,341 @@ +# Copyright (c) 2023 Cisco and/or its affiliates. +# 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. + --- +# PROJECT DEFINITIONS +# +# Please keep projects grouped in this order: +# vpp-x86_64, vpp-aarch64, vpp-csit +# +# NOTES: +# - The 'branch-refspec' attribute is used for sandbox testing. +# Use the get_gerrit_refspec() bash function in +# .../ci-management/extras/bash/sandbox_test_functions.sh +# to query gerrit for the refspec of HEAD in a branch. +# TODO: see if there is a refspec that works without requiring +# use of get_gerrit_refspec and hand entering the result +# in the WebUI 'Build With Parameters' gerrit refspec field. +# [end] NOTES + +# VPP-CHECKSTYLE-X86_64 PROJECT - project: - name: vpp + name: vpp-checkstyle-x86_64 jobs: - - 'vpp-verify-{stream}-{os}' - - 'vpp-verify-{stream}-debug' - - 'vpp-merge-{stream}-{os}' - + - 'vpp-checkstyle-verify-{stream}-{os}-{executor-arch}' project: 'vpp' os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - centos7: - repo-os-part: 'centos7' - + - ubuntu2204 stream: - - master: + - 'master': branch: 'master' - repo-stream-part: 'master' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - - '1908': - branch: 'stable/1908' - repo-stream-part: 'stable.1908' - - '2001': - branch: 'stable/2001' - repo-stream-part: 'stable.2001' - - '2005': - branch: 'stable/2005' - repo-stream-part: 'stable.2005' + branch-refspec: '' + - '2310': + branch: 'stable/2310' + branch-refspec: '' + - '2402': + branch: 'stable/2402' + branch-refspec: '' + executor-arch: 'x86_64' + +# [end] VPP-CHECKSTYLE-X86_64 PROJECT + +# VPP-X86_64 PROJECT +# +# NOTE: The list of supported branches for each OS are maintained +# in .../ci-management/docker/scripts/lib_vpp.sh +# The job configuration must be derived from that list, thus +# modifications to both should be made at the same time. +# Since x86_64 is the primary development architecture, this +# project definition should be identical to the docker image +# build scripts. Other architectures may be a subset. - project: - name: vpp-beta + name: vpp-x86_64 jobs: - - 'vpp-beta-verify-{stream}-{os}' - - 'vpp-beta-merge-{stream}-{os}' - + - 'vpp-verify-{stream}-{os}-{executor-arch}' + - 'vpp-merge-{stream}-{os}-{executor-arch}' project: 'vpp' - os: - - ubuntu2004: - repo-os-part: 'ubuntu.focal.main' - - centos8: - repo-os-part: 'centos8' - + make-parallel-jobs: '4' stream: - - master: + - 'master': branch: 'master' - repo-stream-part: 'master' + branch-refspec: '' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + make-test-multiworker-os: 'debian-11' + - '2310': + branch: 'stable/2310' + branch-refspec: '' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + make-test-multiworker-os: 'debian-11' + - '2402': + branch: 'stable/2402' + branch-refspec: '' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + make-test-multiworker-os: 'debian-11' + os: + - debian11 + - ubuntu2004 + - ubuntu2204 + executor-arch: 'x86_64' +# [end] VPP-X86_64 PROJECT +# VPP-GCC-X86_64 PROJECT - project: - name: vpp-clang + name: vpp-gcc-x86_64 jobs: - - 'vpp-coverity-{stream}' - + - 'vpp-gcc-verify-{stream}-{os}-{executor-arch}' project: 'vpp' + make-parallel-jobs: '4' os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - - centos7: - repo-os-part: 'centos7' - - opensuse: - repo-os-part: 'opensuse' - + - ubuntu2204 + executor-arch: 'x86_64' stream: - - master: + - 'master': branch: 'master' - repo-stream-part: 'master' - + branch-refspec: '' + - '2310': + branch: 'stable/2310' + branch-refspec: '' + - '2402': + branch: 'stable/2402' + branch-refspec: '' + +# [end] VPP-GCC-X86_64 PROJECT + +# VPP-DEBUG-X86_64 PROJECT +# +# Currently a periodic job due to intermittent failures. +# Limiting branches to master, since other branches +# may not get fixes for the intermittent failures. +# - project: - name: vpp-misc + name: vpp-debug-x86_64 jobs: - - 'vpp-checkstyle-verify-{stream}' + - 'vpp-debug-verify-{stream}-{os}-{executor-arch}' project: 'vpp' + make-parallel-jobs: '4' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + comment-trigger-value: 'debug-verify' stream: - - master: + - 'master': branch: 'master' - repo-stream-part: 'master' - - '1901': - branch: 'stable/1901' - repo-stream-part: 'stable.1901' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - - '1908': - branch: 'stable/1908' - repo-stream-part: 'stable.1908' - - '2001': - branch: 'stable/2001' - repo-stream-part: 'stable.2001' - - '2005': - branch: 'stable/2005' - repo-stream-part: 'stable.2005' - os: ubuntu1804 - + branch-refspec: '' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + os: 'ubuntu2204' + executor-arch: 'x86_64' + +# [end] VPP-DEBUG-X86_64 PROJECT + +# VPP-DPDK-RDMA-VERSION-MISMATCH-X86_64 PROJECT +# +# Currently a periodic job due to intermittent failures. +# Limiting branches to master, since other branches +# may not get fixes for the intermittent failures. +# - project: - name: vpp-perpatch + name: vpp-dpdk-rdma-version-mismatch-x86_64 jobs: - - 'vpp-csit-verify-device-{stream}-{device-node-arch}': - make-parallel-jobs: '32' - - 'vpp-csit-verify-perf-{stream}-{node-arch}' + - 'vpp-dpdk-rdma-version-mismatch-{stream}-{os}-{executor-arch}' project: 'vpp' - os: ubuntu1804 - device-executor: 'vpp-csit-device' - executor: '{os}-us' - skip-vote: 'true' - trigger: 'gerrit-trigger-vpp-csit-devicetest-full' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + comment-trigger-value: 'dpdk-rdma-version-mismatch' stream: - - master: + - 'master': branch: 'master' - repo-stream-part: 'master' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - - '1908': - branch: 'stable/1908' - repo-stream-part: 'stable.1908' - - '2001': - branch: 'stable/2001' - repo-stream-part: 'stable.2001' - - '2005': - branch: 'stable/2005' - repo-stream-part: 'stable.2005' - device-node-arch: - - 1n-skx - - 1n-tx2: - device-executor: 'vpp-csit-arm-ubuntu18' - trigger: 'gerrit-trigger-vpp-csit-devicetest-manual' - node-arch: - - 2n-clx - - 2n-skx - - 3n-skx - - 3n-hsw - - 2n-dnv - - 3n-dnv - - 3n-tsh: - executor: 'ubuntu1804arm-s' - make-parallel-jobs: '16' - exclude: - - stream: '1904' - os: 'ubuntu1804' - device-node-arch: '1n-tx2' - + # Once per day at 00:15 + periodicity: '15 0 * * 0-6' + os: 'ubuntu2204' + executor-arch: 'x86_64' + +# [end] VPP-DPDK-RDMA-VERSION-MISMATCH-X86_64 PROJECT + +# VPP-COV-X86_64 PROJECT +# +# A per-patch job to produce code coverage. +# +# TODO: switch OS to ubuntu-22.04 once the skipping of intermittently failing +# tests are removed +# - project: - name: vpp-older-only + name: vpp-cov-x86_64 jobs: - - 'vpp-historic-verify-{stream}-{os}' - - 'vpp-historic-merge-{stream}-{os}' + - 'vpp-cov-verify-{stream}-{os}-{executor-arch}' project: 'vpp' + make-parallel-jobs: '4' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + comment-trigger-value: 'gcov-report' stream: - - '1901': - branch: 'stable/1901' - repo-stream-part: 'stable.1901' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - - '1908': - branch: 'stable/1908' - repo-stream-part: 'stable.1908' - - '2001': - branch: 'stable/2001' - repo-stream-part: 'stable.2001' + - 'master': + branch: 'master' + branch-refspec: '' + # Once per day at 00:25 + periodicity: '25 0 * * 0-6' + os: 'ubuntu2004' + executor-arch: 'x86_64' + +# [end] VPP-COV-X86_64 PROJECT + +# VPP-AARCH64 PROJECT +# +# NOTE: The list of supported branches for each OS are maintained +# in .../ci-management/docker/scripts/lib_vpp.sh +# The job configuration must be derived from that list, thus +# modifications to both should be made at the same time. +# The AARCH64 architecture is in the process of catching up +# with X86_64 in terms of OS coverage. Thus the jobs are +# a subset of those defined in the docker image build script. +- project: + name: vpp-aarch64 + jobs: + - 'vpp-verify-{stream}-{os}-{executor-arch}' + - 'vpp-merge-{stream}-{os}-{executor-arch}' + project: 'vpp' + make-parallel-jobs: '4' + stream: + - 'master': + branch: 'master' + branch-refspec: '' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + make-test-multiworker-os: '' + - '2310': + branch: 'stable/2310' + branch-refspec: '' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + make-test-multiworker-os: '' + - '2402': + branch: 'stable/2402' + branch-refspec: '' + make-test-os: 'ubuntu-20.04 ubuntu-22.04' + make-test-multiworker-os: '' os: - - ubuntu1604: - repo-os-part: 'ubuntu.xenial.main' + - ubuntu2004 + - ubuntu2204 + executor-arch: 'aarch64' +# [end] VPP-AARCH64 PROJECT +# VPP-CSIT-VERIFY-DEVICE PROJECT - project: - name: vpp-arm + name: vpp-csit-verify-device jobs: - - 'vpp-arm-verify-{stream}-{os}' - - 'vpp-arm-merge-{stream}-{os}' + - 'vpp-csit-verify-device-{stream}-{os}-{executor-arch}-{testbed-arch}': + make-parallel-jobs: '32' project: 'vpp' + skip-vote: 'false' stream: - - master: + - 'master': branch: 'master' - repo-stream-part: 'master' - - '1901': - branch: 'stable/1901' - repo-stream-part: 'stable.1901' - - '1904': - branch: 'stable/1904' - repo-stream-part: 'stable.1904' - - '1908': - branch: 'stable/1908' - repo-stream-part: 'stable.1908' - - '2001': - branch: 'stable/2001' - repo-stream-part: 'stable.2001' - - '2005': - branch: 'stable/2005' - repo-stream-part: 'stable.2005' - os: - - ubuntu1804: - repo-os-part: 'ubuntu-arm.bionic.main' - make-parallel-jobs: '16' + branch-refspec: '' + - '2310': + branch: 'stable/2310' + branch-refspec: '' + - '2402': + branch: 'stable/2402' + branch-refspec: '' + testbed-arch: + - 1n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + skip-vote: 'true' + - 1n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + skip-vote: 'true' + exclude: + # 1n-alt testbed not supported + # in CSIT prior to 2402 + - testbed-arch: 1n-alt + stream: '2310' +# [end] VPP-CSIT-VERIFY-DEVICE PROJECT -# TODO: Merge with (e.g.) vpp-perpatch or similar, -# when number of stable branches supported matches. +# VPP-CSIT-VERIFY-PERF PROJECT - project: - name: vpp-api-crc + name: vpp-csit-verify-perf jobs: - - 'vpp-csit-verify-api-crc-{stream}' + - 'vpp-csit-verify-perf-{stream}-{os}-{executor-arch}-{testbed-arch}' + - 'vpp-csit-bisect-{stream}-{os}-{executor-arch}-{testbed-arch}' project: 'vpp' - executor: 'vpp-csit-device' skip-vote: 'false' stream: - # Only master and LTS branches. - - '1908': - branch: 'stable/1908' - repo-stream-part: 'stable.1908' - - master: + - 'master': branch: 'master' - os: ubuntu1804 + branch-refspec: '' + testbed-arch: + - 2n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-clx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 2n-zn2: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icx: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-tsh: + os: 'ubuntu2204' + executor-arch: 'aarch64' + make-parallel-jobs: '16' + - 3n-alt: + os: 'ubuntu2204' + executor-arch: 'aarch64' + make-parallel-jobs: '16' + - 2n-tx2: + os: 'ubuntu2204' + executor-arch: 'aarch64' + make-parallel-jobs: '16' + - 3n-snr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3n-icxd: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3na-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' + - 3nb-spr: + os: 'ubuntu2204' + executor-arch: 'x86_64' +# [end] VPP-CSIT-VERIFY-PERF PROJECT + +# VPP-CSIT-API-CRC PROJECT +# +# Only master and LTS branches are supported. +# +- project: + name: vpp-csit-api-crc + jobs: + - 'vpp-csit-verify-api-crc-{stream}-{os}-{executor-arch}' + project: 'vpp' + executor-arch: 'x86_64' + skip-vote: 'false' + stream: + - 'master': + branch: 'master' + branch-refspec: '' + - '2310': + branch: 'stable/2310' + branch-refspec: '' + - '2402': + branch: 'stable/2402' + branch-refspec: '' + os: + - 'ubuntu2204' +# [end] VPP-CSIT-API-CRC PROJECT +# LF RELENG VPP PROJECTS - project: name: vpp-info project-name: vpp @@ -225,317 +350,36 @@ views: - project-view project-name: vpp +# [end] LF RELENG VPP PROJECTS +# [end] PROJECT DEFINITIONS -- job-template: - name: 'vpp-historic-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}-us' - concurrent: true - archive-artifacts: '/tmp/vpp-failed-unittests/*/* **/core' - - triggers: - - gerrit-trigger-checkstyle: - name: '{project}' - branch: '{branch}' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: '75' - - builders: - - shell: - !include-raw-escape: - - ../scripts/setup_vpp_ubuntu_docker_test.sh - - shell: - !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh - - shell: - !include-raw-escape: - - ../scripts/vpp/build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' +# JOB TEMPLATE DEFINITIONS +# +# Please keep job templates in the same order as they are referenced +# in the project definitions above. +# VPP-CHECKSTYLE-VERIFY JOB TEMPLATE - job-template: - name: 'vpp-historic-merge-{stream}-{os}' + name: 'vpp-checkstyle-verify-{stream}-{os}-{executor-arch}' project-type: freestyle - node: '{os}-us' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' - - stream-parameter: - stream: '{stream}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: 120 - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - - shell: - !include-raw-escape: - - ../scripts/setup_vpp_ubuntu_docker_test.sh - - shell: - !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh - - shell: - !include-raw-escape: - - ../scripts/vpp/build.sh - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'vpp-arm-verify-{stream}-{os}' - - project-type: freestyle - node: '{os}arm-us' + node: 'builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: '/tmp/vpp-failed-unittests/*/* **/core' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' - - gerrit-refspec-parameter - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - fdio-infra-wrappers: - build-timeout: 120 - - triggers: - - gerrit-trigger-checkstyle: - name: '{project}' - branch: '{branch}' - builders: - - shell: - !include-raw-escape: - - ../scripts/setup_vpp_ubuntu_docker_test.sh - - shell: - !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh - - shell: - !include-raw-escape: - - ../scripts/vpp/build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'vpp-arm-merge-{stream}-{os}' - - project-type: freestyle - node: '{os}arm-us' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' - os-parameter: os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' - - stream-parameter: - stream: '{stream}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' - - gerrit-refspec-parameter - - scm: - - gerrit-trigger-scm: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' - - wrappers: - - fdio-infra-wrappers: - build-timeout: 120 - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - - shell: - !include-raw-escape: - - ../scripts/vpp/checkstyle.sh - - shell: - !include-raw-escape: - - ../scripts/setup_vpp_ubuntu_docker_test.sh - - shell: - !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh - - shell: - !include-raw-escape: - - ../scripts/vpp/build.sh - - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'vpp-checkstyle-verify-{stream}' - - project-type: freestyle - node: '{os}-us' - concurrent: true - archive-artifacts: '/tmp/vpp-failed-unittests/*/* **/core' - - build-discarder: - 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}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.ubuntu.bionic.main' - - gerrit-refspec-parameter scm: - gerrit-trigger-scm: @@ -551,7 +395,6 @@ credential-id: VppApiCompatNotify variable: SECRET_WEBEX_TEAMS_ACCESS_TOKEN - triggers: - gerrit: server-name: 'Primary' @@ -564,12 +407,11 @@ - comment-added-contains-event: comment-contains-value: 'checkstylecheck' - comment-added-contains-event: - comment-contains-value: 'docsonly' - - comment-added-contains-event: comment-contains-value: 'recheck' - comment-added-contains-event: comment-contains-value: 'reverify' - # Following two are to cover missing functions of drafts going to review status + # Following two are to cover missing functions of drafts + # going to review status - comment-added-contains-event: comment-contains-value: 'runtest' - comment-added-contains-event: @@ -585,8 +427,6 @@ pattern: ^((?!\/COMMIT_MSG|docs|_abc|_def[\/\.]).)*$ forbidden-file-paths: - compare-type: REG_EXP - pattern: .*docs\/.* - - compare-type: REG_EXP pattern: .*extras\/emacs\/.* disable-strict-forbidden-file-verification: 'true' override-votes: true @@ -606,6 +446,9 @@ builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/vpp/checkstyle.sh - shell: !include-raw-escape: @@ -616,42 +459,45 @@ - shell: !include-raw-escape: - ../scripts/vpp/commitmsg.sh + - shell: + !include-raw-escape: + - ../scripts/vpp/docs_spell.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish + +# [end] VPP-CHECKSTYLE-VERIFY JOB TEMPLATE +# VPP-VERIFY JOB TEMPLATE - job-template: - name: 'vpp-beta-verify-{stream}-{os}' + name: 'vpp-verify-{stream}-{os}-{executor-arch}' project-type: freestyle - node: '{os}-us' + node: 'builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: '/tmp/vpp-failed-unittests/*/* **/core' - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' + - make-test-os-parameter: + make-test-os: '{make-test-os}' + - make-test-multiworker-os-parameter: + make-test-multiworker-os: '{make-test-multiworker-os}' - os-parameter: os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' + - project-parameter: + project: '{project}' - stream-parameter: stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' scm: - gerrit-trigger-scm: @@ -664,58 +510,56 @@ build-timeout: 120 triggers: - - gerrit-trigger-manually-triggered: - comment-trigger-value: 'betacheck' + - gerrit-trigger-checkstyle: name: '{project}' branch: '{branch}' builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh + - ../scripts/setup_vpp_ext_deps.sh - shell: !include-raw-escape: - ../scripts/vpp/build.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish +# [end] VPP-VERIFY JOB TEMPLATE +# VPP-DEBUG-VERIFY JOB TEMPLATE - job-template: - name: 'vpp-verify-{stream}-{os}' + name: 'vpp-debug-verify-{stream}-{os}-{executor-arch}' project-type: freestyle - node: '{os}-us' + node: 'builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: '/tmp/vpp-failed-unittests/*/* **/core' - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' + - make-test-os-parameter: + make-test-os: '{make-test-os}' - os-parameter: os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' + - project-parameter: + project: '{project}' - stream-parameter: stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' - - gerrit-refspec-parameter scm: - gerrit-trigger-scm: @@ -725,110 +569,117 @@ wrappers: - fdio-infra-wrappers: - build-timeout: 120 + build-timeout: '{build-timeout}' triggers: - - gerrit-trigger-checkstyle: + - gerrit-trigger-checkstyle-nonvoting: name: '{project}' branch: '{branch}' builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh + - ../scripts/setup_vpp_ext_deps.sh - shell: !include-raw-escape: - - ../scripts/vpp/build.sh + - ../scripts/vpp/debug-build.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish +# [end] VPP-DEBUG-VERIFY JOB TEMPLATE +# VPP-DPDK-RDMA-VERSION-MISMATCH PERIODIC JOB TEMPLATE - job-template: - name: 'vpp-verify-{stream}-debug' + name: 'vpp-dpdk-rdma-version-mismatch-{stream}-{os}-{executor-arch}' project-type: freestyle - node: 'ubuntu1804-us' + node: 'builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: '/tmp/vpp-failed-unittests/*/* **/core' - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' - gerrit-parameter: branch: '{branch}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' + - make-test-os-parameter: + make-test-os: '{make-test-os}' - os-parameter: - os: 'ubuntu1804' - - repo-name-parameter: - repo-name: '{repo-stream-part}.ubuntu.bionic.main' + os: '{os}' + - project-parameter: + project: '{project}' - stream-parameter: stream: '{stream}' - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' - - gerrit-refspec-parameter scm: - gerrit-trigger-scm: credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' + refspec: '' + choosing-strategy: 'default' wrappers: - fdio-infra-wrappers: build-timeout: '{build-timeout}' triggers: - - gerrit-trigger-checkstyle-nonvoting: + - timed: '{periodicity}' + - gerrit-trigger-manually-triggered: + comment-trigger-value: '{comment-trigger-value}' name: '{project}' branch: '{branch}' builders: - shell: !include-raw-escape: - - ../scripts/setup_vpp_ubuntu_docker_test.sh + - ../scripts/setup_executor_env.sh - shell: !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh + - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - - ../scripts/vpp/debug-build.sh + - ../scripts/vpp/dpdk-rdma-version-mismatch.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - vpp-dpdk-rdma-version-mismatch: + branch: '{branch}' + - fdio-infra-publish +# [end] VPP-DPDK-RDMA-VERSION-MISMATCH PERIODIC JOB TEMPLATE +# VPP-MERGE JOB TEMPLATE - job-template: - name: 'vpp-coverity-{stream}' + name: 'vpp-merge-{stream}-{os}-{executor-arch}' project-type: freestyle - node: 'ubuntu1804-us' - concurrent: true - archive-artifacts: '/tmp/vpp-failed-unittests/*/* **/core' + node: 'builder-{os}-prod-{executor-arch}' - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: '{build-num-to-keep}' - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' - gerrit-parameter: branch: '{branch}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' + - make-test-os-parameter: + make-test-os: '{make-test-os}' + - make-test-multiworker-os-parameter: + make-test-multiworker-os: '{make-test-multiworker-os}' - os-parameter: - os: 'ubuntu1804' - - repo-name-parameter: - repo-name: '{repo-stream-part}.ubuntu.bionic.main' + os: '{os}' + - project-parameter: + project: '{project}' - stream-parameter: stream: '{stream}' @@ -836,190 +687,135 @@ - gerrit-trigger-scm: credentials-id: 'jenkins-gerrit-credentials' refspec: '' - choosing-strategy: 'gerrit' + choosing-strategy: 'default' wrappers: - fdio-infra-wrappers: - build-timeout: '{build-timeout}' + build-timeout: 120 triggers: - - timed: '0 14 * * *' + - gerrit-trigger-patch-merged: + name: '{project}' + branch: '{branch}' builders: + - config-file-provider: + files: + - file-id: '.packagecloud' + target: '/root/.packagecloud' + - config-file-provider: + files: + - file-id: 'packagecloud_api' + target: '/root/packagecloud_api' + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/vpp/commitmsg.sh + - shell: + !include-raw-escape: + - ../scripts/setup_vpp_ubuntu_docker_test.sh + - shell: + !include-raw-escape: + - ../scripts/setup_vpp_ext_deps.sh - shell: - command: !include-raw-escape: ../scripts/vpp/coverity.sh - unstable-return: 42 + !include-raw-escape: + - ../scripts/vpp/build.sh + - shell: + !include-raw-escape: + - ../scripts/packagecloud_push.sh publishers: - - email-ext: - # yamllint disable-line rule:line-length - recipients: 'ejk@cisco.com' - reply-to: '' - content-type: 'text' - subject: 'Coverity run passing as of $BUILD_TIMESTAMP' - # yamllint disable-line rule:line-length - body: | - Coverity run passing. - - ${{FILE,path="output.txt"}} - failure: false - success: true - - email-ext: - # yamllint disable-line rule:line-length - recipients: 'ejk@cisco.com' - reply-to: '' - content-type: 'text' - subject: 'Coverity run UNSTABLE as of $BUILD_TIMESTAMP' - # yamllint disable-line rule:line-length - body: | - Coverity run UNSTABLE. - - Something went wrong with daily scan. - failure: false - unstable: true - - email-ext: - # yamllint disable-line rule:line-length - recipients: 'vpp-dev@lists.fd.io, ejk@cisco.com' - reply-to: '' - content-type: 'text' - subject: 'Coverity run FAILED as of $BUILD_TIMESTAMP' - # yamllint disable-line rule:line-length - body: | - Coverity run failed today. - - ${{FILE,path="output.txt"}} - failure: true - - email-ext: - # yamllint disable-line rule:line-length - recipients: 'vpp-dev@lists.fd.io, ejk@cisco.com' - reply-to: '' - content-type: 'text' - subject: 'Coverity run as of $BUILD_TIMESTAMP' - # yamllint disable-line rule:line-length - body: | - Coverity run fixed today. - - ${{FILE,path="output.txt"}} - failure: false - fixed: true - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish +# [end] VPP-MERGE JOB TEMPLATE +# VPP-GCC-VERIFY JOB TEMPLATE - job-template: - name: 'vpp-merge-{stream}-{os}' + name: 'vpp-gcc-verify-{stream}-{os}-{executor-arch}' project-type: freestyle - node: '{os}-us' + node: 'builder-{os}-prod-{executor-arch}' + concurrent: true - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' - os-parameter: os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' + - project-parameter: + project: '{project}' - stream-parameter: stream: '{stream}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' - - gerrit-refspec-parameter scm: - gerrit-trigger-scm: credentials-id: 'jenkins-gerrit-credentials' - refspec: '' - choosing-strategy: 'default' + refspec: '$GERRIT_REFSPEC' + choosing-strategy: 'gerrit' wrappers: - fdio-infra-wrappers: - build-timeout: '{build-timeout}' + build-timeout: 120 triggers: - - gerrit-trigger-patch-merged: + - gerrit-trigger-checkstyle: name: '{project}' branch: '{branch}' builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - shell: !include-raw-escape: - - ../scripts/vpp/checkstyle.sh + - ../scripts/setup_executor_env.sh - shell: !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh + - ../scripts/setup_vpp_ext_deps.sh - shell: !include-raw-escape: - - ../scripts/vpp/build.sh - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh + - ../scripts/vpp/gcc-build.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish +# [end] VPP-GCC-VERIFY JOB TEMPLATE +# VPP-COV-VERIFY JOB TEMPLATE - job-template: - name: 'vpp-beta-merge-{stream}-{os}' + name: 'vpp-cov-verify-{stream}-{os}-{executor-arch}' project-type: freestyle - node: '{os}-us' + node: 'builder-{os}-prod-{executor-arch}' + concurrent: true - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' - gerrit-parameter: branch: '{branch}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' + - make-test-os-parameter: + make-test-os: '{make-test-os}' - os-parameter: os: '{os}' - - maven-project-parameter: - maven: 'mvn33-new' - - maven-exec: - maven-version: 'mvn33-new' + - project-parameter: + project: '{project}' - stream-parameter: stream: '{stream}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' scm: - gerrit-trigger-scm: @@ -1032,86 +828,72 @@ build-timeout: '{build-timeout}' triggers: + - timed: '{periodicity}' - gerrit-trigger-manually-triggered: - comment-trigger-value: 'betamerge' + comment-trigger-value: '{comment-trigger-value}' name: '{project}' branch: '{branch}' builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - shell: !include-raw-escape: - - ../scripts/vpp/checkstyle.sh + - ../scripts/setup_executor_env.sh - shell: !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh + - ../scripts/setup_vpp_ext_deps.sh - shell: !include-raw-escape: - - ../scripts/vpp/build.sh - - provide-maven-settings: - settings-file: 'vpp-settings' - global-settings-file: 'global-settings' - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh + - ../scripts/vpp/cov-build.sh publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish-cov-7day + - fdio-infra-publish +# [end] VPP-COV-VERIFY JOB TEMPLATE +# VPP-CSIT-VERIFY-DEVICE-PERPATCH JOB TEMPLATE - job-template: - name: 'vpp-csit-verify-device-{stream}-{device-node-arch}' + name: 'vpp-csit-verify-device-{stream}-{os}-{executor-arch}-{testbed-arch}' description: | <ul> <li>executor <ul> - <li>{device-executor} + <li>csit-builder-{os}-prod-{executor-arch} + </ul> + <li>testbed architecture + <ul> + <li>{testbed-arch} </ul> </ul> project-type: freestyle - node: '{device-executor}' + node: 'csit-builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: '**/csit_current/**/*.*' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' + - gerrit-csit-refspec-parameter + - gerrit-event-comment-text-parameter + - gerrit-event-type-parameter - gerrit-parameter: branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' - os-parameter: os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.ubuntu.bionic.main' - - gerrit-refspec-parameter - - gerrit-event-type-parameter - - gerrit-event-comment-text-parameter - - gerrit-csit-refspec-parameter + - project-parameter: + project: '{project}' - stream-parameter: stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - make-parallel-jobs-parameter: - make-parallel-jobs: '{make-parallel-jobs}' scm: - gerrit-trigger-scm: @@ -1124,7 +906,7 @@ build-timeout: '90' triggers: - - '{trigger}': + - 'gerrit-trigger-vpp-csit-devicetest-full': name: '{project}' branch: '{branch}' skip-vote: '{skip-vote}' @@ -1132,28 +914,33 @@ builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh + - ../scripts/setup_vpp_ext_deps.sh - shell: !include-raw-escape: - ../scripts/vpp/csit-device.sh publishers: - - robot-report: - output-path: 'csit_current/' - - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish +# [end] VPP-CSIT-VERIFY-DEVICE-PERPATCH JOB TEMPLATE +# VPP-CSIT-VERIFY-PERF JOB TEMPLATE - job-template: - name: 'vpp-csit-verify-perf-{stream}-{node-arch}' + name: 'vpp-csit-verify-perf-{stream}-{os}-{executor-arch}-{testbed-arch}' description: | <ul> <li>executor <ul> - <li>{executor} + <li>builder-{os}-prod-{executor-arch} + </ul> + <li>testbed architecture + <ul> + <li>{testbed-arch} </ul> <li>Objective Contrary to csit-vpp job, this also measures the parent performance, @@ -1162,44 +949,35 @@ </ul> project-type: freestyle - node: '{executor}' + node: 'builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: > - **/csit_current/**/*.* - **/csit_parent/**/*.* latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.ubuntu.bionic.main' - - gerrit-refspec-parameter - - gerrit-event-type-parameter - - gerrit-event-comment-text-parameter - - gerrit-csit-refspec-parameter - csit-perf-trial-duration-parameter: csit-perf-trial-duration: "10.0" - csit-perf-trial-multiplicity-parameter: csit-perf-trial-multiplicity: "5" - - stream-parameter: - stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + - gerrit-csit-refspec-parameter + - gerrit-event-comment-text-parameter + - gerrit-event-type-parameter + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' + - gerrit-parameter: + branch: '{branch}' - make-parallel-jobs-parameter: make-parallel-jobs: '{make-parallel-jobs}' + - os-parameter: + os: '{os}' + - project-parameter: + project: '{project}' + - stream-parameter: + stream: '{stream}' scm: - gerrit-trigger-scm: @@ -1215,58 +993,166 @@ - gerrit-trigger-csit-perftest: project: '{project}' branch: '{branch}' - trigger-word: 'perftest-{node-arch}' + trigger-word: 'perftest-{testbed-arch}' skip-vote: true builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - - ../scripts/setup_vpp_dpdk_dev_env.sh + - ../scripts/setup_vpp_ext_deps.sh - shell: !include-raw-escape: - ../scripts/vpp/csit-perf.sh publishers: - - robot-report: - output-path: 'csit_current/0/' - - - lf-infra-publish - + - postbuildscript: + # Can be removed when all CSIT branches use correct archive directory. + builders: + - build-on: + - ABORTED + - FAILURE + - NOT_BUILT + - SUCCESS + - UNSTABLE + build-steps: + - shell: + !include-raw-escape: + - ../scripts/vpp/copy_archives.sh + - fdio-infra-publish +# [end] VPP-CSIT-VERIFY-PERF JOB TEMPLATE + +# VPP-CSIT-BISECT JOB TEMPLATE - job-template: - name: 'vpp-csit-verify-api-crc-{stream}' + name: 'vpp-csit-bisect-{stream}-{os}-{executor-arch}-{testbed-arch}' + description: | + <ul> + <li>executor + <ul> + <li>builder-{os}-prod-{executor-arch} + </ul> + <li>testbed architecture + <ul> + <li>{testbed-arch} + </ul> + <li>Objective + <ul> + <li>Find a cause of VPP performance jump among VPP commits. + </ul> + </ul> project-type: freestyle - node: '{os}-us' + node: 'builder-{os}-prod-{executor-arch}' concurrent: true - archive-artifacts: '' latest-only: false - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + # Please keep parameters in alphabetical order parameters: - - project-parameter: - project: '{project}' + - csit-perf-trial-duration-parameter: + csit-perf-trial-duration: "1.0" + - csit-perf-trial-multiplicity-parameter: + csit-perf-trial-multiplicity: "60" + - gerrit-csit-refspec-parameter + - gerrit-event-comment-text-parameter + - gerrit-event-type-parameter + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' - gerrit-parameter: branch: '{branch}' - - gerrit-refspec-parameter - - gerrit-csit-refspec-parameter + - make-parallel-jobs-parameter: + make-parallel-jobs: '{make-parallel-jobs}' + - os-parameter: + os: '{os}' + - project-parameter: + project: '{project}' - stream-parameter: stream: '{stream}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. + + scm: + - gerrit-trigger-scm: + credentials-id: 'jenkins-gerrit-credentials' + refspec: '$GERRIT_REFSPEC' + choosing-strategy: 'gerrit' + + wrappers: + - fdio-infra-wrappers-non-activity-timeout: + build-timeout: 300 + + triggers: + - gerrit-trigger-csit-perftest: + project: '{project}' + branch: '{branch}' + trigger-word: 'bisecttest-{testbed-arch}' + skip-vote: true + + builders: + - shell: + !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: + - ../scripts/setup_vpp_ubuntu_docker_test.sh + - shell: + !include-raw-escape: + - ../scripts/setup_vpp_ext_deps.sh + - shell: + !include-raw-escape: + - ../scripts/vpp/csit-bisect.sh + + publishers: + - postbuildscript: + # Can be removed when all CSIT branches use correct archive directory. + builders: + - build-on: + - ABORTED + - FAILURE + - NOT_BUILT + - SUCCESS + - UNSTABLE + build-steps: + - shell: + !include-raw-escape: + - ../scripts/vpp/copy_archives.sh + - fdio-infra-publish +# [end] VPP-CSIT-BISECT JOB TEMPLATE + +# VPP-CSIT-VERIFY-API-CRC JOB TEMPLATE +- job-template: + name: 'vpp-csit-verify-api-crc-{stream}-{os}-{executor-arch}' + + project-type: freestyle + node: 'builder-{os}-prod-{executor-arch}' + concurrent: true + latest-only: false + + properties: + - lf-infra-properties: + build-days-to-keep: "{build-days-to-keep}" + + # Please keep parameters in alphabetical order + parameters: # Not sure whether not failing has any useful usage, # but it does not hurt to have some flexibility for future. - csit-fail-on-crc-mismatch-parameter: fail-on-crc-mismatch: 'True' + - gerrit-csit-refspec-parameter + - gerrit-parameter: + branch: '{branch}' + - gerrit-refspec-parameter: + refspec: '{branch-refspec}' + - project-parameter: + project: '{project}' + - stream-parameter: + stream: '{stream}' scm: - gerrit-trigger-scm: @@ -1279,8 +1165,6 @@ build-timeout: 300 triggers: - # TODO: Make other verify jobs trigger on success of this one, - # without breaking verification for VPP branches before stable/1908. - gerrit-trigger-checkstyle: name: '{project}' branch: '{branch}' @@ -1288,12 +1172,35 @@ builders: - shell: !include-raw-escape: + - ../scripts/setup_executor_env.sh + - shell: + !include-raw-escape: - ../scripts/setup_vpp_ubuntu_docker_test.sh - shell: !include-raw-escape: - ../scripts/vpp/check_crc.sh - # TODO: Add sending e-mail notifications to vpp-api-dev@lists.fd.io + # TODO: Add sending e-mail notifications to vpp-api-dev@lists.fd.io publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' + - fdio-infra-publish +# [end] VPP-CSIT-VERIFY-API-CRC JOB TEMPLATE +# [end] JOB TEMPLATE DEFINITIONS + +- project: + name: vpp-release + project: vpp + project-name: vpp + build-node: centos8-builder-2c-2g + mvn-settings: vpp-settings + jobs: + - "gerrit-packagecloud-release-verify" + +- project: + name: vpp-packagecloud-release + project: vpp + project-name: vpp + build-node: centos8-builder-2c-2g + mvn-settings: vpp-settings + jobs: + - "gerrit-packagecloud-release-merge" + - "{project-name}-gerrit-release-jobs" diff --git a/jjb/vsap/include-raw-vsap-build.sh b/jjb/vsap/include-raw-vsap-build.sh deleted file mode 100644 index 0f1c6d5d4..000000000 --- a/jjb/vsap/include-raw-vsap-build.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash -# vsap build script -set -xe -o pipefail - -# container server node detection -grep search /etc/resolv.conf || true - -OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') -OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g') - -echo OS_ID: $OS_ID -echo OS_VERSION_ID: $OS_VERSION_ID - -echo "Building using \"make deb-${MODE} openssl3_enable=1 vpp=${STREAM}\"" - -make deb-${MODE} openssl3_enable=1 vpp=${STREAM} -make verify-${MODE} openssl3_enable=1 - -echo "*******************************************************************" -echo "* VSAP ${MODE} ${STREAM} BUILD SUCCESSFULLY COMPLETED" -echo "*******************************************************************" diff --git a/jjb/vsap/vsap.yaml b/jjb/vsap/vsap.yaml deleted file mode 100644 index 711f9b9b2..000000000 --- a/jjb/vsap/vsap.yaml +++ /dev/null @@ -1,193 +0,0 @@ ---- -######################################################################### -# -# Copyright (c) 2019 Intel and/or its affiliates. -# 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. -######################################################################### - -- project: - name: vsap - jobs: - - 'vsap-verify-{stream}-{os}-{mode}' - - 'vsap-merge-{stream}-{os}-{mode}' - - project: 'vsap' - os: - - ubuntu1804: - repo-os-part: 'ubuntu.bionic.main' - stream: - - '2005': - branch: 'stable/2005' - repo-stream-part: 'stable.2005' - mode: - - vcl: - repo-mode-part: 'vcl' - - ldp: - repo-mode-part: 'ldp' - -- project: - name: vsap-view - views: - - project-view - project-name: vsap - -- job-template: - name: 'vsap-verify-{stream}-{os}-{mode}' - - project-type: freestyle - node: '{os}-us' - concurrent: true - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - gerrit-refspec-parameter - - os-parameter: - os: '{os}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}.{repo-mode-part}' - - stream-parameter: - stream: '{stream}' - - mode-parameter: - mode: '{mode}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm-recursive: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - submodule-recursive: true - submodule: - recursive: true - - wrappers: - - fdio-infra-wrappers: - build-timeout: 120 - - triggers: - - gerrit-trigger-patch-submitted: - name: '{project}' - branch: '{branch}' - - builders: - - shell: - !include-raw-escape: - - include-raw-vsap-build.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- job-template: - name: 'vsap-merge-{stream}-{os}-{mode}' - - project-type: freestyle - node: '{os}-us' - - build-discarder: - daysToKeep: '{build-days-to-keep}' - numToKeep: 100 - artifactDaysToKeep: '{build-artifact-days-to-keep}' - artifactNumToKeep: '{build-artifact-num-to-keep}' - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - gerrit-refspec-parameter - - os-parameter: - os: '{os}' - - stream-parameter: - stream: '{stream}' - - mode-parameter: - mode: '{mode}' - - repo-name-parameter: - repo-name: '{repo-stream-part}.{repo-os-part}.{repo-mode-part}' - - string: - name: ARCHIVE_ARTIFACTS - default: '{archive-artifacts}' - description: Artifacts to archive to the logs server. - - scm: - - gerrit-trigger-scm-recursive: - credentials-id: 'jenkins-gerrit-credentials' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - submodule-recursive: true - submodule: - recursive: true - - wrappers: - - fdio-infra-wrappers: - build-timeout: '{build-timeout}' - - triggers: - - gerrit-trigger-patch-merged: - name: '{project}' - branch: '{branch}' - - builders: - - config-file-provider: - files: - - file-id: '.packagecloud' - target: '/root' - - config-file-provider: - files: - - file-id: 'packagecloud_api' - target: '/root' - - shell: - !include-raw-escape: - - include-raw-vsap-build.sh - - shell: - !include-raw-escape: - - ../scripts/packagecloud_push.sh - - publishers: - - fdio-infra-shiplogs: - maven-version: 'mvn36' - -- project: - name: vsap-info - project-name: vsap - jobs: - - gerrit-info-yaml-verify - build-node: centos7-builder-2c-2g - project: vsap - branch: master - -- project: - name: vsap-sonar - project: vsap - project-name: vsap - mvn-settings: vsap-settings - sonarcloud: true - sonarcloud-project-organization: '{sonarcloud_project_organization}' - sonarcloud-api-token: '{sonarcloud_api_token}' - sonarcloud-project-key: '{sonarcloud_project_organization}_{project-name}' - branch: master - build-node: centos7-docker-4c-4g - jobs: - - gerrit-maven-sonar |