Skip to content
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

ReverseProxy read error when serving index.html from /public #57

Open
kylekeesling opened this issue Dec 4, 2024 · 0 comments
Open

Comments

@kylekeesling
Copy link

I'm having an issue when attempting to serve a file from the Rails public folder when using kamal with thruster.

I have a javascript library that requires me to copy assets to the Rails public folder so it can be accessed via the code. The path is: https://tools-demo.passtesting.com/webviewer/ui/index.html, but I get a 5xx error when attempting to access it.

When tailing the proxy logs (kamal proxy logs) I see a 301 response and then: httputil: ReverseProxy read error during body copy: unexpected EOF

When I access it as a directory (https://tools-demo.passtesting.com/webviewer/ui/) it loads as expected. The problem is that the library has a hardcoded reference to index.html instead of referring to the path, so I currently have no way to mitigate this.

The problem appears to be solved when I disable X-Sendfile (X_SENDFILE_ENABLED=false).

Ideally I'd like to keep this enabled for all of its other benefits, but is fully disabling X-Sendfile the only solution here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant