diff --git a/jenkins/jobs/gerrit-plugin-jobs.yaml b/jenkins/jobs/gerrit-plugin-jobs.yaml index 7a48257fed..94106d57d4 100644 --- a/jenkins/jobs/gerrit-plugin-jobs.yaml +++ b/jenkins/jobs/gerrit-plugin-jobs.yaml @@ -16,12 +16,19 @@ export PATH=`pwd`/buck/bin:$PATH rm -rf gerrit git clone -b {gerrit-branch} {gerrit-project} + PLUGIN_PARENT_PROJECT={plugin-parent-project} + if [ -n "$PLUGIN_PARENT_PROJECT" ]; then + git clone -b {gerrit-branch} {plugin-parent-project} gerrit/plugins/{plugin-parent-name} + fi git clone -b {plugin-branch} {plugin-project} gerrit/plugins/{plugin-name} cd gerrit/plugins/{plugin-name} /usr/local/jenkins/slave_scripts/version-properties.sh source version.properties cd $WORKSPACE/gerrit buck clean + if [ -n "$PLUGIN_PARENT_PROJECT" ]; then + buck build plugins/{plugin-parent-name}:{plugin-parent-name} + fi buck build plugins/{plugin-name}:{plugin-name} cp ./buck-out/gen/plugins/{plugin-name}/{plugin-name}.jar ./buck-out/gen/plugins/{plugin-name}/{plugin-name}-$PROJECT_VER.jar diff --git a/jenkins/jobs/projects.yaml b/jenkins/jobs/projects.yaml index 99e6e7e129..bd02353242 100644 --- a/jenkins/jobs/projects.yaml +++ b/jenkins/jobs/projects.yaml @@ -1992,6 +1992,8 @@ name: gerrit tarball-site: tarballs.openstack.org gerrit-project: 'https://git.openstack.org/openstack-infra/gerrit' + plugin-parent-name: '' + plugin-parent-project: '' jobs: - '{plugin-name}-gerrit-plugin-{plugin-branch}': @@ -2009,6 +2011,15 @@ plugin-name: 'importer' plugin-project: 'https://gerrit.googlesource.com/plugins/{plugin-name}' plugin-branch: 'stable-2.11' + # its plugins depend on a parent plugin. We need to build parent + # the parent plugin then build the child plugin. + - '{plugin-name}-gerrit-plugin-{plugin-branch}': + gerrit-branch: 'openstack/2.11.4' + plugin-name: 'its-storyboard' + plugin-project: 'https://gerrit.googlesource.com/plugins/{plugin-name}' + plugin-parent-name: 'its-base' + plugin-parent-project: 'https://gerrit.googlesource.com/plugins/{plugin-parent-name}' + plugin-branch: 'stable-2.11' - project: name: gerrit-dash-creator