]> git.apps.os.sepia.ceph.com Git - ceph-build.git/commitdiff
ceph-dashboard-pr-backend: Only run during PR pipeline wip-combine-db-prs
authorDavid Galloway <dgallowa@redhat.com>
Mon, 29 Jun 2020 22:32:00 +0000 (18:32 -0400)
committerDavid Galloway <dgallowa@redhat.com>
Mon, 29 Jun 2020 23:08:24 +0000 (19:08 -0400)
Signed-off-by: David Galloway <dgallowa@redhat.com>
ceph-dashboard-pr-backend/build/build
ceph-dashboard-pr-backend/build/failure [new file with mode: 0644]
ceph-dashboard-pr-backend/build/finish [new file with mode: 0644]
ceph-dashboard-pr-backend/config/definitions/ceph-dashboard-pr-backend.yml

index 7460f2f595187275d4aa872a5d8a4206419916c2..91de7b9aacd94f838ff38dfe0ffaf1bc0776fe04 100644 (file)
@@ -1,8 +1,2 @@
-#!/bin/bash -e
-n_build_jobs=$(get_nr_build_jobs)
-n_test_jobs=$(($(nproc) / 4))
-export CHECK_MAKEOPTS="-j${n_test_jobs} -N -Q"
-export BUILD_MAKEOPTS="-j${n_build_jobs}"
-timeout 3h ./run-make-check.sh
-sleep 5
-ps -ef | grep ceph || true
+#!/bin/bash
+update_github_status "ceph" "pending" "ceph dashboard backend API tests" "Running"
diff --git a/ceph-dashboard-pr-backend/build/failure b/ceph-dashboard-pr-backend/build/failure
new file mode 100644 (file)
index 0000000..a24be93
--- /dev/null
@@ -0,0 +1,2 @@
+#!/bin/bash
+update_github_status "ceph" "failure" "ceph dashboard backend API tests"
diff --git a/ceph-dashboard-pr-backend/build/finish b/ceph-dashboard-pr-backend/build/finish
new file mode 100644 (file)
index 0000000..920e786
--- /dev/null
@@ -0,0 +1,2 @@
+#!/bin/bash
+update_github_status "ceph" "success" "ceph dashboard backend API tests"
index 13aa3fd4b362bf7cc8952b083dda2f92d20ac287..6a3d18d4b9866d3a21abe44b7278f53cbcbf103d 100644 (file)
@@ -1,6 +1,5 @@
 - job:
     name: ceph-dashboard-pr-backend
-    project-type: freestyle
     defaults: global
     concurrent: true
     node: huge && bionic && x86_64 && !xenial && !trusty
           name: sha1
           description: "commit id or a refname, like 'origin/pr/72/head'"
 
-    triggers:
-      - github-pull-request:
-          allow-whitelist-orgs-as-admins: true
-          org-list:
-            - ceph
-          white-list-target-branches:
-            - master
-            - octopus
-            - nautilus
-          trigger-phrase: 'jenkins test dashboard backend'
-          skip-build-phrase: '^jenkins do not test.*'
-          only-trigger-phrase: false
-          github-hooks: true
-          permit-all: true
-          auto-close-on-fail: false
-          status-context: "ceph dashboard backend API tests"
-          started-status: "running ceph dashboard backend API tests"
-          success-status: "ceph dashboard backend API tests succeeded"
-          failure-status: "ceph dashboard backend API tests failed"
-
     scm:
       - git:
           url: https://github.com/ceph/ceph.git
           wipe-workspace: true
 
     builders:
+      - copyartifact:
+          project: ceph-pull-requests
+          filter: 'build/**'
+          which-build: multijob-build
       - shell:
           !include-raw:
             - ../../../scripts/build_utils.sh
             - ../../build/build
             - ../../../scripts/dashboard/install-backend-api-test-deps.sh
       - shell: "cd src/pybind/mgr/dashboard; timeout 7200 ./run-backend-api-tests.sh"
+      - shell:
+          !include-raw:
+            - ../../../scripts/build_utils.sh
+            - ../../build/finish
 
     wrappers:
       - ansicolor
+      - credentials-binding:
+          - text:
+              credential-id: 8dff73ff-506c-4397-969d-023f15aedea9
+              variable: GITHUB_API_TOKEN
+
+    publishers:
+      - archive:
+          artifacts: 'build/**'
+          allow-empty: false
+          latest-only: false
+      - postbuildscript:
+          builders:
+            - role: SLAVE
+              build-on:
+                  - FAILURE
+                  - ABORTED
+              build-steps:
+                - shell:
+                    !include-raw:
+                      - ../../../scripts/build_utils.sh
+                      - ../../build/failure