Monty Taylor 56ceaf1c40 Remove the extra bazel options
We had some extra bazel options that don't seem to be necessary
anymore now that we are using upstream bazel options appropriately.

Retry the build a couple of times if it goes south, inside of the
build image. This should allow re-use of the cache the second time,
and if there is a temporary error, it should pick up and move
forward.

Change-Id: I5f304acb21fd3a4d40701fc0414ae0c424c838e5
2019-08-26 11:26:19 +02:00

55 lines
1.9 KiB
YAML

- hosts: all
tasks:
- name: Move plugin repos into gerrit tree
command: "mv -f {{ item }} ../gerrit/plugins"
args:
chdir: /home/zuul/src/gerrit.googlesource.com/plugins
loop:
- commit-message-length-validator
- hooks
- its-storyboard
- its-base
- javamelody
- replication
- reviewnotes
# There is no stable branch for download-commands and no 3.0 branch of
# singleusergroup so we need to check out the actual ref defined in the
# parent repo. Luckily, since we don't set a remote and this submodule
# uses relative paths, it should just clone the right thing and do it
# locally.
- name: Checkout core plugin submodules
command: "git submodule update --init plugins/{{ item }}"
args:
chdir: /home/zuul/src/gerrit.googlesource.com/gerrit
loop:
- download-commands
- singleusergroup
- name: Move additional plugin repos into gerrit tree
command: "mv -f {{ item }} ../gerrit/plugins"
args:
chdir: /home/zuul/src/gerrit.googlesource.com/plugins
loop: "{{ gerrit_additional_plugins | default([]) }}"
- name: Configure plugin bazel file
lineinfile:
path: /home/zuul/src/gerrit.googlesource.com/gerrit/tools/bzl/plugins.bzl
insertafter: "# Add custom core plugins here"
line: '"{{ item }}",'
loop:
- its-storyboard
- its-base
- javamelody
- name: Configure javamelody external plugin deps
file:
state: link
force: yes
src: javamelody/external_plugin_deps.bzl
path: /home/zuul/src/gerrit.googlesource.com/gerrit/plugins/external_plugin_deps.bzl
- name: Move build script into main gerrit source dir
command: "mv docker/gerrit/bazel/build-gerrit.sh /home/zuul/src/gerrit.googlesource.com/gerrit"
args:
chdir: /home/zuul/src/opendev.org/opendev/system-config