o-fl0w / stash-vr

Watch your stash library in VR.
49 stars 8 forks source link

Connections over HTTPS instead of HTTP #2

Closed sharklazerwallo closed 2 years ago

sharklazerwallo commented 2 years ago

Issue: When using stash-vr behind a reverse proxy that forces HTTPS, I'm able to connect to it initially but all metadata that is returned appears to be hardcoded to use HTTP (I believe that it's being done here and here but please correct me if I'm wrong, Go is definitely not my expertise). Using HereSphere, it does not follow the HTTP-to-HTTPS redirect and instead just keeps issuing the requests.

Is it possible to provide an option to allow these URLs to respond with HTTPS? I was able to work around this by opting this specific domain out of the forced redirect but generally prefer operating everything over HTTPS. Thanks again for a great and easy to setup otherwise option to handle VR streaming, was by far the easiest to get going outside of this.

o-fl0w commented 2 years ago

I admire the fact you went for a workaround and I agree - everything https should definitely be possible. Thank you for reporting this.

I've pushed a fix available now from v0.3.15, hopefully this will solve your issue. Please report back if it doesn't and I'll have another look.

o-fl0w commented 2 years ago

New fix out now with v0.3.17 It should autodetect if you're behind a reverse proxy and use https accordingly. Try updating and running without any extra configuration first. If you still have issues you could force https by setting env. var. FORCE_HTTPS="true". Hope this helps.

sharklazerwallo commented 2 years ago

Worked perfectly, no need to use the flag. Thank you so much!