poiuytrez
poiuytrez

Reputation: 22518

Password protect readthedocs.org documentation

I have a documentation managed on readthedocs.org. Is there a way to password protect or at least make our documentation available only for some of our customers?

Upvotes: 3

Views: 1969

Answers (2)

bergercookie
bergercookie

Reputation: 2760

This is actually available nowadays in the business edition of readthedocs. You can read more about it in the following pages:

  1. https://docs.readthedocs.io/en/stable/commercial/sharing.html
  2. https://about.readthedocs.com/pricing/

Pasting verbatim from the first page I linked:

Go into your project’s Admin page and click on Sharing.

Click on New Share

Select access type (secret link, password, or HTTP header token), add an expiration date and a Description to help with managing access in the future.

Check Allow access to all versions? if you want to grant access to all versions, or uncheck that option and select the specific versions you want grant access to.

Click Save.

Get the info needed to share your documentation with other users:

    Secret link: copy the link that is generated

    Password: copy the link and password

    HTTP header token: Copy the token, and then pass the Authorization header in your HTTP request.

Give that information to the person who you want to give access.

Upvotes: 0

Zach Cook
Zach Cook

Reputation: 614

Unfortunately, docs hosted on Read The Docs cannot be password-protected.

The best you can do (as of now) is to set your documentation to "Private" which will show users a 404 when they navigate to your docs from the www.readthedocs.org website. However, this is extremely weak security as anyone with the actual url can still view your documentation.

From their documentation:

With a URL to view the actual documentation, even private docs are viewable. This is because our architecture doesn’t do any logic on documentation display, to increase availability.

However, you could just host the Sphinx generated documentation yourself, and that you could password protect. I would say that is definitely your best bet!

Read the Docs is really just a convenience hosting service, you can still host your documentation elsewhere, and then easily password protect it just like you would password protect anything else.

Update

Btw, the easiest way to do that is to just generate generate static .html files - using make html from the root folder. Put those HTML files up on an internally hosted web server and you're good :)

Upvotes: 4

Related Questions