From 4f48c5be222261fa650f15d231909663b24427f1 Mon Sep 17 00:00:00 2001 From: Andrew Schoen Date: Fri, 16 Jun 2017 13:03:42 -0500 Subject: [PATCH] ceph-medic-pull-requests: adds a job to test ceph-medic PRs Signed-off-by: Andrew Schoen --- ceph-medic-pull-requests/build/build | 9 +++ .../definitions/ceph-medic-pull-requests.yml | 64 +++++++++++++++++++ 2 files changed, 73 insertions(+) create mode 100644 ceph-medic-pull-requests/build/build create mode 100644 ceph-medic-pull-requests/config/definitions/ceph-medic-pull-requests.yml diff --git a/ceph-medic-pull-requests/build/build b/ceph-medic-pull-requests/build/build new file mode 100644 index 00000000..63fe8992 --- /dev/null +++ b/ceph-medic-pull-requests/build/build @@ -0,0 +1,9 @@ +#!/bin/bash + +# the following two methods exist in scripts/build_utils.sh +pkgs=( "tox" ) +install_python_packages "pkgs[@]" + +cd "$WORKSPACE/ceph-medic" + +$VENV/tox -rv diff --git a/ceph-medic-pull-requests/config/definitions/ceph-medic-pull-requests.yml b/ceph-medic-pull-requests/config/definitions/ceph-medic-pull-requests.yml new file mode 100644 index 00000000..4f0f1043 --- /dev/null +++ b/ceph-medic-pull-requests/config/definitions/ceph-medic-pull-requests.yml @@ -0,0 +1,64 @@ +- scm: + name: ceph-medic + scm: + - git: + url: https://github.com/ceph/ceph-medic + branches: + - ${sha1} + refspec: +refs/pull/*:refs/remotes/origin/pr/* + browser: auto + timeout: 20 + basedir: "ceph-medic" + skip-tag: true + wipe-workspace: true + + +- job: + name: ceph-medic-pull-requests + description: Runs tox tests for ceph-medic on each GitHub PR + project-type: freestyle + node: python3 + block-downstream: false + block-upstream: false + defaults: global + display-name: 'ceph-medic: Pull Requests' + quiet-period: 5 + retry-count: 3 + + logrotate: + daysToKeep: 15 + numToKeep: 30 + artifactDaysToKeep: 15 + artifactNumToKeep: 15 + + properties: + - github: + url: https://github.com/ceph/ceph-medic/ + + parameters: + - string: + name: sha1 + description: "A pull request ID, like 'origin/pr/72/head'" + + triggers: + - github-pull-request: + admin-list: + - alfredodeza + - dmick + - ktdreyer + - andrewschoen + org-list: + - ceph + only-trigger-phrase: false + github-hooks: true + permit-all: true + auto-close-on-fail: false + + scm: + - ceph-medic + + builders: + - shell: + !include-raw: + - ../../../scripts/build_utils.sh + - ../../build/build -- 2.47.3