-
Notifications
You must be signed in to change notification settings - Fork 183
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
nginx: stream error received: unspecific protocol error detected #27
Comments
Adding this to the server section seems to fix it: location /sshx.SshxService/Channel {
grpc_pass grpc://127.0.0.1:8051;
} |
Yep, this directive fixes the issue. Thanks a lot! Maybe we should add the working |
release]$ ./sshx --server https://localhost:8003 Caused by: As per your suggestion i was changed the below line of code in cargo.toml file still i am getting certificate error message.
|
Yes, you'll have to Actually on the server it internally just checks if the content-type is sshx/crates/sshx-server/src/listen.rs Lines 51 to 60 in e01b75a
To clarify, you don't necessarily need to detect gRPC when you're putting a reverse proxy in front of sshx. You just need to forward HTTP/2 connections to it as the backend protocol. But Nginx doesn't let you do h2c (HTTP/2 cleartext) backend for its reverse proxy; it only has Sorry about this, Nginx is just eternally difficult to configure 😅 |
this is what i have in my nginx.conf . I am still facing certificate issue. would you mind sharing your nginx setup @shumvgolove $ ./sshx --server https://localhost:8002 Caused by: `events {} pid nginx.pid; http {
} |
Thanks for your guide, my problem is solved. By the way, self signed cert need to add into keychain in Mac OS |
Hey 👋 and thanks for the great project!
After several attempts to figure out how to make it work with
nginx
reverse-proxy, I've created half-working solution. I am providing below steps to reproduce the issue and ultimately figure out what is the problem.sshx-server
setupsshx
repository:npm ci && npm run build
sshx
(which will also serve frontend).:nginx
setupnginx.conf
with the following content:mkcert
(otherwise grpc/websockets won't work) and assign correct permissions:nginx
:sshx
setupThe default
sshx
binaries won't work, becausetonic
is compiled withtls-webpki-roots
feature, which means thatsshx
will not lookup OSca-certificates
bundle, making our self-signed certificates useless and throwing the following error:In order to fix that we need to recompile
sshx
binary withtls-roots
feature (which will lookup OS ca-certificates):sshx
cloned git repository:cd /tmp/reproduce-issue/sshx
tonic_fix.patch
:and apply it like so:
sshx
:Now, here's the issue: there's no connection between server and shell and I'm unable to spawn terminal:
And once in a while
sshx
produces the following log:Here's the log with
RUST_LOG=trace
: trace_sshx.logAny help would be much appreciated!
The text was updated successfully, but these errors were encountered: