Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Hi, I've tried setting up weave-minimal but ran into a problem with the webserver proxy configuration. I'm using an SSL-only lighttpd with mod_proxy, but cannot get it to even sync the very first time. What happens is that the user gets created, but no data is uploaded. The last thing that happens is that the URL https://serverurl/weave/user/1.0/l2u3gb3gp56neugnzzwnpfl3exkexikf/node/weave is fetched from the server - after that, the log in Firefox shows the authentication failing and nothing happens.
I think this is because the above URL returns the string "http://serverurl/weave/" - note that the S is missing from httpS. So something inside my setup returns the wrong URL, which is afterwards ends up in Firefox's pref.js as the services.sync.clusterURL option and sync fails.
I was not able to find the point at which this happens in the weave-minimal code; I don't know if this is a bug in werkzeug or lighttpd or some wrong configuration on my part. Any help would be appreciated.
Can you please post your lighttpd configuration (related parts)? I think, it has something to do with the headers, that lighttpd does not pass to the backend (such as Host and X-Scheme). Without these headers, the backend does not know on which public url it runs:
curl -4 https://posativ.org/weave/user/1.0/dbxv2a5gbfgkdkhvbv6xnoebmt2dkye2/node/weave https://posativ.org/weave/
In contrast to something like this:
curl -4 https://serverurl/weave/user/1.0/l2u3gb3gp56neugnzzwnpfl3exkexikf/node/weave http://localhost:1234/
Appearently you do this with
The lighttpd configuration might just need this:
setenv.add-response-header = ( "X-Forwarded-For" => "https://serverurl/path/") # or maybe even server.name
Please report back, what environment variables are working and I will add them to the README!
Thanks. I fiddled around with this a bit and it turns out that I only need to add the X-Scheme; to the request header and not the response header, though. Like this: