Update docs building

Update docs building:
* Switch to sphinx-build
* Update requirements for Sphinx and openstackdocstheme for
  python 3, create doc/requirements.txt file.
* Remove unneeded doc and translation sections from setup.cfg
* Remove install_command, it's unneeded, the default is fine.
* Use TOX_CONSTRAINTS instead of obsolete UPPER_CONSTRAINTS

Change-Id: I6ff4427014fc967a6f7b28fc6cbe5a0f4eca601c
This commit is contained in:
Andreas Jaeger 2020-05-03 11:18:36 +02:00
parent eb7be57a14
commit 7e2d6f2292
4 changed files with 9 additions and 16 deletions

4
doc/requirements.txt Normal file
View File

@ -0,0 +1,4 @@
sphinx>=2.0.0,!=2.1.0 # BSD
openstackdocstheme>=2.0.0 # Apache-2.0
reno>=2.5.0 # Apache-2.0

View File

@ -24,11 +24,3 @@ packages =
[entry_points]
tempest.test_plugins =
ironic_tests = ironic_tempest_plugin.plugin:IronicTempestPlugin
[build_sphinx]
source-dir = doc/source
build-dir = doc/build
all_files = 1
[upload_sphinx]
upload-dir = doc/build/html

View File

@ -7,8 +7,3 @@ hacking>=3.0.0,<3.1.0 # Apache-2.0
stestr>=1.0.0 # Apache-2.0
coverage!=4.4,>=4.0 # Apache-2.0
flake8-import-order>=0.17.1 # LGPLv3
sphinx!=1.6.6,!=1.6.7,>=1.6.2 # BSD
openstackdocstheme>=1.20.0 # Apache-2.0
reno>=2.5.0 # Apache-2.0

View File

@ -7,11 +7,10 @@ ignore_basepython_conflict=true
[testenv]
basepython = python3
usedevelop = True
install_command = pip install {opts} {packages}
setenv =
VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
deps = -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
deps = -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/test-requirements.txt
commands = stestr run --slowest {posargs}
@ -32,9 +31,12 @@ commands =
coverage xml -o cover/coverage.xml
[testenv:docs]
commands = python setup.py build_sphinx
deps = -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
commands = sphinx-build -W -b html doc/source doc/build/html
[testenv:pdf-docs]
deps = {[testenv:docs]deps}
whitelist_externals = make
commands = sphinx-build -b latex doc/source doc/build/pdf
make -C doc/build/pdf