Add docs-linkchecker to validate external links 43/39443/1
authorThanh Ha <thanh.ha@linuxfoundation.org>
Wed, 25 May 2016 19:48:36 +0000 (15:48 -0400)
committerThanh Ha <thanh.ha@linuxfoundation.org>
Wed, 25 May 2016 19:48:48 +0000 (15:48 -0400)
Change-Id: I0e030e1fb48adef8973528235ab3f311e56d0980
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
docs/conf.py
tox.ini

index 2c112bd308bede5da20defeaccf8c86b43d0302b..c11a826211fe4909c8ef22f350e1ab0a2df90d41 100644 (file)
@@ -285,3 +285,13 @@ texinfo_documents = [
 
 # If true, do not generate a @detailmenu in the "Top" node's menu.
 #texinfo_no_detailmenu = False
+
+
+linkcheck_ignore = [
+    # Ignore jenkins because it's often slow to respond.
+    'https://jenkins.opendaylight.org/releng',
+    'https://jenkins.opendaylight.org/sandbox',
+    'http://\$CONTROL_HOST:8181/dlux/index.html',
+    # The '#' in the path makes sphinx think it's an anchor
+    'https://git.opendaylight.org/gerrit/#/admin/projects/releng/builder',
+]
diff --git a/tox.ini b/tox.ini
index ee12e8ea750cc4a09155fb84d7ede57cc393d276..8ea4ee5b132235515b91bf8559d371dd9d33fefc 100644 (file)
--- a/tox.ini
+++ b/tox.ini
@@ -1,8 +1,12 @@
 [tox]
 minversion = 1.6
-envlist = docs
+envlist = docs,docs-linkcheck
 skipsdist = true
 
 [testenv:docs]
 deps = sphinx
-commands = sphinx-build -b html -d {envtmpdir}/doctrees ./docs/ {envtmpdir}/html
+commands = sphinx-build -b html -n -d {envtmpdir}/doctrees ./docs/ {envtmpdir}/html
+
+[testenv:docs-linkcheck]
+deps = sphinx
+commands = sphinx-build -b linkcheck -d {envtmpdir}/doctrees ./docs/ {envtmpdir}/linkcheck