-
Notifications
You must be signed in to change notification settings - Fork 339
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Proxying redis-stat (with nginx) fails #56
Comments
Thanks for the heads up. Sorry that I don't have enough time to maintain this project at the moment. redis-stat web server is just a sinatra app, I don't think there's anything special about it. So you might want to test if it works well with a simple sinatra app running on thin. |
@junegunn In file: redis-stat/lib/redis-stat/server/views/index.erb old: path is web root-relative
new: pls see the dot before the slash making the path web root-relative independent
Difference:
Proxying 1 can not work while 2 does. Would be great if you could incooperate and merge it. BTW: |
Thanks for looking into it. Yeah, a script for setting up a testing environment would be nice. A couple questions:
|
|
ad 1
ad 2
I have tested it and it works. When you proxy to access redis-stat from a subfolder, the href link resolved must be the complete url like |
Thanks for digging those up. Would you be interested in sending me a PR? |
Changes referencing issue junegunn#56 Intention: make redis-stat also working when proxying it. Now you can configure your webserver to act as proxy and access redis-stat via ``your-domain/your-access-page`` This was not possible before due to web-root relative paths in index.erb
Ubuntu 16.04
Having other services proxied wih nginx successfully, it fails with redis-stat.
sudo redis-stat --server --daemon
Accessing via http(s)://domain/redis shows the following screen (proxied setup), but no content:
Doing the same but accessing direct (http://server:63790), without nginx and proxying, works.
Example logs entries:
access log:
"GET /js/site.js HTTP/2.0" 404 210 "https://xxxx/redis/"
error log:
open() "/var/www/xxxx/js/site.js" failed (2: No such file or directory), request: "GET /js/site.js HTTP/2.0"
It tries to access files locally instead of proxying them
Here is the corresponding config. As said, other apps proxied work like a charm
Tried to play with the nginx settings around, but it always ends up with the error messages described above.
The text was updated successfully, but these errors were encountered: