Use opendev-tox-docs job

Switch our docs job to use opendev-tox-docs job as base so that we can
publish later the content from gate directly (via promote queue) and do
not need to rebuild in post again.

Use the new promote-openstack-manuals job as first step in using promote
publishing. The other publish jobs will be replaced separately.

Use for building now publishdocs/publishlang so that we have exactly
the same content in check and gate - and in the published website.
For this, update tox.ini and publish script.

Also, do not publish project-data.

Depends-On: https://review.opendev.org/676489
Change-Id: I91f22173a4a6ed421f339833c486a31fd319dba3
This commit is contained in:
Andreas Jaeger 2019-08-14 20:32:18 +02:00
parent 741d59c459
commit 99920e8a49
4 changed files with 12 additions and 13 deletions

View File

@ -14,13 +14,13 @@
Note that this build job does not create a root-marker file, Note that this build job does not create a root-marker file,
this has to be done by scripts called from tox. this has to be done by scripts called from tox.
parent: openstack-tox parent: opendev-tox-docs
nodeset: ubuntu-bionic nodeset: ubuntu-bionic
success-url: publish-docs/html/ success-url: publish-docs/html/
post-run: playbooks/build-manuals-tox/post.yaml
roles: roles:
- zuul: zuul/zuul-jobs - zuul: zuul/zuul-jobs
vars: vars:
sphinx_build_dir: 'publish-docs'
tox_environment: tox_environment:
# The tox job writes the root-marker file directly and thus # The tox job writes the root-marker file directly and thus
# needs the following variables set: # needs the following variables set:
@ -30,20 +30,22 @@
ZUUL_NEWREF: '{{ zuul.ref }}' ZUUL_NEWREF: '{{ zuul.ref }}'
- job: - job:
# TODO(AJaeger): Rename to publishdocs
name: build-tox-manuals-checkbuild name: build-tox-manuals-checkbuild
parent: build-tox-manuals-base parent: build-tox-manuals-base
description: | description: |
Build manuals using "checkbuild" tox environment. Build manuals using "publishdocs" tox environment.
vars: vars:
tox_envlist: checkbuild tox_envlist: publishdocs
- job: - job:
# TODO(AJaeger): Rename to publishlang
name: build-tox-manuals-checklang name: build-tox-manuals-checklang
parent: build-tox-manuals-base parent: build-tox-manuals-base
description: | description: |
Build translated manuals using "checklang" tox environment. Build translated manuals using "publishlang" tox environment.
vars: vars:
tox_envlist: checklang tox_envlist: publishlang
files: files:
- ^.*\.po$ - ^.*\.po$
- ^.*\.pot$ - ^.*\.pot$
@ -68,7 +70,7 @@
- build-tox-manuals-checkbuild - build-tox-manuals-checkbuild
post: post:
jobs: jobs:
- publish-openstack-manuals - promote-openstack-manuals
- project-template: - project-template:
name: openstack-manuals-developer-jobs name: openstack-manuals-developer-jobs

View File

@ -1,5 +0,0 @@
- hosts: all
roles:
- role: fetch-tox-output
- role: fetch-sphinx-output
sphinx_build_dir: 'publish-docs'

View File

@ -40,7 +40,7 @@ if [ "$PUBLISH" = "publish" ] ; then
rsync -a www/static/ publish-docs/html/ rsync -a www/static/ publish-docs/html/
# Don't publish these files # Don't publish these files
rm publish-docs/html/www-index.html rm publish-docs/html/www-index.html
rm publish-docs/html/redirect-tests.txt rm -rf publish-docs/html/project-data
fi fi
if [ "$PUBLISH" = "build" ] ; then if [ "$PUBLISH" = "build" ] ; then

View File

@ -55,6 +55,8 @@ commands =
# over. # over.
commands = commands =
{toxinidir}/tools/publishdocs.sh publish {toxinidir}/tools/publishdocs.sh publish
whereto publish-docs/html/.htaccess publish-docs/html/redirect-tests.txt
rm publish-docs/html/redirect-tests.txt
[testenv:checklang] [testenv:checklang]
whitelist_externals = doc-tools-check-languages whitelist_externals = doc-tools-check-languages