Also worth noting that you can fix that redirect. It has to do with your "proxy_redirect" or "ProxyPassReverse" or whatever the analog is called in apache-land. Alternatively, by setting headers X-Forwarded-Proto: https and Host: yourhostname.com , RStudio might issue better redirects for you.
Proxy rewrites and such can get to be tricky / painful, but it definitely is possible to rewrite / catch redirects. This is a common / important feature for proxies like Apache and nginx.