Update Zuul jobs: Enable docs publishing

Start publishing docs with using the proper template.

For this, add also a doc/requirements.txt file and move docs
requirements there. Update tox.ini for this and use the modern way to
invoke sphinx-build for building.
Remove obsolete sectoins from setup.cfg.
Update the conf.py files and remove unused lines
with newer openstackdocstheme - and require newer theme.

Fix indents in CONTRIBUTING.rst so that the formatting works nicely.

Also, use lower-constraints template instead of individual jobs.

Change-Id: Ia1a7030878f12ca0b8184363173eada929ece3bd
This commit is contained in:
Andreas Jaeger 2019-09-05 08:01:07 +02:00
parent 74b52bb349
commit ac3d3de9ec
9 changed files with 23 additions and 74 deletions

6
doc/requirements.txt Normal file
View File

@ -0,0 +1,6 @@
sphinx!=1.6.6,!=1.6.7,>=1.6.2,<2.0.0;python_version=='2.7' # BSD
sphinx!=1.6.6,!=1.6.7,>=1.6.2;python_version>='3.4' # BSD
openstackdocstheme>=1.20.0 # Apache-2.0
# releasenotes
reno>=2.5.0 # Apache-2.0

View File

@ -63,8 +63,6 @@ pygments_style = 'sphinx'
# html_static_path = ['static'] # html_static_path = ['static']
html_theme = 'openstackdocs' html_theme = 'openstackdocs'
html_last_updated_fmt = '%Y-%m-%d %H:%M'
# Output file base name for HTML help builder. # Output file base name for HTML help builder.
htmlhelp_basename = '%sdoc' % project htmlhelp_basename = '%sdoc' % project

View File

@ -12,9 +12,6 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
# Glance Release Notes documentation build configuration file, created by
# sphinx-quickstart on Tue Nov 3 17:40:50 2015.
#
# This file is execfile()d with the current directory set to its # This file is execfile()d with the current directory set to its
# containing dir. # containing dir.
# #
@ -145,7 +142,7 @@ html_theme = 'openstackdocs'
# Add any paths that contain custom static files (such as style sheets) here, # Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files, # relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css". # so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static'] # html_static_path = ['_static']
# Add any extra paths that contain custom files (such as robots.txt or # Add any extra paths that contain custom files (such as robots.txt or
# .htaccess) here, relative to this directory. These files are copied # .htaccess) here, relative to this directory. These files are copied
@ -154,7 +151,7 @@ html_static_path = ['_static']
# If not '', a 'Last updated on:' timestamp is inserted at every page bottom, # If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
# using the given strftime format. # using the given strftime format.
html_last_updated_fmt = '%Y-%m-%d %H:%M' # html_last_updated_fmt = '%Y-%m-%d %H:%M'
# If true, SmartyPants will be used to convert quotes and dashes to # If true, SmartyPants will be used to convert quotes and dashes to
# typographically correct entities. # typographically correct entities.
@ -194,7 +191,7 @@ html_last_updated_fmt = '%Y-%m-%d %H:%M'
# html_file_suffix = None # html_file_suffix = None
# Output file base name for HTML help builder. # Output file base name for HTML help builder.
htmlhelp_basename = 'GlanceReleaseNotesdoc' htmlhelp_basename = 'ovsdbappReleaseNotesdoc'
# -- Options for LaTeX output --------------------------------------------- # -- Options for LaTeX output ---------------------------------------------
@ -214,8 +211,8 @@ latex_elements = {
# (source start file, target name, title, # (source start file, target name, title,
# author, documentclass [howto, manual, or own class]). # author, documentclass [howto, manual, or own class]).
latex_documents = [ latex_documents = [
('index', 'GlanceReleaseNotes.tex', u'Glance Release Notes Documentation', ('index', 'ovsdbappNotes.tex', u'ovsdbapp Release Notes Documentation',
u'Glance Developers', 'manual'), u'ovsdbapp Developers', 'manual'),
] ]
# The name of an image file (relative to this directory) to place at the top of # The name of an image file (relative to this directory) to place at the top of
@ -239,42 +236,5 @@ latex_documents = [
# latex_domain_indices = True # latex_domain_indices = True
# -- Options for manual page output ---------------------------------------
# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
('index', 'glancereleasenotes', u'Glance Release Notes Documentation',
[u'Glance Developers'], 1)
]
# If true, show URL addresses after external links.
# man_show_urls = False
# -- Options for Texinfo output -------------------------------------------
# Grouping the document tree into Texinfo files. List of tuples
# (source start file, target name, title, author,
# dir menu entry, description, category)
texinfo_documents = [
('index', 'GlanceReleaseNotes', u'Glance Release Notes Documentation',
u'Glance Developers', 'GlanceReleaseNotes',
'One line description of project.',
'Miscellaneous'),
]
# Documents to append as an appendix to all manuals.
# texinfo_appendices = []
# If false, no module index is generated.
# texinfo_domain_indices = True
# How to display URL addresses: 'footnote', 'no', or 'inline'.
# texinfo_show_urls = 'footnote'
# If true, do not generate a @detailmenu in the "Top" node's menu.
# texinfo_no_detailmenu = False
# -- Options for Internationalization output ------------------------------ # -- Options for Internationalization output ------------------------------
locale_dirs = ['locale/'] locale_dirs = ['locale/']

View File

@ -23,15 +23,6 @@ classifier =
packages = packages =
ovsdbapp ovsdbapp
[build_sphinx]
source-dir = doc/source
build-dir = doc/build
all_files = 1
warning-is-error = 1
[upload_sphinx]
upload-dir = doc/build/html
[compile_catalog] [compile_catalog]
directory = ovsdbapp/locale directory = ovsdbapp/locale
domain = ovsdbapp domain = ovsdbapp
@ -45,8 +36,3 @@ input_file = ovsdbapp/locale/ovsdbapp.pot
keywords = _ gettext ngettext l_ lazy_gettext keywords = _ gettext ngettext l_ lazy_gettext
mapping_file = babel.cfg mapping_file = babel.cfg
output_file = ovsdbapp/locale/ovsdbapp.pot output_file = ovsdbapp/locale/ovsdbapp.pot
[build_releasenotes]
all_files = 1
build-dir = releasenotes/build
source-dir = releasenotes/source

View File

@ -6,15 +6,9 @@ hacking<0.13,>=0.12.0 # Apache-2.0
coverage!=4.4,>=4.0 # Apache-2.0 coverage!=4.4,>=4.0 # Apache-2.0
python-subunit>=1.0.0 # Apache-2.0/BSD python-subunit>=1.0.0 # Apache-2.0/BSD
sphinx!=1.6.6,!=1.6.7,>=1.6.2,<2.0.0;python_version=='2.7' # BSD
sphinx!=1.6.6,!=1.6.7,>=1.6.2;python_version>='3.4' # BSD
openstackdocstheme>=1.18.1 # Apache-2.0
oslotest>=3.2.0 # Apache-2.0 oslotest>=3.2.0 # Apache-2.0
os-testr>=1.0.0 # Apache-2.0 os-testr>=1.0.0 # Apache-2.0
pylint==1.9.2 # GPLv2 pylint==1.9.2 # GPLv2
stestr>=2.0.0 # Apache-2.0 stestr>=2.0.0 # Apache-2.0
testscenarios>=0.4 # Apache-2.0/BSD testscenarios>=0.4 # Apache-2.0/BSD
testtools>=2.2.0 # MIT testtools>=2.2.0 # MIT
# releasenotes
reno>=2.5.0 # Apache-2.0

View File

@ -31,10 +31,15 @@ commands = python setup.py test --coverage --testr-args='{posargs}'
[testenv:docs] [testenv:docs]
basepython = python3 basepython = python3
commands = python setup.py build_sphinx deps =
-r{toxinidir}/doc/requirements.txt
commands =
sphinx-build -W -b html -d doc/build/doctrees doc/source doc/build/html
[testenv:releasenotes] [testenv:releasenotes]
basepython = python3 basepython = python3
deps =
-r{toxinidir}/doc/requirements.txt
commands = commands =
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html

View File

@ -1,17 +1,17 @@
- project: - project:
templates: templates:
- check-requirements
- openstack-lower-constraints-jobs
- openstack-python-jobs - openstack-python-jobs
- openstack-python3-train-jobs - openstack-python3-train-jobs
- check-requirements - publish-openstack-docs-pti
check: check:
jobs: jobs:
- openstack-tox-lower-constraints
- openstack-tox-functional - openstack-tox-functional
- openstack-tox-functional-py36 - openstack-tox-functional-py36
- ovsdbapp-tempest-dsvm-networking-ovn-ovs-release - ovsdbapp-tempest-dsvm-networking-ovn-ovs-release
gate: gate:
jobs: jobs:
- openstack-tox-lower-constraints
- openstack-tox-functional - openstack-tox-functional
- openstack-tox-functional-py36 - openstack-tox-functional-py36
- ovsdbapp-tempest-dsvm-networking-ovn-ovs-release - ovsdbapp-tempest-dsvm-networking-ovn-ovs-release