-
Notifications
You must be signed in to change notification settings - Fork 843
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs: Add security.md to readthedocs #90
Conversation
This enables the ability to show the security policy on both GitHub and on the readthedocs site. To do this, enable the ability to import Markdown based files and translate them to rst.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple of inline questions.
doc/rtd/conf.py
Outdated
'sphinx.ext.autodoc', | ||
'sphinx.ext.autosectionlabel', | ||
'sphinx.ext.viewcode', | ||
] | ||
|
||
# The suffix of source filenames. | ||
source_suffix = '.rst' | ||
source_suffix = ['.rst', '.md'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As we're explicitly including SECURITY.md
by path in security.rst
, do we need to expand this list?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It appears we do not. I was following the steps on the m2r site when I added this, but it looks like the import handles this for us.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reverted in latest push
tox.ini
Outdated
@@ -56,6 +56,7 @@ exclude = .venv,.tox,dist,doc,*egg,.git,build,tools | |||
basepython = python3 | |||
deps = | |||
doc8 | |||
m2r |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think ReadTheDocs uses tox
to generate the docs; do we need to put m2r
somewhere else too, so that RTD will install it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah good catch. It appears that sphinx can use a requirements.txt file or a conf.py [1]. Today we point at the requirements.txt file so cloud-init can be installed, which seems unnecessary.
I think a doc-requirements.txt file makes sense and having tox point at that like we do for integration and tests. I'll then update readthedocs look for that file.
[1] https://docs.readthedocs.io/en/stable/guides/specifying-dependencies.html#
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added the doc-requirements.txt in latest push
Also removes the extra, uncessary extension addition of .md
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
(A bit of me wonders if specifying a requirements file might cause issues with the cloudinit imports we do in conf.py
and with the autodoc stuff, but I think the only reasonable way to find out is to merge this and see what happens.)
This enables the ability to show the security policy on both GitHub and
on the readthedocs site. To do this, enable the ability to import
Markdown based files and translate them to rst.