title: Build completed, but View Docs links broken
body: <p>I have installed a local ReadTheDocs server and think I am very close to having it working.  However, while the build of my documentation project says that it is complete, and I can see the generated files under the readthedocs.org/media/html/cadd-faq/latest directory, the View Docs links from the build page generate a 404 page with the following debugging information.</p>
  <pre><code>Using the URLconf defined in readthedocs.urls, Django tried these URL patterns, in this order:
  
  ^$ [name='homepage'] 
  ^support/ [name='support'] 
  ^security/ 
  ^\.well-known/security.txt$ 
  ^search/$ [name='search'] 
  ^dashboard/ 
  ^profiles/ 
  ^accounts/ 
  ^accounts/ 
  ^notifications/ 
  ^accounts/gold/ 
  ^builds/ 
  ^500/$ 
  ^projects/ 
  ^api/v2/ 
  ^api/v2/docsearch/$ [name='doc_search'] 
  ^api/v2/search/$ [name='search_api'] 
  ^api-auth/ 
  ^api/v3/ 
  ^wipe/(?P&lt;project_slug&gt;(?:[-\w]+))/(?P&lt;version_slug&gt;(?:[a-z0-9A-Z][-._a-z0-9A-Z]*?))/$ [name='wipe_version'] 
  ^i18n/ 
  ^admin/ 
  ^media\/epub(?P&lt;path&gt;.*)$ 
  ^media\/htmlzip(?P&lt;path&gt;.*)$ 
  ^media\/json(?P&lt;path&gt;.*)$ 
  ^media\/pdf(?P&lt;path&gt;.*)$ 
  style-catalog/$ 
  ^media/(?P&lt;remainder&gt;.+)$ [name='media-redirect'] 
  ^__debug__/ 
  
  The current path, docs/cadd-faq/en/latest/, didn't match any of these.
  </code></pre>
  <p>I can manually point my browser at the URL &quot;.../media/html/cadd-faq/latest/index.html&quot; which redirects to &quot;.../static/html/cadd-faq/latest/index.html&quot; and view the sphinx generated content, so the build appears to really have succeeded.  But those pages do not have the ReadTheDocs wrapping content that I would expect the View Docs button to have sent me to, so those URLs are certainly not the right ones either.</p>
  <p>That all would seem to indicate that the problem is with something in my ReadTheDocs and/or Django configuration.  Any pointers to how to resolve the problem would be appreciated.</p>
  <p>So, if you are still with me, just a few comments on my installation.  I believe I faithfully followed the instructions at <a href="https://docs.readthedocs.io/en/stable/custom_installs/local_rtd_vm.html" rel="nofollow noreferrer">https://docs.readthedocs.io/en/stable/custom_installs/local_rtd_vm.html</a> (and associated pages), but of course, I could have blundered, as there were, in retrospect, some serious steps missing.  The extremely helpful, and self answered, instructions at <a href="https://stackoverflow.com/questions/61939886/read-the-docs-local-install-celery-valueerror-signal-only-works-in-main-thread">Read the Docs local install: Celery ValueError: signal only works in main thread</a>, through which I got the redis service and celery workers running, took me at least to a place where I started seeing any progress in the build page for my project.</p>
  <p>Even then, though, I had a few steps to get to a Build Complete result.  First, I had to modify the readthedocs.org/readthedocs/doc_builder/python_environments.py file to allow me to specify an HTTP_PROXY value in my local_settings.py file, and get that sent to the --proxy argument of pip install. (Just setting the environment variables didn't appear to work.)  Second, I had to manually pip install the django-storages package into the readthedocs.org/venv environment.  And third, I had to add a master_doc specification in my sphinx conf.py file to deal with the fact that readthedocs thinks the default sphinx master_doc is contents.rst, but our version of sphinx thinks it is index.rst.</p>
  <p>But that is basically all I did, so I don't see where in my configuration I would have either caused the View Docs links to have the wrong URL, or where I would have removed &quot;^docs/&quot; from the patterns Django is looking for.</p>
  <p>I will be glad to post copies of the configuration files I have, but I am afraid I am not sure what the relevant ones to post would be.  Let me know what files, including the context diff of my python_environments.py code changes, would be helpful in diagnosing my problem, and I will be more than glad to share them here.</p>
  <p>Thanks,
  Malcolm</p>