Merge "Allow packer-merge job to test WIP patch"
authorThanh Ha (zxiiro) <thanh.ha@linuxfoundation.org>
Tue, 20 Nov 2018 01:30:52 +0000 (01:30 +0000)
committerGerrit Code Review <gerrit@linuxfoundation.org>
Tue, 20 Nov 2018 01:30:52 +0000 (01:30 +0000)
docs/conf.py
docs/jjb/lf-ci-jobs.rst
jjb/lf-ci-jobs.yaml
releasenotes/notes/packer-merge-test-wip-patches-40b2e87677a84d38.yaml [new file with mode: 0644]

index 5bbe39f..4457e12 100644 (file)
@@ -277,6 +277,7 @@ htmlhelp_basename = 'LinuxFoundationReleaseEngineeringGJJBdoc'
 # Example configuration for intersphinx: refer to the Python standard library.
 intersphinx_mapping = {
     'jjb': ('https://docs.openstack.org/infra/jenkins-job-builder/', None),
+    'lfdocs': ('http://docs.releng.linuxfoundation.org/en/latest/', None),
     'lftools': ('http://lftools.releng.linuxfoundation.org/en/latest/', None),
     'python': ('https://docs.python.org/', None),
 }
index 9e0941c..f55b5dc 100644 (file)
@@ -661,6 +661,19 @@ Packer Merge job runs `packer build` to build system images in the cloud.
 
     :gerrit_verify_triggers: Override Gerrit Triggers.
 
+Test an in-progress patch
+^^^^^^^^^^^^^^^^^^^^^^^^^
+
+To test an in-progress patch from a GitHub Pull Request. Upload this
+job to the :doc:`Jenkins Sandbox <lfdocs:jenkins-sandbox>`. Then when manually
+building the job replace the GERRIT_REFSPEC parameter with the GitHub Pull
+Request number of the patch you would like to test.
+
+Example GitHub:
+
+.. code-block:: none
+
+   GERRIT_REFSPEC: origin/pr/49/merge
 
 .. _gjjb-packer-verify:
 
index 5fe95a6..f097260 100644 (file)
     scm:
       - lf-infra-github-scm:
           url: '{git-clone-url}{github-org}/{project}'
-          refspec: ''
-          branch: 'refs/heads/{branch}'
+          refspec: >
+              +refs/heads/*:refs/remotes/origin/*
+              +refs/pull/*:refs/remotes/origin/pr/*
+          branch: '$GERRIT_REFSPEC'
           submodule-recursive: '{submodule-recursive}'
           submodule-timeout: '{submodule-timeout}'
           choosing-strategy: default
diff --git a/releasenotes/notes/packer-merge-test-wip-patches-40b2e87677a84d38.yaml b/releasenotes/notes/packer-merge-test-wip-patches-40b2e87677a84d38.yaml
new file mode 100644 (file)
index 0000000..0db556b
--- /dev/null
@@ -0,0 +1,6 @@
+---
+features:
+  - |
+    The GERRIT_REFSPEC build parameter can now be used to trigger a test build
+    from the Jenkins Sandbox system against a work in progress packer image
+    patch from a GitHub Pull Request.