Reputation: 51
I have connected two clients via ssh remote tunneling to my cloud server. Testing via netcat confirms , both tunnels are correctly installed - communication between each client and server is working pretty fine - in both directions.
Now I want to connect both clients directly via nginx stream (tcp) on my server. I have used this stream configuration:
# TCP-forwarding to Client 1 (Port 5998)
server {
listen 9001;
# proxy_pass localhost:5999;
proxy_pass 127.0.0.1:5999;
proxy_timeout 10m;
proxy_connect_timeout 1m;
}
# TCP-forwarding to Client 2 (Port 5998)
server {
listen 9000;
# proxy_pass localhost:5998;
proxy_pass 127.0.0.1:5998;
proxy_timeout 10m;
proxy_connect_timeout 1m;
}
Involved ports 9000 and 9001 are visible (up)!
Although the "partial" ssh tunneled tcp communication between Server and clients is fine in both directions, this configuration doesn't close both tunnel halves at the server ...!
Do I have a basic misunderstanding of nginx stream (tcp) capabilities or it a configuration error only?
Any help is appreciated! Thanks!
Upvotes: 0
Views: 62