diff options
Diffstat (limited to 'jobs')
38 files changed, 1830 insertions, 769 deletions
diff --git a/jobs/README.adoc b/jobs/README.adoc index bea1d9f..eb14152 100644 --- a/jobs/README.adoc +++ b/jobs/README.adoc @@ -5,8 +5,6 @@ https://docs.openstack.org/infra/jenkins-job-builder/index.html[Jenkins Job Buil Install jenkins-job-builder: -For debian 9, see troubleshooting below. Otherwise: - apt-get install jenkins-job-builder Have a jenkins-job-builder.ini file. One of @@ -74,30 +72,78 @@ individual job names. Also be aware that jobs are only actually updated when anything changed. -- debian 9 +*Jenkins labels* -For jenkins-job-builder to work on debian 9: +Most jenkins jobs should run a docker container and install all required +dependencies inside that, so we don't need to install them on the jenkins node. +These jobs don't need to set a label, they can just run on any generic jenkins +node that has docker available. So if you add a new job, you probably don't +need a label at all. -add 'testing' to /etc/apt/sources.list like +Existing jobs typically have a label set by the topic they belong to, e.g.: +- osmocom-master +- osmocom-gerrit +- ttcn3 - deb http://ftp.de.debian.org/debian/ testing main +Other labels indicate specific software/hardware works here, e.g.: +- coverity +- hdlc +- osmo-gsm-tester +- podman -then +*ccache* - sudo apt-get update - sudo apt-get -t testing install python-jenkins - sudo apt-get install jenkins-job-builder +The jobs from master-builds and gerrit-verifications use ccache. View the +statistics with SSH on the build nodes with: -and make sure to *not* pick the python3 versions -(or you'll need to add catching of HTTPError to jenkins/__init__.py in -'def maybe_add_crumb') + $ CCACHE_DIR=~/ccache/gerrit-verifications ccache -s + $ CCACHE_DIR=~/ccache/master-builds ccache -s -*Jenkins labels* +Note that running multiple jobs in parallel influence the ccache statistics, +and it's impossible to tell which job caused which change in the stats (that's +why they are not printed at the end of each job, it would be confusing). + +*timers* + +A lot of the jenkins jobs run daily with a timer: + + triggers: + - timed: "H 20 * * *" + +or weekly: + + triggers: + - timed: "H 20 * * H" + +Use H for the minute / day of week, to have it derivated as hash of the job +name. Replace 20 with the hour (UTC) the job should run. + +The jobs follow this timetable, to ensure we don't attempt to use binary +packages before they have been built (leading to failing jobs). + + 18:00 - 21:00 OBS related + 18:XX osmocom-obs-sync (sync Debian:12 etc. with openSUSE OBS) + 19:XX osmocom-obs-check-new-distros + 19:XX osmocom-obs-wireshark + 20:XX osmocom-obs (new binary packages start building on OBS!) + + 22:00 - 03:00 Jobs that don't need binary packages + 22:XX coverity + 22:XX octsim_osmo-ccid-firmware + 22:XX osmo-gsm-tester-runner (virtual) + 23:XX master-builds-dahdi + 00:XX osmocom-api + 00:XX registry-update-base-images + 01:XX osmocom-build-tags-against-master + 01:XX osmocom-list-commits + 02:XX registry-triggers + 02:XX registry-rebuild-upload-fpga-build (weekly) -The build jobs are using labels to specify on which nodes the job should be run. -Please use the following labels + 04:00 - 18:00 Jobs that need binary packages + ttcn3-testsuites + 04:XX osmocom-release-manuals + 05:XX osmocom-release-tarballs + 06:XX repo-install-test + 06:XX coverity-status (runs intentionally much later than the coverity job) -- osmocom-master-debian8: are nodes which can build osmocom-master and is a debian 8 -- osmocom-master-debian9: are nodes which can build osmocom-master and is a debian 9 -- osmocom-gerrit-debian8: are nodes which can build osmocom-gerrit and is a debian 8 -- osmocom-gerrit-debian9: are nodes which can build osmocom-gerrit and is a debian 9 +master-builds: to avoid complexity, these run throughout the day (H H * * *). diff --git a/jobs/coverity-status.yml b/jobs/coverity-status.yml new file mode 100644 index 0000000..cb7522e --- /dev/null +++ b/jobs/coverity-status.yml @@ -0,0 +1,46 @@ +# Check if the coverity badge says "failed". This can happen for example if we +# use a coverity version that is no longer supported, and it doesn't fail in +# any other obvious way. (SYS#6685) +- project: + name: osmocom-coverity-status + jobs: + - osmocom-coverity-status + +- job: + name: 'osmocom-coverity-status' + project-type: freestyle + defaults: global + description: | + Verify that the coverity badge says "passed" and not "failed" (SYS#6685). + <br> + <br> + <img src="https://scan.coverity.com/projects/7523/badge.svg"> + builders: + - shell: | + coverity/badge_status.sh + publishers: + - email: + recipients: 'jenkins-notifications@lists.osmocom.org' + notify-every-unstable-build: true + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + parameters: + - string: + name: BRANCH + description: osmo-ci.git branch + default: 'origin/master' + scm: + - git: + url: https://gerrit.osmocom.org/osmo-ci + git-config-name: 'Jenkins Builder' + git-config-email: 'jenkins@osmocom.org' + branches: + - '$BRANCH' + triggers: + - timed: "H 06 * * *" + publishers: + - email: + notify-every-unstable-build: true + recipients: 'jenkins-notifications@lists.osmocom.org' diff --git a/jobs/coverity.yml b/jobs/coverity.yml index 74803c7..42c060a 100644 --- a/jobs/coverity.yml +++ b/jobs/coverity.yml @@ -9,13 +9,19 @@ project-type: freestyle defaults: global description: 'Generated by job-builder' - display-name: 'Coverity-Upload' node: coverity builders: - shell: | - cd coverity - export PATH=$PATH:/opt/coverity/current/bin - ./jenkins.sh + docker run \ + --rm=true \ + -e PARALLEL_MAKE="$PARALLEL_MAKE" \ + -u build \ + -v "$PWD:/build" \ + -v "$HOME/osmo-ci/coverity:/home/build/osmo-ci/coverity:ro" \ + -v "/opt/coverity:/opt/coverity:ro" \ + -w /build/coverity \ + "$USER/debian-bookworm-build" \ + ./jenkins.sh publishers: - email: recipients: 'jenkins-notifications@lists.osmocom.org' @@ -37,7 +43,7 @@ branches: - '$BRANCH' triggers: - - timed: "@daily" + - timed: "H 22 * * *" publishers: - email: notify-every-unstable-build: true diff --git a/jobs/gerrit-binpkgs.yml b/jobs/gerrit-binpkgs.yml new file mode 100644 index 0000000..a6cf44b --- /dev/null +++ b/jobs/gerrit-binpkgs.yml @@ -0,0 +1,73 @@ +# This file holds all gerrit verifications for building deb and rpm packages. +# https://jenkins.osmocom.org/jenkins/view/Jenkins-Gerrit/. +# One can simply add a gerrit job by adding project's repository to repos list. + +- project: + name: gerrit-binpkgs + jobs: + - 'gerrit-binpkgs' + +- job: + name: 'gerrit-binpkgs' + project-type: freestyle + node: osmocom-gerrit + concurrent: true + retry-count: 3 # scm checkout + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 1000 + description: | + binary packages job (deb/rpm) of CI for patches sent to + <a href="https://gerrit.osmocom.org">gerrit</a> + </br></br> + Related issue: <a href="https://osmocom.org/issues/2385">OS#2385</a> + + parameters: + !include: gerrit-verifications-parameters.yaml.inc + + scm: + - git: + basedir: '$PROJECT_NAME' + url: '$GERRIT_REPO_URL' + credentials-id: d5eda5e9-b59d-44ba-88d2-43473cb6e42d + branches: + - $GERRIT_BRANCH + refspec: $GERRIT_REFSPEC + name: + choosing-strategy: gerrit + wipe-workspace: true + skip-tag: true + submodule: + recursive: false + + builders: + - shell: |- + # Make obvious which distro we build for, for humans and for parsing + # by scripts/jenkins-gerrit/comment_generate.py + set +x + echo + echo "Building binary packages for distro: '$DISTRO'" + echo + set -x + + # Clone osmo-ci.git + rm -rf osmo-ci + git clone \ + --depth=1 \ + --branch="$BRANCH_CI" \ + https://gerrit.osmocom.org/osmo-ci \ + osmo-ci + git -C osmo-ci log --oneline + + cd "$PROJECT_NAME" + ../osmo-ci/scripts/obs/gerrit_binpkgs.sh "$DISTRO" + + wrappers: + - ansicolor: + colormap: xterm + - ssh-agent-credentials: + users: + - d5eda5e9-b59d-44ba-88d2-43473cb6e42d + +# vim: expandtab tabstop=2 shiftwidth=2 diff --git a/jobs/gerrit-lint.yml b/jobs/gerrit-lint.yml index 602ce68..3039829 100644 --- a/jobs/gerrit-lint.yml +++ b/jobs/gerrit-lint.yml @@ -1,166 +1,56 @@ # This file holds all gerrit lint verifications https://jenkins.osmocom.org/jenkins/view/Jenkins-Gerrit/. -# One can simply add a gerrit job by adding project's repository to repos list. +# Add project's repositories to jobs/gerrit-verifications.yml. When +# pipeline_lint is set for that project, the pipeline will call the gerrit-lint +# job for it. - project: name: gerrit-lint - # following default values can be overridden by each repo - disabled: false - gerrit_url: 'ssh://jenkins@gerrit.osmocom.org:29418' - repos_url: '{gerrit_url}/{repos}' - gerrit_project: '{repos}' - - # in alphabetical order - repos: - - asn1c - - cellmgr-ng - - docker-playground - - libasn1c - - libgtpnl - - libosmo-abis - - libosmo-gprs - - libosmo-netif - - libosmo-pfcp - - libosmo-sccp - - libosmocore - - libsmpp34 - - libtelnet - - libusrp - - openbsc - - openggsn - - osmo-bsc - - osmo-bsc-nat - - osmo-bts - - osmo-hnodeb - - osmo-hnbgw - - osmo-upf - - osmo-ci - - - osmo_dia2gsup: - repos_url: '{gerrit_url}/erlang/{repos}' - gerrit_project: 'erlang/{repos}' - - - osmo-e1-hardware - - osmo-ggsn - - osmo-gsm-manuals - - - osmo_gsup: - repos_url: '{gerrit_url}/erlang/{repos}' - gerrit_project: 'erlang/{repos}' - - - osmo-hlr - - osmo-iuh - - osmo-mgw - - osmo-msc - - osmo-pcap - - osmo-pcu - - - osmo-python-tests: - repos_url: '{gerrit_url}/python/{repos}' - gerrit_project: 'python/{repos}' - - - osmo-sgsn - - - osmo_ss7: - repos_url: '{gerrit_url}/erlang/{repos}' - gerrit_project: 'erlang/{repos}' - - - osmo-sip-connector - - osmo-trx - - osmocom-bb - - osmo-tetra - - osmo-sysmon - - osmo-remsim - - simtrace2 - - osmo-asf4-dfu - - osmo-ccid-firmware - - osmo-e1d - - osmo-cbc - - osmo-e1-recorder - - gapk - - osmo-uecups - - osmo-el2tpd - - osmo-smlc - - osmo-gbproxy - - pysim - - - osmo-ttcn3-hacks: - repos_url: 'https://gerrit.osmocom.org/{repos}' - jobs: - - 'gerrit-{repos}-lint' + - 'gerrit-lint' -- job-template: - name: 'gerrit-{repos}-lint' +- job: + name: 'gerrit-lint' project-type: freestyle - node: osmocom-gerrit-debian9 - disabled: '{obj:disabled}' + node: osmocom-gerrit retry-count: 3 # scm checkout properties: - build-discarder: days-to-keep: 30 - num-to-keep: 120 - artifact-days-to-keep: -1 - artifact-num-to-keep: -1 + num-to-keep: 1000 description: | - Run linting on patches submitted to gerrit for - <a href="https://gerrit.osmocom.org/#/q/status:open+project:{repos}">{repos}</a> + Lint job of CI for patches sent to <a href="https://gerrit.osmocom.org">gerrit</a>. </br></br> Related issue: <a href="https://osmocom.org/issues/5087">OS#5087</a> parameters: - - string: - name: BRANCH_CI - description: | - osmo-ci.git branch - default: 'master' + !include: gerrit-verifications-parameters.yaml.inc scm: - git: basedir: 'code-from-gerrit' - url: '{obj:repos_url}' + url: '$GERRIT_REPO_URL' credentials-id: d5eda5e9-b59d-44ba-88d2-43473cb6e42d branches: - $GERRIT_BRANCH refspec: $GERRIT_REFSPEC - name: choosing-strategy: gerrit wipe-workspace: false skip-tag: true submodule: recursive: false - - git: - basedir: 'osmo-ci' - url: '{gerrit_url}/osmo-ci' - credentials-id: d5eda5e9-b59d-44ba-88d2-43473cb6e42d - branches: - - '$BRANCH_CI' - wipe-workspace: true - - triggers: - - gerrit: - trigger-on: - - patchset-created-event: - exclude-drafts: true - exclude-no-code-change: true - projects: - - project-compare-type: 'PLAIN' - project-pattern: '{obj:gerrit_project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**' - skip-vote: - successful: false - failed: false - unstable: false - notbuilt: false - silent: false - escape-quotes: false - no-name-and-email: false - trigger-for-unreviewed-patches: true - server-name: gerrit.osmocom.org builders: - - shell: 'cd code-from-gerrit && ../osmo-ci/lint/lint_diff.sh HEAD~1' + - shell: | + rm -rf osmo-ci + git clone \ + --depth=1 \ + --branch="$BRANCH_CI" \ + https://gerrit.osmocom.org/osmo-ci \ + osmo-ci + git -C osmo-ci log --oneline + + cd code-from-gerrit + ../osmo-ci/lint/lint_diff.sh HEAD~1 wrappers: - ansicolor: diff --git a/jobs/gerrit-verifications-comment.yml b/jobs/gerrit-verifications-comment.yml new file mode 100644 index 0000000..3ed54ad --- /dev/null +++ b/jobs/gerrit-verifications-comment.yml @@ -0,0 +1,45 @@ +# This job runs at the start/end of the pipeline in gerrit-verifications.yml. +# On start it posts a link to the pipeline to gerrit, and on end a list of +# failed/successful job links together with a vote +V/-V. + +- project: + name: gerrit-verifications-comment + jobs: + - 'gerrit-verifications-comment' + +- job: + name: 'gerrit-verifications-comment' + project-type: freestyle + node: osmocom-gerrit + retry-count: 3 # scm checkout + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 120 + description: | + Send start and result comments to <a href="https://gerrit.osmocom.org">gerrit</a>. + </br></br> + Related issue: <a href="https://osmocom.org/issues/2385">OS#2385</a> + + parameters: + !include: gerrit-verifications-parameters.yaml.inc + + scm: + - git: + url: 'https://gerrit.osmocom.org/osmo-ci' + credentials-id: d5eda5e9-b59d-44ba-88d2-43473cb6e42d + branches: + - '$BRANCH_CI' + wipe-workspace: true + + builders: + - shell: 'cd scripts/jenkins-gerrit && ./comment_send.sh' + + wrappers: + - ansicolor: + colormap: xterm + - ssh-agent-credentials: + users: + - d5eda5e9-b59d-44ba-88d2-43473cb6e42d + +# vim: expandtab tabstop=2 shiftwidth=2 diff --git a/jobs/gerrit-verifications-dahdi.yml b/jobs/gerrit-verifications-dahdi.yml index 51bfb04..5a8b3a6 100644 --- a/jobs/gerrit-verifications-dahdi.yml +++ b/jobs/gerrit-verifications-dahdi.yml @@ -1,25 +1,34 @@ - project: - name: gerrit-dahdi-linux - node: osmocom-gerrit-debian9 + name: gerrit-dahdi-linux-stable + type: stable + repo: 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git' + linux-ver: + - "linux-4.19.y" + - "linux-5.10.y" + - "linux-6.1.y" + jobs: + - 'gerrit-dahdi-linux-{type}-{linux-ver}' + +- project: + name: gerrit-dahdi-linux-torvalds + type: torvalds + repo: 'https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git' linux-ver: - - "v4.19" - - "v5.10" - "master" jobs: - - 'gerrit-dahdi-linux-{linux-ver}' + - 'gerrit-dahdi-linux-{type}-{linux-ver}' + - job-template: - name: 'gerrit-dahdi-linux-{linux-ver}' + name: 'gerrit-dahdi-linux-{type}-{linux-ver}' project-type: freestyle - node: osmocom-gerrit-debian9 + node: osmocom-gerrit concurrent: true retry-count: 0 # scm checkout properties: - build-discarder: days-to-keep: 30 num-to-keep: 120 - artifact-days-to-keep: -1 - artifact-num-to-keep: -1 description: | Pending gerrit code reviews of <a href="https://gerrit.osmocom.org/#/q/status:open+project:dahdi-linux">dahdi-linux</a> @@ -29,26 +38,12 @@ <b>Auto-generated using Jenkins Job Builder. DO NOT EDIT MANUALLY!</b> scm: - - git: - basedir: 'dahdi-linux' - url: 'https://gerrit.osmocom.org/dahdi-linux' - credentials-id: d5eda5e9-b59d-44ba-88d2-43473cb6e42d - branches: - - $GERRIT_BRANCH - refspec: $GERRIT_REFSPEC - choosing-strategy: gerrit - # When the gerrit git repository is configured to wipe-workspace, the - # linux.git clone gets removed as well. Cloning the linux repo takes a - # long time, so only clean both repos, don't remove them. - wipe-workspace: false - clean: - before: true - skip-tag: true - submodule: - recursive: true + # Let jenkins clone the big linux repository and keep it between builds + # (wipe-workspace is false). Clone dahdi-linux with code from gerrit in + # the shell part below. - git: basedir: 'linux' - url: 'https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git' + url: '{repo}' branches: - '{linux-ver}' refspec: '{linux-ver}' @@ -76,18 +71,27 @@ notbuilt: false silent: false escape-quotes: false - no-name-and-email: false - trigger-for-unreviewed-patches: true server-name: gerrit.osmocom.org builders: - shell: | + rm -rf dahdi-linux + git init dahdi-linux + cd dahdi-linux + git config advice.detachedHead false + git fetch \ + --depth=1 \ + https://gerrit.osmocom.org/dahdi-linux \ + "$GERRIT_REFSPEC" + git checkout FETCH_HEAD + cd .. + docker run \ --rm=true \ -e "KSRC=/linux" \ -v "$PWD/dahdi-linux:/build" \ -v "$PWD/linux:/linux" \ - "$USER/debian-buster-jenkins" \ + "$USER/debian-bookworm-build" \ timeout 10m su build -c /build/contrib/jenkins.sh publishers: diff --git a/jobs/gerrit-verifications-parameters.yaml.inc b/jobs/gerrit-verifications-parameters.yaml.inc new file mode 100644 index 0000000..32df1b6 --- /dev/null +++ b/jobs/gerrit-verifications-parameters.yaml.inc @@ -0,0 +1,53 @@ +# This file gets included as parameters element of various jobs in the +# gerrit-verifications pipeline. All of these jobs have the same parameters +# and can be called from one run_job() function, without creating log entries +# about undefined parameters (OS#6261). See gerrit-verifications.yml for more +# information. + +- string: + name: BRANCH_CI + description: | + osmo-ci.git branch + default: 'master' +- string: + name: COMMENT_TYPE + description: set by gerrit verification pipeline job +- string: + name: DISTRO + description: set by gerrit verification pipeline job +- string: + name: GERRIT_BRANCH + description: set by gerrit verification pipeline job +- string: + name: GERRIT_CHANGE_NUMBER + description: set by gerrit verification pipeline job +- string: + name: GERRIT_HOST + description: set by gerrit verification pipeline job +- string: + name: GERRIT_PATCHSET_NUMBER + description: set by gerrit verification pipeline job +- string: + name: GERRIT_PATCHSET_REVISION + description: set by gerrit verification pipeline job +- string: + name: GERRIT_PATCHSET_UPLOADER_NAME + description: set by gerrit verification pipeline job +- string: + name: GERRIT_PORT + description: set by gerrit verification pipeline job +- string: + name: GERRIT_PROJECT + description: set by gerrit verification pipeline job +- string: + name: GERRIT_REFSPEC + description: set by gerrit verification pipeline job +- string: + name: GERRIT_REPO_URL + description: set by gerrit verification pipeline job +- string: + name: PIPELINE_BUILD_URL + description: set by gerrit verification pipeline job +- string: + name: PROJECT_NAME + description: set by gerrit verification pipeline job diff --git a/jobs/gerrit-verifications.yml b/jobs/gerrit-verifications.yml index 85c78b4..607e909 100644 --- a/jobs/gerrit-verifications.yml +++ b/jobs/gerrit-verifications.yml @@ -1,14 +1,39 @@ # This file holds all gerrit build verifications https://jenkins.osmocom.org/jenkins/view/Jenkins-Gerrit/. -# One cane simply add a gerrit job by adding project's repository to repos list. +# One can simply add a gerrit job by adding project's repository to repos list. +# +# Overview of jobs involved in the pipeline: +# https://osmocom.org/projects/osmocom-servers/wiki/Jenkins_gerrit-verifications_Pipeline +# +# How it works: +# * Two jobs get added for each repository: +# gerrit-{repos} +# gerrit-{repos}-build +# * The gerrit-{repos} job is a pipeline that runs the gerrit-{repos}-build job +# and other jobs (linting, building debian packages, ...). The purpose of +# this job is to reduce the amount of comments (and resulting mails) in +# gerrit coming from the jenkins build verification. If each job ran +# separately without this pipeline job, they would each generate mails. +# The gerrit-{repos} job gets triggered from gerrit whenever a new patch to +# test is available. It passes the GERRIT_BRANCH and GERRIT_REFSPEC variables +# from gerrit to the jobs called in the pipeline. +# * The gerrit-{repos}-build job runs contrib/jenkins.sh in docker in a matrix. +# By default the matrix results in only one job, however for some projects we +# use the matrix to build for multiple CPU architectures (x86_64, arm) or use +# it to build multiple configurations of the same project (see osmo-bts). +# +# NOTE: after updating the job with Jenkins Job Builder as usual, check if a +# new pipeline script was generated and approve it here: +# https://jenkins.osmocom.org/jenkins/scriptApproval/ +# This used to be necessary when changing the pipeline script, adding new +# projects etc. But it seems to get auto-approved now. - project: name: gerrit # following default values can be overridden by each repo disabled: false concurrent: true - node: osmocom-gerrit-debian9 # axes related defaults - slave_axis: !!python/tuple [osmocom-gerrit-debian9] + slave_axis: !!python/tuple [osmocom-gerrit] a1_name: a1 a1: !!python/tuple [default] a2_name: a2 @@ -24,11 +49,8 @@ # Documentation for variables (keep in sync!): # https://osmocom.org/projects/osmocom-servers/wiki/Jenkins_build_verification_jobs docker_run: | - ARTIFACT_STORE="$HOME/jenkins_build_artifact_store" - mkdir -p "$ARTIFACT_STORE" docker run --rm=true \ --cap-add SYS_PTRACE \ - -e ARTIFACT_STORE=/artifact_store \ -e ASCIIDOC_WARNINGS_CHECK="1" \ -e HOME=/build \ -e JOB_NAME="$JOB_NAME" \ @@ -39,19 +61,52 @@ -e WITH_MANUALS="1" \ -w /build -i -u build \ -v "$PWD:/build" \ - -v "$ARTIFACT_STORE:/artifact_store" \ - docker_img: '$USER/debian-buster-jenkins' - docker_img_erlang: '$USER/debian-bullseye-erlang' + docker_run_ccache: | + CCACHE_DIR="$HOME/ccache/gerrit-verifications" + mkdir -p "$CCACHE_DIR" + chown osmocom-build:osmocom-build "$CCACHE_DIR" + + docker run --rm=true \ + --cap-add SYS_PTRACE \ + -e ASCIIDOC_WARNINGS_CHECK="1" \ + -e HOME=/build \ + -e JOB_NAME="$JOB_NAME" \ + -e MAKE=make \ + -e OSMOPY_DEBUG_TCP_SOCKETS="1" \ + -e OSMO_GSM_MANUALS_DIR="/opt/osmo-gsm-manuals" \ + -e PARALLEL_MAKE="$PARALLEL_MAKE" \ + -e WITH_MANUALS="1" \ + -w /build -i -u build \ + -v "$PWD:/build" \ + \ + -e CCACHE_DIR="/ccache" \ + -e PATH="/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" \ + -v "$CCACHE_DIR:/ccache" \ + docker_img: '$USER/debian-bookworm-build' + docker_img_erlang: '$USER/debian-bookworm-erlang' timeout_cmd: '/usr/bin/timeout 30m' - cmd: '{docker_run} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh' + cmd: '{docker_run_ccache} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh' gerrit_url: 'ssh://jenkins@gerrit.osmocom.org:29418' repos_url: '{gerrit_url}/{repos}' gerrit_project: '{repos}' + # Which jobs to run in the pipeline + pipeline_build: true + pipeline_lint: true + pipeline_binpkgs: "debian:10 debian:12" # in alphabetical order repos: - - asn1c - - cellmgr-ng + - asn1c: + pipeline_binpkgs: "" + pipeline_lint: false + + - cellmgr-ng: + pipeline_binpkgs: "debian:10 debian:12" + + - docker-playground: + pipeline_build: false + pipeline_binpkgs: "" + - libasn1c - libgtpnl - libosmo-abis @@ -61,13 +116,17 @@ - libosmo-sccp - libosmocore: + slave_axis: !!python/tuple [io_uring] # OS#6405 a1_name: arch a1: !!python/tuple [arm-none-eabi, amd64] combination_filter: '!(arch=="arm-none-eabi" && label=="FreeBSD_amd64")' - cmd: '{docker_run} {docker_img} {timeout_cmd} /build/contrib/jenkins_arch.sh "$arch"' + cmd: '{docker_run_ccache} {docker_img} {timeout_cmd} /build/contrib/jenkins_arch.sh "$arch"' - libsmpp34 - - libtelnet + + - libtelnet: + pipeline_binpkgs: "" + - libusrp - openbsc: @@ -78,11 +137,12 @@ a3_name: IU a3: !!python/tuple [--disable-iu] cmd: | - {docker_run} \ + {docker_run_ccache} \ -e IU="$IU" \ -e SMPP="$SMPP" \ -e MGCP="$MGCP" \ {docker_img} {timeout_cmd} /build/contrib/jenkins.sh + pipeline_binpkgs: "" - openggsn: a1_name: GTP @@ -94,7 +154,7 @@ - osmo-bsc-nat - osmo-bts: - slave_axis: !!python/tuple [osmocom-master-debian9, rpi4-raspbian11] + slave_axis: !!python/tuple [osmocom-gerrit, rpi4-raspbian11] a1_name: FIRMWARE_VERSION a1: !!python/tuple [master, femtobts_v2.7, superfemto_v2.4, superfemto_v3.0.1pre, superfemto_v3.1, superfemto_v5.1, v2017.01, litecell15, oc2g, oc2g-next] a2_name: BTS_MODEL @@ -102,32 +162,60 @@ a3_name: WITH_MANUALS a3: !!python/tuple ["1", "0"] combination_filter: > - (FIRMWARE_VERSION == "master" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || + (FIRMWARE_VERSION == "master" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || (FIRMWARE_VERSION == "master" && BTS_MODEL == "trx" && WITH_MANUALS == "0" && label == "rpi4-raspbian11") || - (FIRMWARE_VERSION == "femtobts_v2.7" && BTS_MODEL == "sysmo" && WITH_MANUALS == "1" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "superfemto_v2.4" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "superfemto_v3.0.1pre" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "superfemto_v3.1" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "superfemto_v5.1" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "v2017.01" && BTS_MODEL == "lc15" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "litecell15" && BTS_MODEL == "lc15" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "oc2g" && BTS_MODEL == "oc2g" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "oc2g-next" && BTS_MODEL == "oc2g" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") + (FIRMWARE_VERSION == "femtobts_v2.7" && BTS_MODEL == "sysmo" && WITH_MANUALS == "1" && label == "osmocom-gerrit") || + (FIRMWARE_VERSION == "superfemto_v2.4" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (FIRMWARE_VERSION == "superfemto_v3.0.1pre" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (FIRMWARE_VERSION == "superfemto_v3.1" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (FIRMWARE_VERSION == "superfemto_v5.1" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (FIRMWARE_VERSION == "v2017.01" && BTS_MODEL == "lc15" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (FIRMWARE_VERSION == "litecell15" && BTS_MODEL == "lc15" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (FIRMWARE_VERSION == "oc2g" && BTS_MODEL == "oc2g" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (FIRMWARE_VERSION == "oc2g-next" && BTS_MODEL == "oc2g" && WITH_MANUALS == "0" && label == "osmocom-gerrit") concurrent: false cmd: | - {docker_run} \ + DOCKER_IMG="{docker_img}" + case "$(arch)" in + arm*) DOCKER_IMG="$DOCKER_IMG-arm" ;; + esac + {docker_run_ccache} \ -e FIRMWARE_VERSION="$FIRMWARE_VERSION" \ -e WITH_MANUALS="$WITH_MANUALS" \ - {docker_img} {timeout_cmd} /build/contrib/jenkins_bts_model.sh "$BTS_MODEL" + "$DOCKER_IMG" {timeout_cmd} /build/contrib/jenkins_bts_model.sh "$BTS_MODEL" - osmo_dia2gsup: repos_url: '{gerrit_url}/erlang/{repos}' gerrit_project: 'erlang/{repos}' cmd: '{docker_run} {docker_img_erlang} {timeout_cmd} /build/contrib/jenkins.sh' + pipeline_binpkgs: "debian:11 debian:12" + + - osmo-epdg: + repos_url: '{gerrit_url}/erlang/{repos}' + gerrit_project: 'erlang/{repos}' + cmd: '{docker_run} {docker_img_erlang} {timeout_cmd} /build/contrib/jenkins.sh' + pipeline_binpkgs: "debian:12" - osmo-e1-hardware: - docker_img: 'registry.osmocom.org/$USER/fpga-build' - cmd: 'docker pull {docker_img} && {docker_run} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh' + a2_name: JOB_TYPE + a2: !!python/tuple ["firmware", "gateware", "manuals", "software"] + cmd: | + DOCKER_IMG="{docker_img}" + case "$JOB_TYPE" in + firmware|gateware|manuals) + DOCKER_IMG="registry.osmocom.org/$USER/fpga-build" + docker pull "$DOCKER_IMG" + ;; + esac + {docker_run} \ + -e JOB_TYPE="$JOB_TYPE" \ + "$DOCKER_IMG" \ + {timeout_cmd} /build/contrib/jenkins.sh + pipeline_binpkgs: "" + + - osmo-ci: + pipeline_build: false + pipeline_binpkgs: "" - osmo-ggsn: a1_name: GTP @@ -138,17 +226,19 @@ (GTP == "--enable-gtp-linux" && WITH_MANUALS == "0") || (GTP == "--disable-gtp-linux" && WITH_MANUALS == "1") cmd: | - {docker_run} \ + {docker_run_ccache} \ -e GTP="$GTP" \ -e WITH_MANUALS="$WITH_MANUALS" \ {docker_img} {timeout_cmd} /build/contrib/jenkins.sh - - osmo-gsm-manuals + - osmo-gsm-manuals: + pipeline_binpkgs: "debian:10 debian:12" - osmo_gsup: repos_url: '{gerrit_url}/erlang/{repos}' gerrit_project: 'erlang/{repos}' - cmd: '{docker_run} {docker_img_erlang} {timeout_cmd} /build/contrib/jenkins.sh' + cmd: '{docker_run_ccache} {docker_img_erlang} {timeout_cmd} /build/contrib/jenkins.sh' + pipeline_binpkgs: "" - osmo-hlr - osmo-iuh @@ -160,10 +250,10 @@ a2_name: WITH_MANUALS a2: !!python/tuple ["1", "0"] combination_filter: > - (IU == "--enable-iu" && WITH_MANUALS == "0") || - (IU == "--disable-iu" && WITH_MANUALS == "1") + (IU == "--enable-iu" && WITH_MANUALS == "1") || + (IU == "--disable-iu" && WITH_MANUALS == "0") cmd: | - {docker_run} \ + {docker_run_ccache} \ -e IU="$IU" \ -e WITH_MANUALS="$WITH_MANUALS" \ {docker_img} {timeout_cmd} /build/contrib/jenkins.sh @@ -171,7 +261,7 @@ - osmo-pcap - osmo-pcu: - slave_axis: !!python/tuple [osmocom-master-debian9, rpi4-raspbian11] + slave_axis: !!python/tuple [osmocom-gerrit, rpi4-raspbian11] a1_name: FIRMWARE_VERSION a1: !!python/tuple [master, v2017.01, litecell15, oc2g] a2_name: with_vty @@ -181,24 +271,29 @@ a4_name: WITH_MANUALS a4: !!python/tuple ["1", "0"] combination_filter: > - (with_vty == "True" && with_dsp == "sysmo" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="v2017.01" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="litecell15" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (with_vty == "True" && with_dsp == "oc2g" && FIRMWARE_VERSION=="oc2g" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (with_vty == "False" && with_dsp == "none" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "1" && label == "osmocom-master-debian9") || + (with_vty == "True" && with_dsp == "sysmo" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="v2017.01" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="litecell15" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (with_vty == "True" && with_dsp == "oc2g" && FIRMWARE_VERSION=="oc2g" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || + (with_vty == "False" && with_dsp == "none" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "1" && label == "osmocom-gerrit") || (with_vty == "False" && with_dsp == "none" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "rpi4-raspbian11") cmd: | - {docker_run} \ + DOCKER_IMG="{docker_img}" + case "$(arch)" in + arm*) DOCKER_IMG="$DOCKER_IMG-arm" ;; + esac + {docker_run_ccache} \ -e FIRMWARE_VERSION="$FIRMWARE_VERSION" \ -e with_vty="$with_vty" \ -e with_dsp="$with_dsp" \ -e WITH_MANUALS="$WITH_MANUALS" \ - {docker_img} {timeout_cmd} /build/contrib/jenkins.sh + "$DOCKER_IMG" {timeout_cmd} /build/contrib/jenkins.sh - osmo-python-tests: repos_url: '{gerrit_url}/python/{repos}' gerrit_project: 'python/{repos}' + pipeline_binpkgs: "debian:10 debian:12" - osmo-sgsn: a1_name: IU @@ -206,10 +301,10 @@ a2_name: WITH_MANUALS a2: !!python/tuple ["1", "0"] combination_filter: > - (IU == "--enable-iu" && WITH_MANUALS == "0") || - (IU == "--disable-iu" && WITH_MANUALS == "1") + (IU == "--enable-iu" && WITH_MANUALS == "1") || + (IU == "--disable-iu" && WITH_MANUALS == "0") cmd: | - {docker_run} \ + {docker_run_ccache} \ -e IU="$IU" \ -e WITH_MANUALS="$WITH_MANUALS" \ {docker_img} {timeout_cmd} /build/contrib/jenkins.sh @@ -218,52 +313,114 @@ repos_url: '{gerrit_url}/erlang/{repos}' gerrit_project: 'erlang/{repos}' cmd: '{docker_run} {docker_img_erlang} {timeout_cmd} /build/contrib/jenkins.sh' + pipeline_binpkgs: "" - osmo-sip-connector - osmo-trx: - slave_axis: !!python/tuple [osmocom-master-debian9,rpi4-raspbian11] + slave_axis: !!python/tuple [osmocom-gerrit,rpi4-raspbian11] a1_name: INSTR - a1: !!python/tuple [--with-sse, --without-sse --with-neon, --with-neon-vfpv4] + a1: !!python/tuple [--with-sse, --without-sse, --with-neon, --with-neon-vfpv4] a2_name: WITH_MANUALS a2: !!python/tuple ["1", "0"] combination_filter: > - (INSTR == "--without-sse" && WITH_MANUALS == "1" && label == "osmocom-master-debian9") || - (INSTR == "--with-sse" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || + (INSTR == "--without-sse" && WITH_MANUALS == "1" && label == "osmocom-gerrit") || + (INSTR == "--with-sse" && WITH_MANUALS == "0" && label == "osmocom-gerrit") || (INSTR == "--with-neon" && WITH_MANUALS == "0" && label == "rpi4-raspbian11") || (INSTR == "--with-neon-vfpv4" && WITH_MANUALS == "0" && label == "rpi4-raspbian11") cmd: | - {docker_run} \ + DOCKER_IMG="{docker_img}" + case "$(arch)" in + arm*) DOCKER_IMG="$DOCKER_IMG-arm" ;; + esac + {docker_run_ccache} \ -e INSTR="$INSTR" \ -e WITH_MANUALS="$WITH_MANUALS" \ - {docker_img} {timeout_cmd} /build/contrib/jenkins.sh + "$DOCKER_IMG" {timeout_cmd} /build/contrib/jenkins.sh + + - osmocom-bb: + pipeline_binpkgs: "debian:12" + + - osmo-tetra: + pipeline_binpkgs: "" + + - osmo-sysmon: + pipeline_binpkgs: "debian:10 debian:12" - - osmocom-bb - - osmo-tetra - - osmo-sysmon - osmo-remsim - simtrace2 + - osmo-opencm3-projects: - docker_img: '$USER/debian-bullseye-jenkins' cmd: '{docker_run} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh' - - osmo-asf4-dfu - - osmo-ccid-firmware + pipeline_binpkgs: "" + + - osmo-asf4-dfu: + pipeline_binpkgs: "" + + - osmo-ccid-firmware: + pipeline_binpkgs: "" + - osmo-e1d - osmo-cbc - - osmo-e1-recorder - - gapk + + - osmo-e1-recorder: + pipeline_binpkgs: "" + + - gapk: + pipeline_binpkgs: "debian:12" + - osmo-uecups - - osmo-el2tpd + + - osmo-el2tpd: + pipeline_binpkgs: "" + - osmo-smlc - osmo-gbproxy - osmo-hnodeb - - osmo-hnbgw - - osmo-upf + + - osmo-hnbgw: + a1_name: PFCP + a1: !!python/tuple ["1", "0"] + a2_name: WITH_MANUALS + a2: !!python/tuple ["1", "0"] + a3_name: NFTABLES + a3: !!python/tuple ["1", "0"] + combination_filter: > + (PFCP == "1" && WITH_MANUALS == "1" && NFTABLES == "1") || + (PFCP == "0" && WITH_MANUALS == "0" && NFTABLES == "0") + cmd: | + {docker_run_ccache} \ + -e PFCP="$PFCP" \ + -e WITH_MANUALS="$WITH_MANUALS" \ + -e NFTABLES="$NFTABLES" \ + {docker_img} {timeout_cmd} /build/contrib/jenkins.sh + + - osmo-upf: + pipeline_binpkgs: "debian:11 debian:12" - pysim: - slave_axis: !!python/tuple [simtester] concurrent: false - cmd: '{timeout_cmd} ./contrib/jenkins.sh' + slave_axis: !!python/tuple [simtester,osmocom-gerrit] + a2_name: JOB_TYPE + a2: !!python/tuple ["test", "distcheck", "pylint", "docs"] + combination_filter: > + (JOB_TYPE == "test" && label == "simtester") || + (JOB_TYPE == "distcheck" && label == "osmocom-gerrit") || + (JOB_TYPE == "pylint" && label == "osmocom-gerrit") || + (JOB_TYPE == "docs" && label == "osmocom-gerrit") + cmd: | + case "$JOB_TYPE" in + "test") + {timeout_cmd} ./contrib/jenkins.sh + ;; + *) + {docker_run} \ + -e JOB_TYPE="$JOB_TYPE" \ + {docker_img} \ + {timeout_cmd} /build/contrib/jenkins.sh + ;; + esac + pipeline_binpkgs: "" - osmo-ttcn3-hacks: slave_axis: !!python/tuple [ttcn3] @@ -271,7 +428,7 @@ docker run \ --rm \ -v "$PWD:/build" \ - "registry.osmocom.org/osmocom-build/debian-bullseye-titan" \ + "registry.osmocom.org/osmocom-build/debian-bookworm-titan" \ {timeout_cmd} \ sh -e -x -c " useradd --uid=1000 build; @@ -280,27 +437,222 @@ su build -c 'make clean'; su build -c 'make compile'; " + pipeline_binpkgs: "" - - dahdi-tools + - dahdi-tools: + pipeline_lint: false + pipeline_binpkgs: "" jobs: - 'gerrit-{repos}' + - 'gerrit-{repos}-build' - job-template: name: 'gerrit-{repos}' + project-type: pipeline + concurrent: true + parameters: + - bool: + name: PIPELINE_BUILD + description: Enable the build job (runs contrib/jenkins.sh) + default: '{obj:pipeline_build}' + - bool: + name: PIPELINE_LINT + description: Enable the lint job + default: '{obj:pipeline_lint}' + - string: + name: REPO_URL + description: Clone URL, to be passed to jobs started in the pipeline + default: '{obj:repos_url}' + - string: + name: PIPELINE_BINPKGS + description: | + Enable the binpkgs job (build deb/rpm packages) for the given space + separated distributions. Empty list disables the binpkgs job. The + distributions must have binary packages in the osmocom:master + repository. + default: '{obj:pipeline_binpkgs}' + dsl: | + def run_job(display_name, job_name, comment_type=null, distro=null) {{ + try {{ + echo "pipeline_${{display_name}}: running job ${{job_name}}" + + // IMPORTANT: Keep gerrit-verifications-parameters.yaml.inc in sync + // with the list of parameters here, and make sure all jobs passed + // to run_job() include the .yaml.inc file. (OS#6261) + build job: job_name, parameters: [ + string(name: "COMMENT_TYPE", value: comment_type), + string(name: "DISTRO", value: distro), + string(name: "GERRIT_BRANCH", value: "${{env.GERRIT_BRANCH}}"), + string(name: "GERRIT_CHANGE_NUMBER", value: "${{env.GERRIT_CHANGE_NUMBER}}"), + string(name: "GERRIT_HOST", value: "${{env.GERRIT_HOST}}"), + string(name: "GERRIT_PATCHSET_NUMBER", value: "${{env.GERRIT_PATCHSET_NUMBER}}"), + string(name: "GERRIT_PATCHSET_REVISION", value: "${{env.GERRIT_PATCHSET_REVISION}}"), + string(name: "GERRIT_PATCHSET_UPLOADER_NAME", value: "${{env.GERRIT_PATCHSET_UPLOADER_NAME}}"), + string(name: "GERRIT_PORT", value: "${{env.GERRIT_PORT}}"), + string(name: "GERRIT_PROJECT", value: "${{env.GERRIT_PROJECT}}"), + string(name: "GERRIT_REFSPEC", value: "${{env.GERRIT_REFSPEC}}"), + string(name: "GERRIT_REPO_URL", value: "${{env.REPO_URL}}"), + string(name: "PIPELINE_BUILD_URL", value: "${{env.BUILD_URL}}"), + string(name: "PROJECT_NAME", value: "{repos}"), + ] + echo "pipeline_${{display_name}}: SUCCESS" + }} catch (Exception e) {{ + echo "pipeline_${{display_name}}: FAILED" + }} + }} + + pipeline {{ + agent none + stages {{ + stage("Verification") {{ + parallel {{ + + // Run the comment job to add the pipeline link to gerrit + stage("Start Comment") {{ + steps {{ + script {{ + run_job("comment_start", "gerrit-verifications-comment", "start") + }} + }} + }} + + stage("Build") {{ + when {{ + expression {{ params.PIPELINE_BUILD }} + }} + steps {{ + script {{ + run_job("build", "gerrit-{repos}-build") + }} + }} + }} + + stage("Lint") {{ + when {{ + expression {{ params.PIPELINE_LINT }} + }} + steps {{ + script {{ + run_job("lint", "gerrit-lint") + }} + }} + }} + + // Generating binpkgs stages is not possible if we want to run + // them in parallel and not have another job that just waits + // until they complete. + + stage("binpkgs-0") {{ + when {{ + expression {{ params.PIPELINE_BINPKGS.split().size() > 0 }} + }} + steps {{ + script {{ + distro = params.PIPELINE_BINPKGS.split()[0] + run_job(distro, "gerrit-binpkgs", null, distro) + }} + }} + }} + + stage("binpkgs-1") {{ + when {{ + expression {{ params.PIPELINE_BINPKGS.split().size() > 1 }} + }} + steps {{ + script {{ + distro = params.PIPELINE_BINPKGS.split()[1] + run_job(distro, "gerrit-binpkgs", null, distro) + }} + }} + }} + + stage("binpkgs-2") {{ + when {{ + expression {{ params.PIPELINE_BINPKGS.split().size() > 2 }} + }} + steps {{ + script {{ + distro = params.PIPELINE_BINPKGS.split()[2] + run_job(distro, "gerrit-binpkgs", null, distro) + }} + }} + }} + + }} // end of parallel + }} // end of Verification stage + + // Run the comment job to get successful/failed links and add a + // comment + vote to gerrit + stage("Result Comment") {{ + steps {{ + script {{ + run_job("comment_result", "gerrit-verifications-comment", "result") + }} + }} + }} + + }} + }} + disabled: '{obj:disabled}' + retry-count: 3 # scm checkout + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 1000 + description: | + Pipeline of CI for patches sent to + <a href="https://gerrit.osmocom.org/#/q/status:open+project:{repos}">{repos}</a> + <br/><br/> + <b>Auto-generated using Jenkins Job Builder. DO NOT EDIT MANUALLY!</b> + + scm: + - git: + url: '{obj:repos_url}' + credentials-id: d5eda5e9-b59d-44ba-88d2-43473cb6e42d + branches: + - $GERRIT_BRANCH + refspec: $GERRIT_REFSPEC + name: + choosing-strategy: gerrit + wipe-workspace: false + skip-tag: true + submodule: + recursive: true + + triggers: + - gerrit: + trigger-on: + - patchset-created-event: + exclude-drafts: true + exclude-no-code-change: true + projects: + - project-compare-type: 'PLAIN' + project-pattern: '{obj:gerrit_project}' + branches: + - branch-compare-type: 'ANT' + branch-pattern: '**' + skip-vote: + successful: false + failed: false + unstable: false + notbuilt: false + silent: true # comment + vote is done in gerrit-pipeline-result.yml + escape-quotes: false + server-name: gerrit.osmocom.org + +- job-template: + name: 'gerrit-{repos}-build' project-type: matrix - node: '{node}' concurrent: '{obj:concurrent}' disabled: '{obj:disabled}' retry-count: 3 # scm checkout properties: - build-discarder: days-to-keep: 30 - num-to-keep: 120 - artifact-days-to-keep: -1 - artifact-num-to-keep: -1 + num-to-keep: 1000 description: | - Pending gerrit code reviews of + Build job of CI for patches sent to <a href="https://gerrit.osmocom.org/#/q/status:open+project:{repos}">{repos}</a> <br/><br/> <b>Auto-generated using Jenkins Job Builder. DO NOT EDIT MANUALLY!</b> @@ -345,28 +697,8 @@ submodule: recursive: true - triggers: - - gerrit: - trigger-on: - - patchset-created-event: - exclude-drafts: true - exclude-no-code-change: true - projects: - - project-compare-type: 'PLAIN' - project-pattern: '{obj:gerrit_project}' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**' - skip-vote: - successful: false - failed: false - unstable: false - notbuilt: false - silent: false - escape-quotes: false - no-name-and-email: false - trigger-for-unreviewed-patches: true - server-name: gerrit.osmocom.org + parameters: + !include: gerrit-verifications-parameters.yaml.inc builders: - shell: '{obj:cmd}' diff --git a/jobs/master-builds-dahdi.yml b/jobs/master-builds-dahdi.yml index a404487..8f6d070 100644 --- a/jobs/master-builds-dahdi.yml +++ b/jobs/master-builds-dahdi.yml @@ -1,25 +1,33 @@ - project: - name: master-builds-dahdi-linux - node: osmocom-gerrit-debian9 + name: master-builds-dahdi-linux-stable + type: stable + repo: 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git' + linux-ver: + - "linux-4.19.y" + - "linux-5.10.y" + - "linux-6.1.y" + jobs: + - 'master-dahdi-linux-{type}-{linux-ver}' + +- project: + name: master-builds-dahdi-linux-torvalds + type: torvalds + repo: 'https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git' linux-ver: - - "v4.19" - - "v5.10" - "master" jobs: - - 'master-dahdi-linux-{linux-ver}' + - 'master-dahdi-linux-{type}-{linux-ver}' - job-template: - name: 'master-dahdi-linux-{linux-ver}' + name: 'master-dahdi-linux-{type}-{linux-ver}' project-type: freestyle - node: osmocom-master-debian9 + node: osmocom-master concurrent: true retry-count: 0 # scm checkout properties: - build-discarder: days-to-keep: 30 num-to-keep: 120 - artifact-days-to-keep: -1 - artifact-num-to-keep: -1 description: | Automatic jenkins test job of <a href="https://gerrit.osmocom.org/#/q/status:open+project:dahdi-linux">dahdi-linux</a> @@ -29,24 +37,12 @@ <b>Auto-generated using Jenkins Job Builder. DO NOT EDIT MANUALLY!</b> scm: - - git: - basedir: 'dahdi-linux' - url: 'https://gerrit.osmocom.org/dahdi-linux' - credentials-id: d5eda5e9-b59d-44ba-88d2-43473cb6e42d - branches: - - 'origin/master' - # When the gerrit git repository is configured to wipe-workspace, the - # linux.git clone gets removed as well. Cloning the linux repo takes a - # long time, so only clean both repos, don't remove them. - wipe-workspace: false - clean: - before: true - skip-tag: true - submodule: - recursive: true + # Let jenkins clone the big linux repository and keep it between builds + # (wipe-workspace is false). Clone dahdi-linux with code from gerrit in + # the shell part below. - git: basedir: 'linux' - url: 'https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git' + url: '{repo}' branches: - '{linux-ver}' refspec: '{linux-ver}' @@ -56,16 +52,22 @@ before: true triggers: - - timed: "H H * * *" + - timed: "H 23 * * *" builders: - shell: | + rm -rf dahdi-linux + git clone \ + --depth=1 \ + https://gerrit.osmocom.org/dahdi-linux + git -C dahdi-linux log --oneline + docker run \ --rm=true \ -e "KSRC=/linux" \ -v "$PWD/dahdi-linux:/build" \ -v "$PWD/linux:/linux" \ - "$USER/debian-buster-jenkins" \ + "$USER/debian-bookworm-build" \ timeout 10m su build -c /build/contrib/jenkins.sh publishers: diff --git a/jobs/master-builds.yml b/jobs/master-builds.yml index 7fc306f..a902be8 100644 --- a/jobs/master-builds.yml +++ b/jobs/master-builds.yml @@ -5,9 +5,8 @@ # following default values can be overridden by each repo disabled: false concurrent: true - node: 'osmocom-master-debian9' # axes related defaults - slave_axis: !!python/tuple [osmocom-master-debian9] + slave_axis: !!python/tuple [osmocom-master] a1_name: a1 a1: !!python/tuple [default] a2_name: a2 @@ -23,34 +22,68 @@ # Documentation for variables (keep in sync!): # https://osmocom.org/projects/osmocom-servers/wiki/Jenkins_build_verification_jobs docker_run: | - ARTIFACT_STORE="$HOME/jenkins_build_artifact_store" - mkdir -p "$ARTIFACT_STORE" docker run --rm=true \ --cap-add SYS_PTRACE \ - -e ARTIFACT_STORE=/artifact_store \ -e ASCIIDOC_WARNINGS_CHECK="1" \ -e HOME=/build \ + -e IS_MASTER_BUILD=1 \ -e JOB_NAME="$JOB_NAME" \ -e MAKE=make \ -e OSMOPY_DEBUG_TCP_SOCKETS="1" \ -e OSMO_GSM_MANUALS_DIR="/opt/osmo-gsm-manuals" \ -e PARALLEL_MAKE="$PARALLEL_MAKE" \ -e PUBLISH="1" \ + -e SSH_AUTH_SOCK=/ssh-agent \ -e WITH_MANUALS="1" \ -w /build -i -u build \ + -v $(readlink -f $SSH_AUTH_SOCK):/ssh-agent \ -v "$PWD:/build" \ - -v "$ARTIFACT_STORE:/artifact_store" \ -v "$HOME/.ssh:/home/build/.ssh:ro" \ - docker_img: '$USER/debian-buster-jenkins' - cmd: '{docker_run} {docker_img} /build/contrib/jenkins.sh' - wrappers: [] + docker_run_ccache: | + CCACHE_DIR="$HOME/ccache/master-builds" + mkdir -p "$CCACHE_DIR" + chown osmocom-build:osmocom-build "$CCACHE_DIR" + + docker run --rm=true \ + --cap-add SYS_PTRACE \ + -e ASCIIDOC_WARNINGS_CHECK="1" \ + -e HOME=/build \ + -e IS_MASTER_BUILD=1 \ + -e JOB_NAME="$JOB_NAME" \ + -e MAKE=make \ + -e OSMOPY_DEBUG_TCP_SOCKETS="1" \ + -e OSMO_GSM_MANUALS_DIR="/opt/osmo-gsm-manuals" \ + -e PARALLEL_MAKE="$PARALLEL_MAKE" \ + -e PUBLISH="1" \ + -e SSH_AUTH_SOCK=/ssh-agent \ + -e WITH_MANUALS="1" \ + -w /build -i -u build \ + -v $(readlink -f $SSH_AUTH_SOCK):/ssh-agent \ + -v "$PWD:/build" \ + -v "$HOME/.ssh:/home/build/.ssh:ro" \ + \ + -e CCACHE_DIR="/ccache" \ + -e PATH="/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" \ + -v "$CCACHE_DIR:/ccache" \ + docker_img: '$USER/debian-bookworm-build' + docker_img_erlang: '$USER/debian-bookworm-erlang' + timeout_cmd: '/usr/bin/timeout 30m' + cmd: '{docker_run_ccache} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh' trigger: email: jenkins-notifications@lists.osmocom.org laforge@gnumonks.org - git_base_url: https://gerrit.osmocom.org + gerrit_url: 'https://gerrit.osmocom.org' + gitea_url: 'https://gitea.osmocom.org' + repos_url: '{gerrit_url}/{repos}' + branches: + - master + ssh: + - docs_ftp.osmocom.org # in alphabetical order repos: - - asn1c + - asn1c: + branches: + - osmo-iuh/master - libasn1c: # Full triggers would be: @@ -73,10 +106,10 @@ master-libosmo-netif, master-osmo-bts - libosmo-dsp: - git_base_url: https://gitea.osmocom.org/sdr + repos_url: '{gitea_url}/sdr/{repos}' cmd: | - {docker_run} \ - {docker_img} sh -ex -c \ + {docker_run_ccache} \ + {docker_img} {timeout_cmd} sh -ex -c \ 'autoreconf -fi; \ ./configure; \ $MAKE $PARALLEL_MAKE; \ @@ -133,17 +166,18 @@ master-osmo-sgsn - libosmocore: + slave_axis: !!python/tuple [io_uring] # OS#6405 a1_name: arch a1: !!python/tuple [arm-none-eabi, amd64] combination_filter: '!(arch=="arm-none-eabi" && label=="FreeBSD_amd64")' - cmd: '{docker_run} {docker_img} /build/contrib/jenkins_arch.sh "$arch"' + cmd: '{docker_run_ccache} {docker_img} {timeout_cmd} /build/contrib/jenkins_arch.sh "$arch"' # Full triggers would be: # trigger: > # master-libosmo-abis, master-libosmo-netif, master-libosmo-sccp, master-openbsc, # master-osmo-bsc, master-osmo-bts, master-osmo-ggsn, master-osmo-gmr, master-osmo-hlr, # master-osmo-iuh, master-osmo-mgw, master-osmo-msc, master-osmo-pcap, master-osmo-pcu, # master-osmo-sgsn, master-osmo-sip-connector, master-osmo-tetra, master-osmo-hnodeb - # master-osmocom-bb, SIMtrace, xgoldmon + # master-osmocom-bb, master-simtrace, master-xgoldmon # Optimized: # libosmocore # -> master-libosmo-abis @@ -181,8 +215,8 @@ master-osmo-tetra, master-osmo-trx, master-osmocom-bb, - SIMtrace, - xgoldmon + master-simtrace, + master-xgoldmon - libsmpp34: trigger: master-osmo-msc, master-openbsc @@ -199,17 +233,17 @@ a3_name: IU a3: !!python/tuple [--disable-iu] cmd: | - {docker_run} \ + {docker_run_ccache} \ -e IU="$IU" \ -e SMPP="$SMPP" \ -e MGCP="$MGCP" \ - {docker_img} /build/contrib/jenkins.sh + {docker_img} {timeout_cmd} /build/contrib/jenkins.sh - osmo-bsc - osmo-bsc-nat - osmo-bts: - slave_axis: !!python/tuple [osmocom-master-debian9, rpi4-raspbian11] + slave_axis: !!python/tuple [osmocom-master, rpi4-raspbian11] a1_name: FIRMWARE_VERSION a1: !!python/tuple [master, femtobts_v2.7, superfemto_v2.4, superfemto_v3.0.1pre, superfemto_v3.1, superfemto_v5.1, v2017.01, origin/nrw/litecell15, origin/nrw/oc2g] a2_name: BTS_MODEL @@ -217,34 +251,72 @@ a3_name: WITH_MANUALS a3: !!python/tuple ["1", "0"] combination_filter: > - (FIRMWARE_VERSION == "master" && WITH_MANUALS == "1" && label == "osmocom-master-debian9") || + (FIRMWARE_VERSION == "master" && WITH_MANUALS == "1" && label == "osmocom-master") || (FIRMWARE_VERSION == "master" && BTS_MODEL == "trx" && WITH_MANUALS == "0" && label == "rpi4-raspbian11") || - (FIRMWARE_VERSION == "femtobts_v2.7" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "superfemto_v2.4" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "superfemto_v3.0.1pre" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "superfemto_v3.1" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "superfemto_v5.1" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "v2017.01" && BTS_MODEL == "lc15" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "origin/nrw/litecell15" && BTS_MODEL == "lc15" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (FIRMWARE_VERSION == "origin/nrw/oc2g" && BTS_MODEL == "oc2g" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") + (FIRMWARE_VERSION == "femtobts_v2.7" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master") || + (FIRMWARE_VERSION == "superfemto_v2.4" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master") || + (FIRMWARE_VERSION == "superfemto_v3.0.1pre" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master") || + (FIRMWARE_VERSION == "superfemto_v3.1" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master") || + (FIRMWARE_VERSION == "superfemto_v5.1" && BTS_MODEL == "sysmo" && WITH_MANUALS == "0" && label == "osmocom-master") || + (FIRMWARE_VERSION == "v2017.01" && BTS_MODEL == "lc15" && WITH_MANUALS == "0" && label == "osmocom-master") || + (FIRMWARE_VERSION == "origin/nrw/litecell15" && BTS_MODEL == "lc15" && WITH_MANUALS == "0" && label == "osmocom-master") || + (FIRMWARE_VERSION == "origin/nrw/oc2g" && BTS_MODEL == "oc2g" && WITH_MANUALS == "0" && label == "osmocom-master") concurrent: false cmd: | - {docker_run} \ + DOCKER_IMG="{docker_img}" + case "$(arch)" in + arm*) DOCKER_IMG="$DOCKER_IMG-arm" ;; + esac + {docker_run_ccache} \ -e FIRMWARE_VERSION="$FIRMWARE_VERSION" \ -e WITH_MANUALS="$WITH_MANUALS" \ - {docker_img} /build/contrib/jenkins_bts_model.sh "$BTS_MODEL" + "$DOCKER_IMG" {timeout_cmd} /build/contrib/jenkins_bts_model.sh "$BTS_MODEL" + + - osmo_dia2gsup: + repos_url: '{gerrit_url}/erlang/{repos}' + cmd: '{docker_run} {docker_img_erlang} {timeout_cmd} /build/contrib/jenkins.sh' + + - osmo-epdg: + repos_url: '{gerrit_url}/erlang/{repos}' + cmd: '{docker_run} {docker_img_erlang} {timeout_cmd} /build/contrib/jenkins.sh' - osmo-e1-hardware: + a2_name: JOB_TYPE + a2: !!python/tuple ["firmware", "gateware", "manuals", "software"] + cmd: | + DOCKER_IMG="{docker_img}" + case "$JOB_TYPE" in + firmware|gateware) + DOCKER_IMG="registry.osmocom.org/$USER/fpga-build" + docker pull "$DOCKER_IMG" + ;; + esac + {docker_run} \ + -e JOB_TYPE="$JOB_TYPE" \ + "$DOCKER_IMG" \ + {timeout_cmd} /build/contrib/jenkins.sh --publish + ssh: + - binaries_ftp.osmocom.org + - docs_ftp.osmocom.org + - ice40-usbtrace: + repos_url: '{gitea_url}/electronics/{repos}' docker_img: 'registry.osmocom.org/$USER/fpga-build' - cmd: 'docker pull {docker_img} && {docker_run} {docker_img} /build/contrib/jenkins.sh --publish' + cmd: 'docker pull {docker_img} && {docker_run} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh --publish' + ssh: + - binaries_ftp.osmocom.org + - docs_ftp.osmocom.org - no2bootloader: - git_base_url: https://github.com/no2fpga + repos_url: 'https://github.com/no2fpga/{repos}' docker_img: 'registry.osmocom.org/$USER/fpga-build' - cmd: 'docker pull {docker_img} && {docker_run} {docker_img} /build/contrib/jenkins.sh --publish' + cmd: 'docker pull {docker_img} && {docker_run} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh --publish' email: jenkins-notifications@lists.osmocom.org laforge@gnumonks.org kredon@sysmocom.de 246tnt@gmail.com + ssh: + - binaries_ftp.osmocom.org + - docs_ftp.osmocom.org - osmo-fl2k: - git_base_url: https://gitea.osmocom.org/sdr + repos_url: '{gitea_url}/sdr/{repos}' + - osmo-ggsn: a1_name: GTP a1: !!python/tuple [--enable-gtp-linux,--disable-gtp-linux] @@ -254,23 +326,26 @@ (GTP == "--enable-gtp-linux" && WITH_MANUALS == "0") || (GTP == "--disable-gtp-linux" && WITH_MANUALS == "1") cmd: | - {docker_run} \ + {docker_run_ccache} \ -e GTP="$GTP" \ -e WITH_MANUALS="$WITH_MANUALS" \ - {docker_img} /build/contrib/jenkins.sh + {docker_img} {timeout_cmd} /build/contrib/jenkins.sh trigger: master-osmo-sgsn - osmo-upf - osmo-gmr: - git_base_url: https://gitea.osmocom.org/satellite + repos_url: '{gitea_url}/satellite/{repos}' email: jenkins-notifications@lists.osmocom.org 246tnt@gmail.com - - osmo-gsm-manuals: - node: 'osmocom-master-debian9' + - osmo-gsm-manuals + + - osmo_gsup: + repos_url: '{gerrit_url}/erlang/{repos}' + cmd: '{docker_run_ccache} {docker_img_erlang} {timeout_cmd} /build/contrib/jenkins.sh' - osmo-gsm-tester: - cmd: '{docker_run} {docker_img} /build/contrib/jenkins-build-manuals.sh' + cmd: '{docker_run} {docker_img} {timeout_cmd} /build/contrib/jenkins-build-manuals.sh' - osmo-hlr @@ -285,6 +360,10 @@ master-osmo-hnodeb, master-osmo-hnbgw + - osmo-ir77: + repos_url: '{gitea_url}/satellite/{repos}' + email: jenkins-notifications@lists.osmocom.org 246tnt@gmail.com + - osmo-mgw: trigger: master-osmo-msc, master-osmo-bsc @@ -294,18 +373,18 @@ a2_name: WITH_MANUALS a2: !!python/tuple ["1", "0"] combination_filter: > - (IU == "--enable-iu" && WITH_MANUALS == "0") || - (IU == "--disable-iu" && WITH_MANUALS == "1") + (IU == "--enable-iu" && WITH_MANUALS == "1") || + (IU == "--disable-iu" && WITH_MANUALS == "0") cmd: | - {docker_run} \ + {docker_run_ccache} \ -e IU="$IU" \ -e WITH_MANUALS="$WITH_MANUALS" \ - {docker_img} /build/contrib/jenkins.sh + {docker_img} {timeout_cmd} /build/contrib/jenkins.sh - osmo-pcap - osmo-pcu: - slave_axis: !!python/tuple [osmocom-master-debian9, rpi4-raspbian11] + slave_axis: !!python/tuple [osmocom-master, rpi4-raspbian11] a1_name: FIRMWARE_VERSION a1: !!python/tuple [master, v2017.01, origin/nrw/litecell15] a2_name: with_vty @@ -315,19 +394,26 @@ a4_name: WITH_MANUALS a4: !!python/tuple ["1", "0"] combination_filter: > - (with_vty == "True" && with_dsp == "sysmo" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="v2017.01" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="origin/nrw/litecell15" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || - (with_vty == "False" && with_dsp == "none" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "1" && label == "osmocom-master-debian9") || + (with_vty == "True" && with_dsp == "sysmo" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "osmocom-master") || + (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "osmocom-master") || + (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="v2017.01" && WITH_MANUALS == "0" && label == "osmocom-master") || + (with_vty == "True" && with_dsp == "lc15" && FIRMWARE_VERSION=="origin/nrw/litecell15" && WITH_MANUALS == "0" && label == "osmocom-master") || + (with_vty == "False" && with_dsp == "none" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "1" && label == "osmocom-master") || (with_vty == "False" && with_dsp == "none" && FIRMWARE_VERSION=="master" && WITH_MANUALS == "0" && label == "rpi4-raspbian11") cmd: | - {docker_run} \ + DOCKER_IMG="{docker_img}" + case "$(arch)" in + arm*) DOCKER_IMG="$DOCKER_IMG-arm" ;; + esac + {docker_run_ccache} \ -e FIRMWARE_VERSION="$FIRMWARE_VERSION" \ -e with_vty="$with_vty" \ -e with_dsp="$with_dsp" \ -e WITH_MANUALS="$WITH_MANUALS" \ - {docker_img} /build/contrib/jenkins.sh + "$DOCKER_IMG" {timeout_cmd} /build/contrib/jenkins.sh + + - osmo-python-tests: + repos_url: '{gerrit_url}/python/{repos}' - osmo-sgsn: a1_name: IU @@ -335,13 +421,13 @@ a2_name: WITH_MANUALS a2: !!python/tuple ["1", "0"] combination_filter: > - (IU == "--enable-iu" && WITH_MANUALS == "0") || - (IU == "--disable-iu" && WITH_MANUALS == "1") + (IU == "--enable-iu" && WITH_MANUALS == "1") || + (IU == "--disable-iu" && WITH_MANUALS == "0") cmd: | - {docker_run} \ + {docker_run_ccache} \ -e IU="$IU" \ -e WITH_MANUALS="$WITH_MANUALS" \ - {docker_img} /build/contrib/jenkins.sh + {docker_img} {timeout_cmd} /build/contrib/jenkins.sh - osmo-sip-connector: email: jenkins-notifications@lists.osmocom.org laforge@gnumonks.org holger@freyther.de @@ -350,39 +436,57 @@ email: jenkins-notifications@lists.osmocom.org laforge@gnumonks.org 246tnt@gmail.com - osmo-trx: - slave_axis: !!python/tuple [osmocom-master-debian9,rpi4-raspbian11] + slave_axis: !!python/tuple [osmocom-master,rpi4-raspbian11] a1_name: INSTR a1: !!python/tuple [--with-sse, --without-sse, --with-neon, --with-neon-vfpv4] a2_name: WITH_MANUALS a2: !!python/tuple ["1", "0"] combination_filter: > - (INSTR == "--without-sse" && WITH_MANUALS == "1" && label == "osmocom-master-debian9") || - (INSTR == "--with-sse" && WITH_MANUALS == "0" && label == "osmocom-master-debian9") || + (INSTR == "--without-sse" && WITH_MANUALS == "1" && label == "osmocom-master") || + (INSTR == "--with-sse" && WITH_MANUALS == "0" && label == "osmocom-master") || (INSTR == "--with-neon" && WITH_MANUALS == "0" && label == "rpi4-raspbian11") || (INSTR == "--with-neon-vfpv4" && WITH_MANUALS == "0" && label == "rpi4-raspbian11") cmd: | - {docker_run} \ + DOCKER_IMG="{docker_img}" + case "$(arch)" in + arm*) DOCKER_IMG="$DOCKER_IMG-arm" ;; + esac + {docker_run_ccache} \ -e INSTR="$INSTR" \ -e WITH_MANUALS="$WITH_MANUALS" \ - {docker_img} /build/contrib/jenkins.sh + "$DOCKER_IMG" {timeout_cmd} /build/contrib/jenkins.sh - osmocom-bb - osmo-sysmon - osmo-remsim - osmo-asf4-dfu: - cmd: '{docker_run} {docker_img} /build/contrib/jenkins.sh --publish' + cmd: '{docker_run_ccache} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh --publish' email: jenkins-notifications@lists.osmocom.org laforge@gnumonks.org ewild@sysmocom.de + ssh: + - binaries_ftp.osmocom.org + - docs_ftp.osmocom.org - osmo-ccid-firmware: - cmd: '{docker_run} {docker_img} /build/contrib/jenkins.sh --publish' + cmd: '{docker_run_ccache} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh --publish' email: jenkins-notifications@lists.osmocom.org laforge@gnumonks.org ewild@sysmocom.de + ssh: + - binaries_ftp.osmocom.org + - docs_ftp.osmocom.org + - simtrace: + repos_url: '{gitea_url}/sim-card/{repos}' + email: jenkins-notifications@lists.osmocom.org laforge@gnumonks.org kredon@sysmocom.de - simtrace2: - cmd: '{docker_run} {docker_img} /build/contrib/jenkins.sh --publish' + cmd: '{docker_run_ccache} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh --publish' email: jenkins-notifications@lists.osmocom.org laforge@gnumonks.org kredon@sysmocom.de + ssh: + - binaries_ftp.osmocom.org + - docs_ftp.osmocom.org - osmo-opencm3-projects: - git_base_url: https://gitea.osmocom.org/electronics - docker_img: '$USER/debian-bullseye-jenkins' - cmd: '{docker_run} {docker_img} /build/contrib/jenkins.sh --publish' + repos_url: '{gitea_url}/electronics/{repos}' + cmd: '{docker_run} {docker_img} {timeout_cmd} /build/contrib/jenkins.sh --publish' email: jenkins-notifications@lists.osmocom.org laforge@gnumonks.org kredon@sysmocom.de + ssh: + - binaries_ftp.osmocom.org + - docs_ftp.osmocom.org - osmo-e1d - osmo-cbc @@ -393,25 +497,65 @@ - osmo-smlc - osmo-gbproxy - osmo-hnodeb - - osmo-hnbgw + + - osmo-hnbgw: + a1_name: PFCP + a1: !!python/tuple ["1", "0"] + a2_name: WITH_MANUALS + a2: !!python/tuple ["1", "0"] + a3_name: NFTABLES + a3: !!python/tuple ["1", "0"] + combination_filter: > + (PFCP == "1" && WITH_MANUALS == "1" && NFTABLES == "1") || + (PFCP == "0" && WITH_MANUALS == "0" && NFTABLES == "0") + cmd: | + {docker_run_ccache} \ + -e PFCP="$PFCP" \ + -e WITH_MANUALS="$WITH_MANUALS" \ + -e NFTABLES="$NFTABLES" \ + {docker_img} {timeout_cmd} /build/contrib/jenkins.sh - rtl-sdr: - git_base_url: https://gitea.osmocom.org/sdr + repos_url: '{gitea_url}/sdr/{repos}' email: laforge@gnumonks.org steve@steve-m.de - pysim: concurrent: false - slave_axis: !!python/tuple [simtester] - cmd: 'PUBLISH=1 WITH_MANUALS=1 /usr/bin/timeout 30m ./contrib/jenkins.sh' + slave_axis: !!python/tuple [simtester,osmocom-master] + a2_name: JOB_TYPE + a2: !!python/tuple ["test", "pylint", "docs"] + combination_filter: > + (JOB_TYPE == "test" && label == "simtester") || + (JOB_TYPE == "pylint" && label == "osmocom-master") || + (JOB_TYPE == "docs" && label == "osmocom-master") + cmd: | + case "$JOB_TYPE" in + "test") + {timeout_cmd} ./contrib/jenkins.sh + ;; + *) + {docker_run} \ + -e JOB_TYPE="$JOB_TYPE" \ + {docker_img} \ + {timeout_cmd} /build/contrib/jenkins.sh + ;; + esac - sysmo-usim-tool: concurrent: false - cmd: cd ./tests; ./run-tests + cmd: cd ./tests; {timeout_cmd} ./run-tests slave_axis: !!python/tuple [simtester] - git_base_url: https://gitea.sysmocom.de/sysmocom + repos_url: 'https://gitea.sysmocom.de/sysmocom/{repos}' - dahdi-tools + - xgoldmon: + repos_url: 'https://github.com/2b-as/{repos}' + cmd: | + rm -rf osmo-ci + git clone --depth=1 https://gerrit.osmocom.org/osmo-ci -b master + {docker_run_ccache} {docker_img} {timeout_cmd} /build/osmo-ci/scripts/xgoldmon-jenkins.sh + jobs: - 'master-{repos}' @@ -425,11 +569,9 @@ - build-discarder: days-to-keep: 30 num-to-keep: 120 - artifact-days-to-keep: -1 - artifact-num-to-keep: -1 description: | Automatic jenkins test job of - <a href="{git_base_url}/{repos}">{repos}</a> + <a href="{repos_url}">{repos}</a> <br/><br/> <b>Auto-generated using Jenkins Job Builder. DO NOT EDIT MANUALLY!</b> @@ -437,7 +579,6 @@ sequential: '{obj:sequential}' combination-filter: | {obj:combination_filter} - node: '{obj:node}' axes: - axis: type: slave @@ -462,9 +603,8 @@ scm: - git: - url: "{git_base_url}/{repos}" - branches: - - 'origin/master' + url: '{obj:repos_url}' + branches: '{obj:branches}' refspec: name: wipe-workspace: false @@ -484,16 +624,20 @@ publishers: - archive: allow-empty: true - artifacts: '**/core, **/testsuite.log' + artifacts: '**/core, **/testsuite.log, **/workspace.tar.xz' - warnings: console-log-parsers: - 'GNU C Compiler 4 (gcc)' resolve-relative-paths: true - trigger: project: '{obj:trigger}' + - trigger: + project: 'Osmocom_OBS_master' - email: recipients: '{obj:email}' send-to-individuals: true - wrappers: '{obj:wrappers}' + wrappers: + - ssh-agent-credentials: + users: '{obj:ssh}' # vim: expandtab tabstop=2 shiftwidth=2 diff --git a/jobs/octsim_osmo-ccid-firmware.yml b/jobs/octsim_osmo-ccid-firmware.yml index 17e3cef..7db1039 100644 --- a/jobs/octsim_osmo-ccid-firmware.yml +++ b/jobs/octsim_osmo-ccid-firmware.yml @@ -35,8 +35,6 @@ queue-scanning: DISABLED use-build-blocker: false - build-discarder: - artifact-days-to-keep: -1 - artifact-num-to-keep: -1 days-to-keep: 30 num-to-keep: 120 - rebuild: @@ -51,5 +49,5 @@ triggers: - reverse: jobs: master-osmo-ccid-firmware, - - timed: H H * * * + - timed: H 22 * * * wrappers: [] diff --git a/jobs/osmo-gsm-manuals-trigger.yml b/jobs/osmo-gsm-manuals-trigger.yml index bbb883f..29882e3 100644 --- a/jobs/osmo-gsm-manuals-trigger.yml +++ b/jobs/osmo-gsm-manuals-trigger.yml @@ -15,7 +15,10 @@ Roll out osmo-gsm-manuals to relevant build environments.<br> <br> Related: <a href="https://osmocom.org/issues/4912">OS#4912</a> - node: osmocom-master-debian9 + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 scm: - git: url: https://gerrit.osmocom.org/osmo-gsm-manuals diff --git a/jobs/osmo-gsm-tester-runner.yml b/jobs/osmo-gsm-tester-runner.yml index 73a49db..4909fe7 100644 --- a/jobs/osmo-gsm-tester-runner.yml +++ b/jobs/osmo-gsm-tester-runner.yml @@ -32,7 +32,7 @@ name: osmo-gsm-tester-repo scm: - git: - url: https://gitea.osmocom.org/cellular-infrastructure/osmo-gsm-tester + url: https://gerrit.osmocom.org/osmo-gsm-tester branches: - ${OSMO_GSM_TESTER_BRANCH} wipe-workspace: false @@ -111,6 +111,7 @@ - job-template: name: 'osmo-gsm-tester_run-{stage}' + disabled: true defaults: runner node: 'osmo-gsm-tester-{stage}' triggers: @@ -171,8 +172,8 @@ branch-pattern: '**' builders: - shell: | - # make sure no bin artifacts from a previous run remain - rm -f *.tgz *.md5 + # make sure no test results/bin artifacts from a previous run remain + rm -rf trial-* *.tgz *.md5 - copy_artifact_all - shell: !include-raw: osmo-gsm-tester_run-gerrit.sh publishers: @@ -186,6 +187,7 @@ # ttcn3 job - job: name: 'osmo-gsm-tester_ttcn3' + disabled: true defaults: runner scm: - 'osmo-gsm-tester-repo' @@ -193,8 +195,8 @@ - timed: "H 23 * * *" builders: - shell: | - # make sure no bin artifacts from a previous run remain - rm -f *.tgz *.md5 + # make sure no test results/bin artifacts from a previous run remain + rm -rf trial-* *.tgz *.md5 - copy_artifact_all - copy_artifact: repo: osmo-gsm-tester_build-osmocom-bb @@ -211,7 +213,7 @@ - job: name: 'osmo-gsm-tester_virtual' defaults: runner - node: 'osmocom-master-debian9' + node: 'osmocom-master' scm: - 'osmo-gsm-tester-repo' triggers: @@ -219,11 +221,46 @@ builders: - shell: | # make sure no bin artifacts from a previous run remain - rm -f *.tgz *.md5 + rm -rf *.tgz *.md5 - copy_artifact_all - copy_artifact: repo: osmo-gsm-tester_build-osmocom-bb - - shell: > + - shell: | + # Set a trap to fix workspace permissions / kill the docker container on exit + clean_up() { + docker kill "osmo-gsm-tester-virtual" || true + docker run --rm \ + -v "$WORKSPACE":/workspace \ + debian:bullseye \ + chmod -R a+rwX /workspace/ + } + clean_up_trap() { + set +x + echo + echo "### Clean up ###" + echo + set -x + + trap - EXIT INT TERM 0 + clean_up + } + trap clean_up_trap EXIT INT TERM 0 + + # Make sure no test results from a previous run remain + clean_up + rm -rf trial-* + + # Build the docker image + rm -rf docker-playground + git clone \ + --depth=1 \ + --branch="$DOCKER_PLAYGROUND_BRANCH" \ + https://gerrit.osmocom.org/docker-playground \ + docker-playground + git -C docker-playground log --oneline + make -C docker-playground/debian-buster-jenkins # OS#6126 + make -C docker-playground/osmo-gsm-tester + unlink osmo-gsm-tester/sysmocom/resources.conf || true ln -s resources.conf.virtual osmo-gsm-tester/sysmocom/resources.conf @@ -241,6 +278,7 @@ -w /build -i \ -v "$PWD:/build" \ -v "$HOME/.ssh:/home/build/.ssh:ro" \ + --name=osmo-gsm-tester-virtual \ --cap-add=sys_nice \ $USER/osmo-gsm-tester \ /bin/bash -c 'LANG="en_US.utf8" LC_ALL="en_US.UTF-8" LC_LANG="en_US.UTF-8" PATH="$PWD/osmo-gsm-tester/src:${PATH}" ./osmo-gsm-tester/contrib/jenkins-run.sh' @@ -251,12 +289,19 @@ - junit: results: 'trial-*/last_run/trial-*.xml' allow-empty-results: true + - email: + notify-every-unstable-build: true + recipients: jenkins-notifications@lists.osmocom.org parameters: - string: name: "OSMO_GSM_TESTER_OPTS" default: "-s netreg_mass" - description: "pass additional command line options to osmo-gsm-tester.py, e.g. to select specific suites:scenarios. Default: leave empty." + description: "pass additional command line options to osmo-gsm-tester.py, e.g. to select specific suites:scenarios" - string: name: "OSMO_GSM_TESTER_BRANCH" - default: "origin/master" + default: "master" description: "Which branch/sha should be used for testing" + - string: + name: "DOCKER_PLAYGROUND_BRANCH" + default: "master" + description: "Which branch/sha should be used for building the osmo-gsm-tester docker container" diff --git a/jobs/osmo-gsm-tester-trigger.yml b/jobs/osmo-gsm-tester-trigger.yml index 07edcf4..216dabc 100644 --- a/jobs/osmo-gsm-tester-trigger.yml +++ b/jobs/osmo-gsm-tester-trigger.yml @@ -8,6 +8,10 @@ - job: name: 'osmo-gsm-tester_build-trigger-all' description: 'Manually kick off all osmo-gsm-tester_build-osmo-* builds at once.' + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 project-type: freestyle node: osmo-gsm-tester-build publishers: diff --git a/jobs/osmocom-api.yml b/jobs/osmocom-api.yml new file mode 100644 index 0000000..312496b --- /dev/null +++ b/jobs/osmocom-api.yml @@ -0,0 +1,46 @@ +- job: + concurrent: false + description: This job builds the doxygen API documentation for latest libosmo* + and uploads it to <a href="https://downloads.osmocom.org/api/latest/" + >https://downloads.osmocom.org/api/latest/</a> + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + name: Osmocom_API + node: osmocom-master + project-type: freestyle + publishers: + - email: + notify-every-unstable-build: true + recipients: jenkins-notifications@lists.osmocom.org + triggers: + - timed: "H 00 * * *" + wrappers: + - ssh-agent-credentials: + users: + - api_ftp.osmocom.org + parameters: + - string: + name: BRANCH + description: osmo-ci.git branch + default: 'master' + scm: + - git: + branches: + - '$BRANCH' + url: https://gerrit.osmocom.org/osmo-ci + git-config-name: 'Jenkins Builder' + git-config-email: 'jenkins@osmocom.org' + wipe-workspace: true + builders: + - shell: | + docker run \ + --rm=true \ + -e SSH_AUTH_SOCK=/ssh-agent \ + -u build \ + -v "$PWD:/build" \ + -v $(readlink -f $SSH_AUTH_SOCK):/ssh-agent \ + -w /build \ + "$USER/debian-bookworm-build" \ + scripts/osmocom-api-doxygen.sh diff --git a/jobs/osmocom-build-tags-against-master.yml b/jobs/osmocom-build-tags-against-master.yml index 22ac9ae..e33c9a3 100644 --- a/jobs/osmocom-build-tags-against-master.yml +++ b/jobs/osmocom-build-tags-against-master.yml @@ -11,7 +11,11 @@ description: | Build old releases of programs/libraries against "master of the day" libosmo* (<a href="https://osmocom.org/issues/3765">OS#3765</a>) - node: osmocom-master-debian9 + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: osmocom-master parameters: - string: name: BRANCH @@ -20,16 +24,23 @@ default: '*/master' builders: - shell: | - PARALLEL_MAKE=-j8 scripts/osmocom-build-old-tags-against-master.sh + docker run \ + --rm=true \ + -e PARALLEL_MAKE="-j8" \ + -u build \ + -v "$PWD:/build" \ + -w /build \ + "$USER/debian-bookworm-build" \ + scripts/osmocom-build-old-tags-against-master.sh scm: - git: branches: - '$BRANCH' - url: https://git.osmocom.org/osmo-ci + url: https://gerrit.osmocom.org/osmo-ci git-config-name: 'Jenkins Builder' git-config-email: 'jenkins@osmocom.org' triggers: - - timed: "@midnight" + - timed: "H 01 * * *" publishers: - archive: allow-empty: false diff --git a/jobs/osmocom-depcheck.yml b/jobs/osmocom-depcheck.yml index 1eadd0e..5e20f95 100644 --- a/jobs/osmocom-depcheck.yml +++ b/jobs/osmocom-depcheck.yml @@ -12,7 +12,11 @@ Verifies that Osmocom programs really build with the dependency versions they claim to support in configure.ac. (Generated by job-builder) - node: osmocom-master-debian9 + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: osmocom-master parameters: - string: name: PROJECTS @@ -26,7 +30,7 @@ name: GIT_URL_PREFIX description: | Where to clone the sources from - default: 'https://git.osmocom.org/' + default: 'https://gerrit.osmocom.org/' - bool: name: BUILD description: | @@ -65,7 +69,7 @@ - git: branches: - '$BRANCH' - url: https://git.osmocom.org/osmo-ci + url: https://gerrit.osmocom.org/osmo-ci git-config-name: 'Jenkins Builder' git-config-email: 'jenkins@osmocom.org' diff --git a/jobs/osmocom-list-commits.yml b/jobs/osmocom-list-commits.yml index c9995c6..d367499 100644 --- a/jobs/osmocom-list-commits.yml +++ b/jobs/osmocom-list-commits.yml @@ -11,7 +11,11 @@ description: | Generate and upload a list of Osmocom git repositories and their latest tag and commits. <b>The latest list is <a href="https://jenkins.osmocom.org/jenkins/job/Osmocom-list-commits/lastSuccessfulBuild/artifact/commits.txt/*view*/">here</a>.</b> - node: osmocom-master-debian9 + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: osmocom-master parameters: - string: name: BRANCH @@ -26,11 +30,11 @@ - git: branches: - '$BRANCH' - url: https://git.osmocom.org/osmo-ci + url: https://gerrit.osmocom.org/osmo-ci git-config-name: 'Jenkins Builder' git-config-email: 'jenkins@osmocom.org' triggers: - - timed: "@midnight" + - timed: "H 01 * * *" publishers: - archive: allow-empty: false diff --git a/jobs/osmocom-obs-check-builders.yml b/jobs/osmocom-obs-check-builders.yml new file mode 100644 index 0000000..01fdba5 --- /dev/null +++ b/jobs/osmocom-obs-check-builders.yml @@ -0,0 +1,32 @@ +--- +- project: + name: Osmocom_OBS_check_builders + jobs: + - Osmocom_OBS_check_builders + +- job-template: + name: 'Osmocom_OBS_check_builders' + project-type: freestyle + defaults: global + description: | + Verify that the expected amount of builders are connected to + obs.osmocom.org. + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + builders: + - shell: | + scripts/obs/check_builders.sh + scm: + - git: + branches: + - 'origin/master' + url: https://gerrit.osmocom.org/osmo-ci + triggers: + - timed: "@hourly" + node: obs + publishers: + - email: + notify-every-unstable-build: true + recipients: 'jenkins-notifications@lists.osmocom.org' diff --git a/jobs/osmocom-obs-check-new-distros.yml b/jobs/osmocom-obs-check-new-distros.yml new file mode 100644 index 0000000..760479a --- /dev/null +++ b/jobs/osmocom-obs-check-new-distros.yml @@ -0,0 +1,39 @@ +--- +- job: + name: 'Osmocom_OBS_check_new_distros' + project-type: freestyle + concurrent: false + defaults: global + description: | + Check whether new distributions (Debian, Raspyberry Pi OS, Ubuntu) are + available in openSUSE's OBS that we need to add to the Osmocom OBS. + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: obs + parameters: + - string: + name: CI_BRANCH + description: osmo-ci.git branch + default: 'master' + scm: + - git: + branches: + - '$CI_BRANCH' + url: https://gerrit.osmocom.org/osmo-ci + git-config-name: 'Jenkins Builder' + git-config-email: 'jenkins@osmocom.org' + builders: + - shell: | + export PYTHONUNBUFFERED=1 + ./scripts/obs/check_new_distros.py --docker + triggers: + - timed: "H 19 * * *" + wrappers: + - ansicolor: + colormap: xterm + publishers: + - email: + notify-every-unstable-build: true + recipients: 'jenkins-notifications@lists.osmocom.org' diff --git a/jobs/osmocom-obs-ewild.yml b/jobs/osmocom-obs-ewild.yml new file mode 100644 index 0000000..111ec09 --- /dev/null +++ b/jobs/osmocom-obs-ewild.yml @@ -0,0 +1,72 @@ +--- +- project: + name: Osmocom_OBS_ewild + jobs: + - Osmocom_OBS_ewild_{branch_suffix} + branch_suffix: + - mssdr + +- job-template: + name: 'Osmocom_OBS_ewild_{branch_suffix}' + project-type: freestyle + concurrent: false + defaults: global + description: | + Iterate over Osmocom projects, and update projects from the + "Hoernchen/{branch_suffix}" branch in OBS. If a package exists in OBS + for a project, but it doesn't have the git branch anymore then delete the + package from OBS. + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: obs + parameters: + - string: + name: CI_BRANCH + description: osmo-ci.git branch + default: 'master' + builders: + - shell: | + export PYTHONUNBUFFERED=1 + BRANCH="Hoernchen/{branch_suffix}" + PROJ="home:ewild:{branch_suffix}" + VERSION_APPEND="~ewild.{branch_suffix}" + PACKAGE="$GERRIT_PROJECT" + + # When manually triggered, run on all Osmocom packages + if [ -z "$PACKAGE" ]; then + PACKAGE="ALL_OSMOCOM_PACKAGES" + fi + + ./scripts/obs/update_obs_project.py \ + --apiurl https://obs.osmocom.org \ + --conflict-pkgname "osmocom-nightly" \ + --delete \ + --docker \ + --feed "master" \ + --git-branch "$BRANCH" \ + --version-append "$VERSION_APPEND" \ + "$PROJ" \ + "$PACKAGE" + scm: + - git: + branches: + - '$CI_BRANCH' + url: https://gerrit.osmocom.org/osmo-ci + git-config-name: 'Jenkins Builder' + git-config-email: 'jenkins@osmocom.org' + triggers: + - gerrit: + trigger-on: + - ref-updated-event + projects: + - project-compare-type: 'ANT' + project-pattern: '**' + branches: + - branch-pattern: 'Hoernchen/{branch_suffix}' + server-name: gerrit.osmocom.org + publishers: + - email: + notify-every-unstable-build: true + recipients: 'ewild@sysmocom.de' diff --git a/jobs/osmocom-obs-nhofmeyr.yml b/jobs/osmocom-obs-nhofmeyr.yml new file mode 100644 index 0000000..427dcd2 --- /dev/null +++ b/jobs/osmocom-obs-nhofmeyr.yml @@ -0,0 +1,73 @@ +--- +- project: + name: Osmocom_OBS_nhofmeyr + jobs: + - Osmocom_OBS_nhofmeyr_{branch_suffix} + branch_suffix: + - dev + +- job-template: + name: 'Osmocom_OBS_nhofmeyr_{branch_suffix}' + project-type: freestyle + concurrent: false + defaults: global + description: | + Iterate over Osmocom projects, and update projects from the + "neels/{branch_suffix}" branch in OBS. If a package exists in OBS + for a project, but it doesn't have the git branch anymore then delete the + package from OBS. (created from osmo-ci.git/jobs/osmocom-obs-nhofmeyr.yml + which was originally a copy of osmocom-obs-rhizomatica.yml) + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: obs + parameters: + - string: + name: CI_BRANCH + description: osmo-ci.git branch + default: 'master' + builders: + - shell: | + export PYTHONUNBUFFERED=1 + BRANCH="neels/{branch_suffix}" + PROJ="home:nhofmeyr:{branch_suffix}" + VERSION_APPEND="~nhofmeyr.{branch_suffix}" + PACKAGE="$GERRIT_PROJECT" + + # When manually triggered, run on all Osmocom packages + if [ -z "$PACKAGE" ]; then + PACKAGE="ALL_OSMOCOM_PACKAGES" + fi + + ./scripts/obs/update_obs_project.py \ + --apiurl https://obs.osmocom.org \ + --conflict-pkgname "osmocom-latest" \ + --delete \ + --docker \ + --feed "master" \ + --git-branch "$BRANCH" \ + --version-append "$VERSION_APPEND" \ + "$PROJ" \ + "$PACKAGE" + scm: + - git: + branches: + - '$CI_BRANCH' + url: https://gerrit.osmocom.org/osmo-ci + git-config-name: 'Jenkins Builder' + git-config-email: 'jenkins@osmocom.org' + triggers: + - gerrit: + trigger-on: + - ref-updated-event + projects: + - project-compare-type: 'ANT' + project-pattern: '**' + branches: + - branch-pattern: 'neels/{branch_suffix}' + server-name: gerrit.osmocom.org + publishers: + - email: + notify-every-unstable-build: true + recipients: 'nhofmeyr@sysmocom.de' diff --git a/jobs/osmocom-obs-rhizomatica.yml b/jobs/osmocom-obs-rhizomatica.yml new file mode 100644 index 0000000..92ab465 --- /dev/null +++ b/jobs/osmocom-obs-rhizomatica.yml @@ -0,0 +1,73 @@ +--- +- project: + name: Osmocom_OBS_rhizomatica + jobs: + - Osmocom_OBS_rhizomatica_{branch_suffix} + branch_suffix: + - testing + - production + +- job-template: + name: 'Osmocom_OBS_rhizomatica_{branch_suffix}' + project-type: freestyle + concurrent: false + defaults: global + description: | + Iterate over Osmocom projects, and update projects from the + "rhizomatica/{branch_suffix}" branch in OBS. If a package exists in OBS + for a project, but it doesn't have the git branch anymore then delete the + package from OBS (<a href="https://osmocom.org/issues/5981">OS#5981</a>). + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: obs + parameters: + - string: + name: CI_BRANCH + description: osmo-ci.git branch + default: 'master' + builders: + - shell: | + export PYTHONUNBUFFERED=1 + BRANCH="rhizomatica/{branch_suffix}" + PROJ="rhizomatica:{branch_suffix}" + VERSION_APPEND="~rhizomatica.{branch_suffix}" + PACKAGE="$GERRIT_PROJECT" + + # When manually triggered, run on all Osmocom packages + if [ -z "$PACKAGE" ]; then + PACKAGE="ALL_OSMOCOM_PACKAGES" + fi + + ./scripts/obs/update_obs_project.py \ + --apiurl https://obs.osmocom.org \ + --conflict-pkgname "osmocom-latest" \ + --delete \ + --docker \ + --feed "master" \ + --git-branch "$BRANCH" \ + --version-append "$VERSION_APPEND" \ + "$PROJ" \ + "$PACKAGE" + scm: + - git: + branches: + - '$CI_BRANCH' + url: https://gerrit.osmocom.org/osmo-ci + git-config-name: 'Jenkins Builder' + git-config-email: 'jenkins@osmocom.org' + triggers: + - gerrit: + trigger-on: + - ref-updated-event + projects: + - project-compare-type: 'ANT' + project-pattern: '**' + branches: + - branch-pattern: 'rhizomatica/{branch_suffix}' + server-name: gerrit.osmocom.org + publishers: + - email: + notify-every-unstable-build: true + recipients: 'jenkins-notifications@lists.osmocom.org' diff --git a/jobs/osmocom-obs-sync.yml b/jobs/osmocom-obs-sync.yml new file mode 100644 index 0000000..3776688 --- /dev/null +++ b/jobs/osmocom-obs-sync.yml @@ -0,0 +1,53 @@ +--- +- job: + name: 'Osmocom_OBS_sync' + project-type: freestyle + concurrent: false + defaults: global + description: | + Sync base distributions (Debian:12 etc.) from openSUSE's OBS to our OBS + (<a href="https://osmocom.org/issues/6165">OS#6165</a>). + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: obs + parameters: + - string: + name: CI_BRANCH + description: osmo-ci.git branch + default: 'master' + scm: + - git: + branches: + - '$CI_BRANCH' + url: https://gerrit.osmocom.org/osmo-ci + git-config-name: 'Jenkins Builder' + git-config-email: 'jenkins@osmocom.org' + builders: + - shell: | + export PYTHONUNBUFFERED=1 + export DISTROS=" + Debian:10 + Debian:11 + Debian:12 + Debian:Next + Raspbian:10 + Raspbian:11 + Raspbian:12 + Ubuntu:22.04 + Ubuntu:23.10 + Ubuntu:24.04 + " + ./scripts/obs/sync_obs_projects.py \ + --docker \ + $DISTROS + triggers: + - timed: "H 18 * * *" + wrappers: + - ansicolor: + colormap: xterm + publishers: + - email: + notify-every-unstable-build: true + recipients: 'jenkins-notifications@lists.osmocom.org' diff --git a/jobs/osmocom-obs-wireshark.yml b/jobs/osmocom-obs-wireshark.yml new file mode 100644 index 0000000..213a1f3 --- /dev/null +++ b/jobs/osmocom-obs-wireshark.yml @@ -0,0 +1,42 @@ +--- +- project: + name: Osmocom_OBS + jobs: + - Osmocom_OBS_wireshark + +- job: + name: 'Osmocom_OBS_wireshark' + project-type: freestyle + defaults: global + description: | + See <a href="https://osmocom.org/issues/2537">OS#2537</a> + for more information. + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: obs + parameters: + - string: + name: BRANCH + description: osmo-ci.git branch + default: 'master' + builders: + - shell: | + export PYTHONUNBUFFERED=1 + ./scripts/obs/update_obs_wireshark.sh osmocom:wireshark + scm: + - git: + branches: + - '$BRANCH' + url: https://gerrit.osmocom.org/osmo-ci + git-config-name: 'Jenkins Builder' + git-config-email: 'jenkins@osmocom.org' + wipe-workspace: true + triggers: + - timed: "H 19 * * *" + + publishers: + - email: + notify-every-unstable-build: true + recipients: 'jenkins-notifications@lists.osmocom.org' diff --git a/jobs/osmocom-obs.yml b/jobs/osmocom-obs.yml index 06b4ecb..eb77f4d 100644 --- a/jobs/osmocom-obs.yml +++ b/jobs/osmocom-obs.yml @@ -2,27 +2,29 @@ - project: name: Osmocom_OBS jobs: - - Osmocom_OBS_{type}_{server} + - Osmocom_OBS_{type} type: + - master: + conflict_version: "" - nightly: # For nightly we don't provide ABI compatibility, make sure packages # from different build dates are not mixed by accident conflict_version: "$(date +%Y%m%d%H%M)" - latest: conflict_version: "" - server: - - build.opensuse.org: - proj: "network:osmocom" - - obs.osmocom.org: - proj: "osmocom" - job-template: - name: 'Osmocom_OBS_{type}_{server}' + name: 'Osmocom_OBS_{type}' project-type: freestyle + concurrent: false defaults: global description: | See <a href="https://osmocom.org/projects/cellular-infrastructure/wiki/Binary_Packages">Wiki: binary packages</a> for more information. + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 node: obs parameters: - string: @@ -34,21 +36,21 @@ export PYTHONUNBUFFERED=1 ./scripts/obs/update_obs_project.py \ - --apiurl {server} \ + --apiurl https://obs.osmocom.org \ --conflict-version {conflict_version} \ --docker \ --feed {type} \ --meta \ - {proj}:{type} + osmocom:{type} scm: - git: branches: - '$BRANCH' - url: https://git.osmocom.org/osmo-ci + url: https://gerrit.osmocom.org/osmo-ci git-config-name: 'Jenkins Builder' git-config-email: 'jenkins@osmocom.org' triggers: - - timed: "H 00 * * *" # run before repo-install-test.yml + - timed: "H 20 * * *" publishers: - email: diff --git a/jobs/osmocom-release-manuals.yml b/jobs/osmocom-release-manuals.yml new file mode 100644 index 0000000..c9d04ae --- /dev/null +++ b/jobs/osmocom-release-manuals.yml @@ -0,0 +1,45 @@ +--- +- project: + name: Osmocom-release-manuals + jobs: + - Osmocom-release-manuals + +- job: + name: 'Osmocom-release-manuals' + node: osmocom-master + project-type: freestyle + defaults: global + description: | + Build manuals for all new Osmocom releases + (<a href="https://osmocom.org/issues/5902">OS#5902</a>). + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + parameters: + - string: + name: BRANCH_CI + description: | + osmo-ci.git branch + default: 'master' + builders: + - shell: | + scripts/manuals/publish-manuals-for-tags.sh + scm: + - git: + branches: + - '$BRANCH_CI' + url: https://gerrit.osmocom.org/osmo-ci + git-config-name: 'Jenkins Builder' + git-config-email: 'jenkins@osmocom.org' + wipe-workspace: true + triggers: + - timed: "H 04 * * *" + publishers: + - email: + notify-every-unstable-build: true + recipients: 'jenkins-notifications@lists.osmocom.org' + wrappers: + - ssh-agent-credentials: + users: + - docs_ftp.osmocom.org diff --git a/jobs/osmocom-release-tarballs.yml b/jobs/osmocom-release-tarballs.yml index 3d11bd3..4b3c8dc 100644 --- a/jobs/osmocom-release-tarballs.yml +++ b/jobs/osmocom-release-tarballs.yml @@ -6,35 +6,36 @@ - job-template: name: 'Osmocom-release-tarballs' + node: osmocom-master project-type: freestyle defaults: global description: | For each relevant Osmocom repository and its tags, build release tarballs (<a href="https://osmocom.org/issues/3870">OS#3870</a>). <br><br> Publishes to: <a href="https://ftp.osmocom.org/releases/">https://ftp.osmocom.org/releases</a> + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 parameters: - string: - name: BRANCH_DOCKER_PLAYGROUND + name: BRANCH_OSMO_CI description: | - docker-playground.git branch where the Dockerfile gets pulled from + osmo-ci.git branch with scripts/tarballs/publish-tarballs-for-tags.sh default: 'master' builders: - shell: | - cd release-tarball-build-dist - ./jenkins.sh + PUBLISH=1 scripts/tarballs/publish-tarballs-for-tags.sh scm: - git: branches: - - '$BRANCH_DOCKER_PLAYGROUND' - url: https://gitea.osmocom.org/osmocom/docker-playground + - '$BRANCH_OSMO_CI' + url: https://gerrit.osmocom.org/osmo-ci git-config-name: 'Jenkins Builder' git-config-email: 'jenkins@osmocom.org' - # Don't wipe workspace to keep generated release tarballs - wipe-workspace: false + wipe-workspace: true triggers: - - timed: "@midnight" - # Limit to one specific builder (so we don't regenerate all tarballs when switching to another builder) - node: build2-deb9build-ansible + - timed: "H 05 * * *" publishers: - email: notify-every-unstable-build: true @@ -42,6 +43,6 @@ wrappers: - ssh-agent-credentials: users: - - releases + - releases_ftp.osmocom.org # vim: expandtab tabstop=2 shiftwidth=2 diff --git a/jobs/registry-rebuild-upload-fpga-build.yml b/jobs/registry-rebuild-upload-fpga-build.yml index dceb2c5..1846e49 100644 --- a/jobs/registry-rebuild-upload-fpga-build.yml +++ b/jobs/registry-rebuild-upload-fpga-build.yml @@ -8,7 +8,11 @@ name: registry-rebuild-upload-fpga-build description: | Rebuild + push fpga-build docker images in our private registry.osmocom.org - node: osmocom-master-debian9 + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: osmocom-master scm: - git: url: https://gerrit.osmocom.org/docker-playground @@ -25,7 +29,7 @@ docker push $REGISTRY/$USER/fpga-build cd .. triggers: - - timed: "@weekly" + - timed: "H 02 * * H" publishers: - email: diff --git a/jobs/registry-rebuild-upload-titan.yml b/jobs/registry-rebuild-upload-titan.yml index a21a088..a535920 100644 --- a/jobs/registry-rebuild-upload-titan.yml +++ b/jobs/registry-rebuild-upload-titan.yml @@ -17,21 +17,25 @@ - job: name: registry-rebuild-upload-titan description: | - Rebuild + push ttcn3 base images (debian-bullseye-titan) in our private + Rebuild + push ttcn3 base images (debian-bookworm-titan) in our private registry.osmocom.org <br><br> Related:<br> <ul> <li> <a href="https://osmocom.org/issues/5017">OS#5017</a> </ul> - node: osmocom-master-debian9 + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: osmocom-master scm: - 'osmocom-docker-playground' builders: - shell: | REGISTRY="registry.osmocom.org" - make -C debian-bullseye-titan REGISTRY_HOST=$REGISTRY - docker push "$REGISTRY/$USER/debian-bullseye-titan" + make -C debian-bookworm-titan REGISTRY_HOST=$REGISTRY + docker push "$REGISTRY/$USER/debian-bookworm-titan" publishers: - email: notify-every-unstable-build: true @@ -48,7 +52,7 @@ <ul> <li>SYS#5765 </ul> - node: osmocom-master-debian9 + node: osmocom-master triggers: - reverse: jobs: diff --git a/jobs/registry-triggers.yml b/jobs/registry-triggers.yml index dcdde85..da7d402 100644 --- a/jobs/registry-triggers.yml +++ b/jobs/registry-triggers.yml @@ -12,7 +12,10 @@ name: 'registry-trigger-{repos}' description: | Update registry.osmocom.org after changes in {repos}. - node: osmocom-master-debian9 + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 scm: - git: url: https://gerrit.osmocom.org/{repos} @@ -24,7 +27,7 @@ - pollscm: cron: "H/5 * * * *" ignore-post-commit-hooks: false - - timed: "H H * * *" + - timed: "H 02 * * *" publishers: - trigger: project: '{obj:trigger}' diff --git a/jobs/registry-update-base-images.yml b/jobs/registry-update-base-images.yml index de5c448..b51ae95 100644 --- a/jobs/registry-update-base-images.yml +++ b/jobs/registry-update-base-images.yml @@ -12,17 +12,21 @@ <ul> <li> <a href="https://osmocom.org/issues/4839">OS#4839</a> </ul> - node: osmocom-master-debian9 + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 + node: osmocom-master builders: - shell: | REGISTRY="registry.osmocom.org" IMAGES=" debian:buster debian:bullseye + debian:bookworm debian:sid centos:centos7 - almalinux:8 " for i in $IMAGES; do src=$i @@ -34,7 +38,7 @@ docker push $dst done triggers: - - timed: "@daily" + - timed: "H 00 * * *" publishers: - email: diff --git a/jobs/repo-install-test.yml b/jobs/repo-install-test.yml index 5343f33..0891e24 100644 --- a/jobs/repo-install-test.yml +++ b/jobs/repo-install-test.yml @@ -4,12 +4,12 @@ jobs: - Osmocom-repo-install-{distro} distro: - - centos8: - feeds: !!python/tuple [nightly, latest] # next: disabled (OS#5322) - debian10: feeds: !!python/tuple [nightly, latest] - debian11: feeds: !!python/tuple [nightly, latest] + - debian12: + feeds: !!python/tuple [nightly, latest] - job-template: name: Osmocom-repo-install-{distro} @@ -25,31 +25,29 @@ <li> <a href="https://osmocom.org/issues/3176">OS#3176</a>: install all Osmocom debian packages <li> <a href="https://osmocom.org/issues/3369">OS#3369</a>: check if systemd services start properly <li> <a href="https://osmocom.org/issues/4563">OS#4563</a>: extend for centos + <li> <a href="https://osmocom.org/issues/5365">OS#5365</a>: run in qemu </ul> - node: osmocom-master-debian9 + properties: + - build-discarder: + days-to-keep: 30 + num-to-keep: 30 parameters: - string: name: BRANCH_CI description: | osmo-ci.git branch default: 'master' - - string: - name: BRANCH_DP - description: | - docker-playground.git branch - default: 'master' axes: - axis: type: slave name: label - values: !!python/tuple [repo-install-test] + values: !!python/tuple [qemu] - axis: type: user-defined name: feed values: '{obj:feeds}' builders: - shell: | - export OSMO_BRANCH_DOCKER_PLAYGROUND="$BRANCH_DP" export FEED="$feed" scripts/repo-install-test.sh "{distro}" scm: @@ -60,7 +58,7 @@ git-config-name: 'Jenkins Builder' git-config-email: 'jenkins@osmocom.org' triggers: - - timed: "H 10 * * *" # run after osmocom-obs.yml + - timed: "H 06 * * *" publishers: - email: diff --git a/jobs/ttcn3-testsuites-kernel-git.yml b/jobs/ttcn3-testsuites-kernel-git.yml index 9d644ec..6ce8fe8 100644 --- a/jobs/ttcn3-testsuites-kernel-git.yml +++ b/jobs/ttcn3-testsuites-kernel-git.yml @@ -8,13 +8,11 @@ disabled: false description: "" node: ttcn3 - blocking: "^{job-name}.*" wipe_workspace: false jobs: - "{job-name}" job-name: - ttcn3-ggsn-test-kernel-git: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" # Cache the linux source tree in the workspace of one node node: ttcn3-ggsn-test-kernel-git description: | @@ -61,7 +59,7 @@ description: | Version of the Osmocom stack to test against the kernel. Either <code>latest</code> for the latest release version, or - <code>master</code> for HEAD of git.osmocom.org. + <code>master</code> for HEAD of Osmocom git repositories. default: 'latest' - string: name: BRANCH @@ -105,8 +103,8 @@ results: '**/junit-xml-*.log' allow-empty-results: false - email: - notify-every-unstable-build: true - recipients: laforge@gnumonks.org osmith@sysmocom.de + notify-every-unstable-build: false + recipients: '{obj:email}' send-to-individuals: false - archive: allow-empty: false @@ -116,17 +114,12 @@ fingerprint: false only-if-success: false properties: - - build-blocker: - use-build-blocker: true - blocking-jobs: - - "{obj:blocking}" - build-discarder: days-to-keep: 30 num-to-keep: 120 - artifact-days-to-keep: -1 - artifact-num-to-keep: -1 wrappers: - ansicolor: colormap: xterm + email: jenkins-notifications@lists.osmocom.org # vim: expandtab tabstop=2 shiftwidth=2 diff --git a/jobs/ttcn3-testsuites.yml b/jobs/ttcn3-testsuites.yml index 9eef9f8..ac79f4d 100644 --- a/jobs/ttcn3-testsuites.yml +++ b/jobs/ttcn3-testsuites.yml @@ -5,7 +5,7 @@ disabled: false description: | Run the a testsuite from - <a href="https://git.osmocom.org/docker-playground/"> + <a href="https://gitea.osmocom.org/osmocom/docker-playground"> docker-playground.git</a>.<br> If this job ends in <code>-latest</code>, the job runs the latest stable versions of the Osmocom stack. Otherwise the nightly builds.<br> @@ -13,36 +13,39 @@ TTCN3 Testsuite</a> for more information. timer: "@midnight" node: ttcn3 - # Block *-latest for all master jobs (without suffix) - blocking: "^{job-name}.*" wipe_workspace: true jobs: - "{job-name}" # Folders from docker-playground.git + # timer: 10 per hour from 04:00 - 18:00, see jobs/README.adoc job-name: # debian nightly - order by time - nplab-m3ua-test: - blocking: "^(nplab|NPLAB-.*)-m3ua-test.*" - timer: 10 03 * * * + timer: H 04 * * * - nplab-sua-test: - blocking: "^(nplab|NPLAB-.*)-sua-test.*" - timer: 15 03 * * * + timer: H 04 * * * - ttcn3-ggsn-test: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 00 04 * * * + timer: H 04 * * * - ttcn3-ggsn-test-kernel: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 10 04 * * * + timer: H 04 * * * description: | Test osmo-ggsn master with the Debian kernel. + - ttcn3-ggsn-test-kernel-pablo-gtp: + timer: H 04 * * * + # Cache the linux source tree in the workspace of one node + wipe_workspace: false + description: | + Test osmo-ggsn master with the Linux kernel built from main of + <a href="https://git.kernel.org/pub/scm/linux/kernel/git/pablo/gtp.git/">pablo/gtp.git</a>. + <br> + This is a temporary job, to be removed once the IPv6 related GTP + patches are upstreamed (OS#1952). - ttcn3-ggsn-test-kernel-latest: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 20 04 * * * + timer: H 04 * * * description: | Test osmo-ggsn latest with the Debian kernel. - ttcn3-ggsn-test-kernel-latest-net-next: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 25 04 * * * + timer: H 04 * * * # Cache the linux source tree in the workspace of one node wipe_workspace: false node: ttcn3-ggsn-test-kernel-git @@ -51,8 +54,7 @@ <a href="https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next.git/"> net-next.git</a>. - ttcn3-ggsn-test-kernel-latest-torvalds: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 30 04 * * * + timer: H 04 * * * # Cache the linux source tree in the workspace of one node wipe_workspace: false node: ttcn3-ggsn-test-kernel-git @@ -61,324 +63,179 @@ <a href="https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/"> torvalds/linux.git</a>. - ttcn3-ggsn-test-ogs: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 35 04 * * * + timer: H 04 * * * description: | Test open5gs-smfd + open5gs-upfd main. + email: jenkins-notifications@lists.osmocom.org acetcom@gmail.com - ttcn3-msc-test: - blocking: "^(ttcn3|TTCN3-.*)-msc-test.*" - timer: 40 04 * * * + timer: H 04 * * * - ttcn3-pcu-test: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 00 05 * * * + timer: H 04 * * * - ttcn3-pcu-test-sns: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 15 05 * * * + timer: H 05 * * * - ttcn3-sgsn-test: - blocking: "^(ttcn3|TTCN3-.*)-sgsn-test.*" - timer: 30 05 * * * + timer: H 05 * * * + - ttcn3-sgsn-test-sns: + timer: H 05 * * * - ttcn3-bsc-test: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 00 06 * * * + timer: H 05 * * * - ttcn3-mgw-test: - blocking: "^(ttcn3|TTCN3-.*)-mgw-test.*" - timer: 30 06 * * * + timer: H 05 * * * - ttcn3-hlr-test: - blocking: "^(ttcn3|TTCN3-.*)-hlr-test.*" - timer: 45 06 * * * + timer: H 05 * * * - ttcn3-bts-test: - blocking: "^(ttcn3|TTCN3-.*)-bts-test.*" - timer: 00 07 * * * + timer: H 05 * * * - ttcn3-sip-test: - blocking: "^(ttcn3|TTCN3-.*)-sip-test.*" - timer: 30 07 * * * + timer: H 05 * * * - ttcn3-bscnat-test: - blocking: "^(ttcn3|TTCN3-.*)-bscnat-test.*" - timer: 00 08 * * * + timer: H 05 * * * disabled: true - ttcn3-bsc-test-sccplite: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 30 08 * * * + timer: H 05 * * * - ttcn3-remsim-test: - blocking: "^(ttcn3|TTCN3-.*)-remsim-test.*" - timer: 00 09 * * * + timer: H 05 * * * - ttcn3-stp-test: - blocking: "^(ttcn3|TTCN3-.*)-stp-test.*" - timer: 30 09 * * * + timer: H 06 * * * - ttcn3-sccp-test: - blocking: "^(ttcn3|TTCN3-.*)-sccp-test.*" - timer: 00 10 * * * + timer: H 06 * * * - ttcn3-smlc-test: - blocking: "^(ttcn3|TTCN3-.*)-smlc-test.*" - timer: 10 10 * * * + timer: H 06 * * * - ttcn3-gbproxy-test: - blocking: "^(ttcn3|TTCN3-.*)-gbproxy-test.*" - timer: 20 10 * * * + timer: H 06 * * * - ttcn3-gbproxy-test-fr: - blocking: "^(ttcn3|TTCN3-.*)-gbproxy-test-fr.*" - timer: 30 10 * * * + timer: H 06 * * * node: hdlc - ttcn3-cbc-test: - blocking: "^(ttcn3|TTCN3-.*)-cbc-test.*" - timer: 40 10 * * * + timer: H 06 * * * - ttcn3-ns-test: - blocking: "^(ttcn3|TTCN3-.*)-ns-test.*" - timer: 00 11 * * * + timer: H 06 * * * - ttcn3-ns-test-sns: - blocking: "^(ttcn3|TTCN3-.*)-ns-test-sns.*" - timer: 10 11 * * * + timer: H 06 * * * - ttcn3-ns-test-fr: - blocking: "^(ttcn3|TTCN3-.*)-ns-test-fr.*" - timer: 20 11 * * * + timer: H 06 * * * node: hdlc - ttcn3-ns-test-sgsn-sns: - blocking: "^(ttcn3|TTCN3-.*)-ns-test-sgsn-sns.*" - timer: 30 11 * * * + timer: H 06 * * * - ttcn3-pcap-client-test: - blocking: "^(ttcn3|TTCN3-.*)-pcap-client-test.*" - timer: 40 11 * * * + timer: H 07 * * * - ttcn3-bsc-test-vamos: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 00 12 * * * + timer: H 07 * * * - ttcn3-hnodeb-test: - blocking: "^(ttcn3|TTCN3-.*)-hnodeb-test.*" - timer: 40 12 * * * + timer: H 07 * * * - ttcn3-upf-test: - blocking: "^(ttcn3|TTCN3-.*)-upf-test.*" - timer: 00 13 * * * - disabled: true + timer: H 07 * * * - ttcn3-hnbgw-test: - blocking: "^(ttcn3|TTCN3-.*)-hnbgw-test.*" - timer: 40 13 * * * - - ttcn3-hnbgw-test-pfcp: - blocking: "^(ttcn3|TTCN3-.*)-hnbgw-test.*" - timer: 40 15 * * * + timer: H 07 * * * - ttcn3-fr-test: - blocking: "^(ttcn3|TTCN3-.*)-fr-test.*" - timer: 40 10 * * * + timer: H 07 * * * node: hdlc - ttcn3-pgw-test: - blocking: "^(ttcn3|TTCN3-.*)-pgw-test.*" - timer: 00 14 * * * + timer: H 07 * * * description: | Test open5gs-smfd + open5gs-upfd PGW main. + email: jenkins-notifications@lists.osmocom.org acetcom@gmail.com + - ttcn3-mme-test-ogs: + timer: H 07 * * * + description: | + Test open5gs-mmed + email: jenkins-notifications@lists.osmocom.org acetcom@gmail.com + - ttcn3-hss-test-ogs: + timer: H 07 * * * + description: | + Test open5gs-hssd + email: jenkins-notifications@lists.osmocom.org acetcom@gmail.com + - ttcn3-dia2gsup-test: + timer: H 07 * * * + - ttcn3-epdg-test: + timer: H 07 * * * + # osmo-epdg requires OTP and kernel >= debian12: + node: build4-deb12build-ansible + - ttcn3-asterisk-ims-ue-test: + timer: H 07 * * * # debian latest stable - nplab-m3ua-test-latest: - blocking: "^(nplab|NPLAB-.*)-m3ua-test.*" - timer: 10 03 * * * + timer: H 07 * * * - nplab-sua-test-latest: - blocking: "^(nplab|NPLAB-.*)-sua-test.*" - timer: 15 03 * * * + timer: H 08 * * * - ttcn3-ggsn-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 00 04 * * * + timer: H 08 * * * - ttcn3-msc-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-msc-test.*" - timer: 30 04 * * * + timer: H 08 * * * - ttcn3-pcu-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 00 05 * * * + timer: H 08 * * * - ttcn3-pcu-test-sns-latest: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 15 05 * * * + timer: H 08 * * * - ttcn3-sgsn-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-sgsn-test.*" - timer: 30 05 * * * + timer: H 08 * * * + - ttcn3-sgsn-test-sns-latest: + timer: H 08 * * * - ttcn3-bsc-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 00 06 * * * + timer: H 08 * * * - ttcn3-mgw-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-mgw-test.*" - timer: 30 06 * * * + timer: H 08 * * * - ttcn3-hlr-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-hlr-test.*" - timer: 45 06 * * * + timer: H 08 * * * - ttcn3-bts-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-bts-test.*" - timer: 00 07 * * * + timer: H 08 * * * - ttcn3-sip-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-sip-test.*" - timer: 30 07 * * * + timer: H 09 * * * - ttcn3-bscnat-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-bscnat-test.*" - timer: 00 08 * * * + timer: H 09 * * * disabled: true - ttcn3-bsc-test-sccplite-latest: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 30 08 * * * + timer: H 09 * * * - ttcn3-remsim-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-remsim-test.*" - timer: 00 09 * * * + timer: H 09 * * * - ttcn3-stp-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-stp-test.*" - timer: 30 09 * * * + timer: H 09 * * * - ttcn3-sccp-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-sccp-test.*" - timer: 00 10 * * * + timer: H 09 * * * - ttcn3-smlc-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-smlc-test.*" - timer: 10 10 * * * + timer: H 09 * * * - ttcn3-gbproxy-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-gbproxy-test.*" - timer: 20 10 * * * + timer: H 09 * * * - ttcn3-gbproxy-test-fr-latest: - blocking: "^(ttcn3|TTCN3-.*)-gbproxy-test-fr.*" - timer: 30 10 * * * + timer: H 09 * * * node: hdlc - ttcn3-cbc-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-cbc-test.*" - timer: 40 10 * * * + timer: H 09 * * * - ttcn3-pcap-client-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-pcap-client-test.*" - timer: 40 11 * * * + timer: H 10 * * * - ttcn3-hnodeb-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-hnodeb-test.*" - timer: 40 12 * * * + timer: H 10 * * * - ttcn3-upf-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-upf-test.*" - timer: 00 13 * * * + timer: H 10 * * * disabled: true - ttcn3-hnbgw-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-hnbgw-test.*" - timer: 40 13 * * * + timer: H 10 * * * # Jobs below use uppercase TTCN3-$DISTRO, so they get listed separately from the ttcn3-* (debian) jobs # centos7 nightly - TTCN3-centos7-pcap-client-test: - blocking: "^(ttcn3|TTCN3-.*)-pcap-client-test.*" - timer: 10 13 * * * + timer: H 10 * * * # centos7 latest - TTCN3-centos7-pcap-client-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 40 13 * * * - - # centos8 nightly - - TTCN3-centos-ggsn-test: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 00 04 * * * - - TTCN3-centos-msc-test: - blocking: "^(ttcn3|TTCN3-.*)-msc-test.*" - timer: 30 04 * * * - - TTCN3-centos-pcu-test: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 00 05 * * * - - TTCN3-centos-pcu-test-sns: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 15 05 * * * - - TTCN3-centos-sgsn-test: - blocking: "^(ttcn3|TTCN3-.*)-sgsn-test.*" - timer: 30 05 * * * - - TTCN3-centos-bsc-test: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 00 06 * * * - - TTCN3-centos-mgw-test: - blocking: "^(ttcn3|TTCN3-.*)-mgw-test.*" - timer: 30 06 * * * - - TTCN3-centos-hlr-test: - blocking: "^(ttcn3|TTCN3-.*)-hlr-test.*" - timer: 45 06 * * * - - TTCN3-centos-bts-test: - blocking: "^(ttcn3|TTCN3-.*)-bts-test.*" - timer: 00 07 * * * - - TTCN3-centos-sip-test: - blocking: "^(ttcn3|TTCN3-.*)-sip-test.*" - timer: 30 07 * * * - - TTCN3-centos-bsc-test-sccplite: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 30 08 * * * - - TTCN3-centos-remsim-test: - blocking: "^(ttcn3|TTCN3-.*)-remsim-test.*" - timer: 00 09 * * * - disabled: true - - TTCN3-centos-stp-test: - blocking: "^(ttcn3|TTCN3-.*)-stp-test.*" - timer: 30 09 * * * - - TTCN3-centos-gbproxy-test: - blocking: "^(ttcn3|TTCN3-.*)-gbproxy-test.*" - timer: 20 10 * * * - - TTCN3-centos-cbc-test: - blocking: "^(ttcn3|TTCN3-.*)-cbc-test.*" - timer: 40 10 * * * - - # centos8 latest stable - - TTCN3-centos-ggsn-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-ggsn-test.*" - timer: 00 04 * * * - - TTCN3-centos-msc-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-msc-test.*" - timer: 30 04 * * * - - TTCN3-centos-pcu-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 00 05 * * * - - TTCN3-centos-pcu-test-sns-latest: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 15 05 * * * - - TTCN3-centos-sgsn-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-sgsn-test.*" - timer: 30 05 * * * - - TTCN3-centos-bsc-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 00 06 * * * - - TTCN3-centos-mgw-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-mgw-test.*" - timer: 30 06 * * * - - TTCN3-centos-hlr-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-hlr-test.*" - timer: 45 06 * * * - - TTCN3-centos-bts-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-bts-test.*" - timer: 00 07 * * * - - TTCN3-centos-sip-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-sip-test.*" - timer: 30 07 * * * - - TTCN3-centos-bsc-test-sccplite-latest: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 30 08 * * * - - TTCN3-centos-remsim-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-remsim-test.*" - timer: 00 09 * * * - disabled: true - - TTCN3-centos-stp-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-stp-test.*" - timer: 30 09 * * * - - TTCN3-centos-smlc-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-smlc-test.*" - timer: 10 10 * * * - - TTCN3-centos-sccp-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-sccp-test.*" - timer: 00 10 * * * - - TTCN3-centos-gbproxy-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-gbproxy-test.*" - timer: 20 10 * * * - - TTCN3-centos-cbc-test-latest: - blocking: "^(ttcn3|TTCN3-.*)-cbc-test.*" - timer: 40 10 * * * + timer: H 10 * * * - # centos8 2022q2 (SYS#6007) - - TTCN3-centos-pcu-test-2022q2: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 00 17 * * * - - TTCN3-centos-pcu-test-sns-2022q2: - blocking: "^(ttcn3|TTCN3-.*)-pcu-test.*" - timer: 15 17 * * * - - TTCN3-centos-bsc-test-2022q2: - blocking: "^(ttcn3|TTCN3-.*)-bsc-test.*" - timer: 30 17 * * * - - TTCN3-centos-mgw-test-2022q2: - blocking: "^(ttcn3|TTCN3-.*)-mgw-test.*" - timer: 45 17 * * * - - TTCN3-centos-bts-test-2022q2: - blocking: "^(ttcn3|TTCN3-.*)-bts-test.*" - timer: 00 18 * * * - - TTCN3-centos-smlc-test-2022q2: - blocking: "^(ttcn3|TTCN3-.*)-smlc-test.*" - timer: 15 18 * * * - - TTCN3-centos-gbproxy-test-2022q2: - blocking: "^(ttcn3|TTCN3-.*)-gbproxy-test.*" - timer: 30 18 * * * + # With LIBOSMO_IO_BACKEND=IO_URING (OS#6357) + - ttcn3-bsc-test-io_uring: + timer: H 11 * * * + node: ttcn3_with_linux_6.1_or_higher # Runs out of memory on others (OS#6405) + - ttcn3-msc-test-io_uring: + timer: H 11 * * * + - ttcn3-hnbgw-test-io_uring: + timer: H 11 * * * + - ttcn3-gbproxy-test-io_uring: + timer: H 11 * * * + - ttcn3-sgsn-test-io_uring: + timer: H 11 * * * + - ttcn3-stp-test-io_uring: + timer: H 11 * * * + - ttcn3-mgw-test-io_uring: + timer: H 11 * * * - job-template: name: '{job-name}' @@ -407,6 +264,15 @@ # Run against debian's kernel export KERNEL_TEST=1 ;; + ttcn3-ggsn-test-kernel-pablo-gtp) + DIR="ttcn3-ggsn-test" + export IMAGE_SUFFIX="master" + export KERNEL_TEST=1 + export KERNEL_BUILD=1 + export KERNEL_URL="https://git.kernel.org/pub/scm/linux/kernel/git/pablo/gtp.git" + export KERNEL_REMOTE_NAME="pablo-gtp" + export KERNEL_BRANCH="main" + ;; ttcn3-ggsn-test-kernel-latest) DIR="ttcn3-ggsn-test" export IMAGE_SUFFIX="latest" @@ -419,7 +285,7 @@ export KERNEL_BUILD=1 export KERNEL_URL="https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next.git" export KERNEL_REMOTE_NAME="net-next" - export KERNEL_BRANCH="master" + export KERNEL_BRANCH="main" ;; ttcn3-ggsn-test-kernel-latest-torvalds) DIR="ttcn3-ggsn-test" @@ -430,28 +296,19 @@ export KERNEL_REMOTE_NAME="torvalds" export KERNEL_BRANCH="master" ;; - TTCN3-centos-*-latest) - DIR="$(echo "{job-name}" | sed s/^TTCN3-centos\-/ttcn3-/ | sed s/\-latest$//)" - export IMAGE_SUFFIX="latest-centos8" - ;; TTCN3-centos7-*-latest) DIR="$(echo "{job-name}" | sed s/^TTCN3-centos7\-/ttcn3-/ | sed s/\-latest$//)" export IMAGE_SUFFIX="latest-centos7" ;; - TTCN3-centos-*-20*q*) - export OSMOCOM_REPO_PATH="osmo-maintained" - export OSMOCOM_REPO_VERSION="$(echo "{job-name}" | grep -o -P -- "20\d\dq.*$")" # e.g. "2021q1" - export IMAGE_SUFFIX="$OSMOCOM_REPO_VERSION-centos8" - DIR="$(echo "{job-name}" | sed s/^TTCN3-centos\-/ttcn3-/ | sed s/\-$OSMOCOM_REPO_VERSION$//)" - ;; - TTCN3-centos-*) - DIR="$(echo "{job-name}" | sed s/^TTCN3-centos\-/ttcn3-/)" - export IMAGE_SUFFIX="master-centos8" - ;; TTCN3-centos7-*) DIR="$(echo "{job-name}" | sed s/^TTCN3-centos7\-/ttcn3-/)" export IMAGE_SUFFIX="master-centos7" ;; + *-io_uring) + DIR="$(echo "{job-name}" | sed s/\-io_uring$//)" + # OS#6405: set memlock to unlimited for older kernels + export DOCKER_ARGS="-e LIBOSMO_IO_BACKEND=IO_URING --ulimit memlock=-1" + ;; *-latest) DIR="$(echo "{job-name}" | sed s/\-latest$//)" export IMAGE_SUFFIX="latest" @@ -479,8 +336,8 @@ results: '**/junit-xml-*.log' allow-empty-results: false - email: - notify-every-unstable-build: true - recipients: laforge@gnumonks.org osmith@sysmocom.de + notify-every-unstable-build: false + recipients: '{obj:email}' send-to-individuals: false - archive: allow-empty: false @@ -490,17 +347,12 @@ fingerprint: false only-if-success: false properties: - - build-blocker: - use-build-blocker: true - blocking-jobs: - - "{obj:blocking}" - build-discarder: days-to-keep: 30 num-to-keep: 120 - artifact-days-to-keep: -1 - artifact-num-to-keep: -1 wrappers: - ansicolor: colormap: xterm + email: jenkins-notifications@lists.osmocom.org # vim: expandtab tabstop=2 shiftwidth=2 diff --git a/jobs/update-osmo-ci-on-slaves.yml b/jobs/update-osmo-ci-on-slaves.yml index 41181cd..c826175 100644 --- a/jobs/update-osmo-ci-on-slaves.yml +++ b/jobs/update-osmo-ci-on-slaves.yml @@ -6,22 +6,31 @@ type: slave name: label values: - - simtester - - host2-deb9build-ansible - - build2-deb9build-ansible - build2-deb10build-ansible + - build2-deb11build-ansible + - build4-deb12build-ansible + - gtp0-deb10fr + - host2-deb11build-ansible - rpi4-raspbian11build-ansible-1 - rpi4-raspbian11build-ansible-2 - rpi4-raspbian11build-ansible-3 - - gtp0-deb9build - - gtp0-deb11build32 - - gtp0-deb10fr - - osmo-gsm-tester-prod - - osmo-gsm-tester-rnd + - simtester properties: - build-discarder: days-to-keep: 30 num-to-keep: 120 + parameters: + - string: + name: OSMO_BRANCH_CI + description: | + osmo-ci.git branch + default: 'master' + - string: + # Used in scripts/common.sh:docker_images_require() + name: OSMO_BRANCH_DOCKER_PLAYGROUND + description: | + docker-playground.git branch + default: 'master' scm: - git: url: https://gerrit.osmocom.org/osmo-ci @@ -29,7 +38,8 @@ git-config-email: 'jenkins@osmocom.org' skip-tag: true branches: - - 'origin/master' + - '$OSMO_BRANCH_CI' + wipe-workspace: true triggers: - pollscm: @@ -39,6 +49,11 @@ builders: - shell: './contrib/jenkins.sh' + + wrappers: + - ansicolor: + colormap: xterm + description: | <b>Auto-generated using Jenkins Job Builder. DO NOT EDIT MANUALLY!</b> @@ -52,7 +67,6 @@ description: | Trigger <a href="https://jenkins.osmocom.org/jenkins/job/update-osmo-ci-on-slaves/">update-osmo-ci-on-slaves</a> on changes in docker-playground.git, so it can rebuild docker containers relevant for the jenkins slaves. - node: osmocom-master-debian9 scm: - git: url: https://gerrit.osmocom.org/docker-playground diff --git a/jobs/update-osmo-python-on-slaves.yml b/jobs/update-osmo-python-on-slaves.yml index 4a2afbc..fad1cf6 100644 --- a/jobs/update-osmo-python-on-slaves.yml +++ b/jobs/update-osmo-python-on-slaves.yml @@ -6,9 +6,10 @@ type: slave name: label values: - - host2-deb9build-ansible - - build2-deb9build-ansible - build2-deb10build-ansible + - build2-deb11build-ansible + - build4-deb12build-ansible + - host2-deb11build-ansible - rpi4-raspbian11build-ansible-1 - rpi4-raspbian11build-ansible-2 - rpi4-raspbian11build-ansible-3 |