Add support to pullin distgit changes

This change addes the ability to bundle a packaging change during the
dlrn build with a code change. It can also be used to just test
packaging changes by switching the change repo to be the main repository
and include a distgit change only.

Change-Id: Ibeea3ef436dccaf36c254b232f922983cd101c5b
This commit is contained in:
Alex Schultz 2018-08-14 16:42:37 -06:00 committed by Emilien Macchi
parent 7ff1a01e4e
commit 5ef81585c2
2 changed files with 25 additions and 0 deletions

View File

@ -39,6 +39,8 @@ Role Variables
* `dlrn_use_local_mirrors` -- use the local repo definitions from
/etc/yum.repos.d/ for CentOS and DLRN while building packages; used upstream
Example artg_change_list for just code changes:
```yaml
artg_change_list:
- host: "review.openstack.org"
@ -48,6 +50,20 @@ artg_change_list:
- host: ...
```
Example artg_change_list for code changes and package changes:
```yaml
artg_change_list:
- host: "review.openstack.org"
project: "openstack/tripleo-heat-templates"
branch: "master"
refspec: "refs/changes/1/123456/1"
distgit:
host: "ssh://user@review.rdoproject.org"
project: "openstack/tripleo-heat-templates-distgit"
refspec: "refs/changes/1/123456/1"
- host: ...
```
Gating with Zuul or Jenkins
---------------------------

View File

@ -64,6 +64,15 @@
version: 'FETCH_HEAD'
when: artg_repos_dir is not defined or copy_dir is failed
- name: Clone the distgit change
git:
repo: '{{ artg_change.distgit.host }}/{{ artg_change.distgit.project }}'
dest: '{{ build_repo_dir }}/DLRN/data/{{ project_name_mapped.stdout }}_distro'
refspec: '{{ artg_change.distgit.refspec }}'
version: 'FETCH_HEAD'
accept_hostkey: yes
when: artg_change.distgit is defined and (artg_repos_dir is not defined or copy_dir is failed)
- name: Run DLRN
shell: >
set +e;