aboutsummaryrefslogtreecommitdiffstats
path: root/jobs/osmo-gsm-tester-runner.yml
diff options
context:
space:
mode:
Diffstat (limited to 'jobs/osmo-gsm-tester-runner.yml')
-rw-r--r--jobs/osmo-gsm-tester-runner.yml76
1 files changed, 61 insertions, 15 deletions
diff --git a/jobs/osmo-gsm-tester-runner.yml b/jobs/osmo-gsm-tester-runner.yml
index 73a49db..5bc7140 100644
--- a/jobs/osmo-gsm-tester-runner.yml
+++ b/jobs/osmo-gsm-tester-runner.yml
@@ -32,9 +32,9 @@
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}
+ - '$OSMO_GSM_TESTER_BRANCH'
wipe-workspace: false
skip-tag: true
basedir: osmo-gsm-tester
@@ -111,6 +111,7 @@
- job-template:
name: 'osmo-gsm-tester_run-{stage}'
+ disabled: true
defaults: runner
node: 'osmo-gsm-tester-{stage}'
triggers:
@@ -136,7 +137,7 @@
- osmo-gsm-tester_build-srslte
builders:
- copy_artifact_all
- - shell: !include-raw: osmo-gsm-tester_run-{stage}.sh
+ - shell: !include-raw-expand: osmo-gsm-tester_run-{stage}.sh
publishers:
- archive:
artifacts: '*-run.tgz, *-bin.tgz'
@@ -153,6 +154,7 @@
# gerrit job
- job:
name: 'osmo-gsm-tester_gerrit'
+ disabled: true # osmo-gsm-tester nodes are currently offline
defaults: runner
scm:
- 'osmo-gsm-tester-gerrit'
@@ -171,10 +173,10 @@
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
+ - shell: !include-raw-expand: osmo-gsm-tester_run-gerrit.sh
publishers:
- archive:
artifacts: '*-run.tgz, *-bin.tgz'
@@ -186,6 +188,7 @@
# ttcn3 job
- job:
name: 'osmo-gsm-tester_ttcn3'
+ disabled: true
defaults: runner
scm:
- 'osmo-gsm-tester-repo'
@@ -193,12 +196,12 @@
- 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
- - shell: !include-raw: osmo-gsm-tester_ttcn3.sh
+ - shell: !include-raw-expand: osmo-gsm-tester_ttcn3.sh
publishers:
- archive:
artifacts: '*-run.tgz, *-bin.tgz'
@@ -211,7 +214,7 @@
- job:
name: 'osmo-gsm-tester_virtual'
defaults: runner
- node: 'osmocom-master-debian9'
+ node: 'osmocom-master'
scm:
- 'osmo-gsm-tester-repo'
triggers:
@@ -219,11 +222,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,9 +279,10 @@
-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'
+ /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'
publishers:
- archive:
artifacts: '*-run.tgz, *-bin.tgz'
@@ -251,12 +290,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"