Add a role to write a root marker

This is a single task within the existing afs prep role, but we
need to be able to do it alone for certain special doc builds,
like infra index page generation.

We could use include_role in the future to de-duplicate this, once
zuul_json supports that.

Change-Id: Ia6c6257cb1479abef79bf919cb6ad25ea6828d90
This commit is contained in:
James E. Blair 2017-09-27 15:48:39 -07:00
parent 5771911e77
commit 2f230e02d5
3 changed files with 14 additions and 0 deletions

View File

@ -0,0 +1,9 @@
Write the root marker for an AFS publishing job
** Role Variables **
.. zuul:rolevar:: root_marker_dir
:default: src/{{ zuul.project.canonical_name }}/doc/build/html
The documentation build directory. The marker file will be placed
in this directory.

View File

@ -0,0 +1 @@
root_marker_dir: "src/{{ zuul.project.canonical_name }}/doc/build/html"

View File

@ -0,0 +1,4 @@
- name: Write marker text
copy:
dest: "{{ root_marker_dir }}/.root-marker"
content: "Project: {{ zuul.project.name }} Branch: {{ zuul.branch }} Build: {{ zuul.build }} Revision: {{ zuul.ref }}"