]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-build.git/commitdiff
Grab SHA1 into parent job's environment for human or program 1665/head
authorDan Mick <dmick@redhat.com>
Thu, 24 Sep 2020 17:26:07 +0000 (17:26 +0000)
committerDan Mick <dmick@redhat.com>
Thu, 24 Sep 2020 17:28:19 +0000 (17:28 +0000)
The Ceph SHA1 is divined by the -setup job, and not available in the
parent job.  That's easily fixed by the same method it's passed to the
-build job: grab the file artifact and use it to inject SHA1 into the
environment.  This means the parent job can show the SHA1 in its build
label for humans, and can also be searched by Jenkins API calls.

Signed-off-by: Dan Mick <dmick@redhat.com>
ceph-dev-new-setup/config/definitions/ceph-dev-new-setup.yml
ceph-dev-new/config/definitions/ceph-dev-new.yml
ceph-dev-setup/config/definitions/ceph-dev-setup.yml
ceph-dev/config/definitions/ceph-dev.yml

index af3dafe55363ed2581f5c5a4c9ebc54c5c94fd88..1667540cb7831a2900ffdda3d98320bc611b9bed 100644 (file)
@@ -15,7 +15,7 @@
       - github:
           url: https://github.com/ceph/ceph-ci
       - copyartifact:
-          projects: ceph-dev-new-build
+          projects: ceph-dev-new-build, ceph-dev-new
 
     parameters:
       - string:
index 7f46df007729f3b0a393fde17489c1749b2b8cd6..2fde222bd0f40e2fb1cd595258a0430c0140622e 100644 (file)
@@ -88,6 +88,12 @@ If this is checked, then the binaries will be built and pushed to chacra even if
             - name: ceph-dev-new-setup
               current-parameters: true
               exposed-scm: false
+      - copyartifact:
+          project: ceph-dev-new-setup
+          filter: dist/sha1
+          which-build: multijob-build
+      - inject:
+          properties-file: ${WORKSPACE}/dist/sha1
       - multijob:
           name: 'ceph dev build phase'
           condition: SUCCESSFUL
index c10e304698afa1abe3fb81e599265ab3c36e202f..54d9a12a509c9ddbf6c77f5ea2ec4a6974203309 100644 (file)
@@ -15,7 +15,7 @@
       - github:
           url: https://github.com/ceph/ceph
       - copyartifact:
-          projects: ceph-dev-build
+          projects: ceph-dev-build, ceph-dev
 
     parameters:
       - string:
index 9792fce60b142334360cfb7c141371c75f3e67c1..6bc8d50e06a131fb536d18fbc3ad2d7fcf1d64f6 100644 (file)
@@ -88,6 +88,12 @@ If this is checked, then the binaries will be built and pushed to chacra even if
             - name: ceph-dev-setup
               current-parameters: true
               exposed-scm: false
+      - copyartifact:
+          project: ceph-dev-setup
+          filter: dist/sha1
+          which-build: multijob-build
+      - inject:
+          properties-file: ${WORKSPACE}/dist/sha1
       - multijob:
           name: 'ceph dev build phase'
           condition: SUCCESSFUL