Proxito: handle http to https redirects for all requests (#10199)
In order to be able to cache the redirects,
I had to refactor some of our code
(and kind of a little in the direction of https://github.com/readthedocs/readthedocs.org/issues/10124).
Closes https://github.com/readthedocs/readthedocs.org/issues/10144