Skip to content

Local Companion App - Exposing local port to remote workspace doens't work #6247

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

Closed
0Grit opened this issue Oct 15, 2021 · 6 comments
Closed
Labels
component: local app meta: stale This issue/PR is stale and will be closed soon team: IDE

Comments

@0Grit
Copy link

0Grit commented Oct 15, 2021

Bug description

image

Steps to reproduce

  1. Start GDB server (Jlinkgdbserver) on port 2331 on local machine

image

  1. PS C:\Users\Grit\Downloads> ./'.\gitpod-local-companion-windows (2).exe' --auto-tunnel=false

  2. PS C:\Users\Grit> ssh -F C:\Users\Grit\AppData\Local\Temp\gitpod_ssh_config -R 2331:localhost:2331 blush-coral-ojk0razu

Port still looks like it's exposed in the opposite direction

image

  1. GDB Fails to connect
    image

[4:02 PM] ila: Yes, as I described the same approach works on Linux but is broken on Windows.

Workspace affected

Not applicable

Expected behavior

GDB client should connect to GDB server

Example repository

https://github.com/gitpod-io/gitpod/tree/main/components/local-app

Anything else?

No response

@ila-embsys
Copy link

I have found where the problem is.

Local Companion App do forward from the remote side to the local side with the right ports but use ipv6. However, in my example OpenOCD app uses ipv4. So the Windows reject the connection.

When I had tried an app that listens to ipv6, everything had working as expected.

@0Grit
Copy link
Author

0Grit commented Oct 16, 2021

@ila-embsys was it ipv6 or the fact that localhost is resolving incorrectly?

@iQQBot
Copy link
Contributor

iQQBot commented Oct 16, 2021

use 127.0.0.1 instead and try

@0Grit
Copy link
Author

0Grit commented Oct 16, 2021

Yes. It worked when I used 127.0.0.1.

@ila-embsys
Copy link

@ila-embsys was it ipv6 or the fact that localhost is resolving incorrectly?

On my system, the hostname "hocalhost" resolves to ipv6 address "::1". So replacing the "localhost" hostname to direct ipv4 address "127.0.0.1" resolves the problem.

@stale
Copy link

stale bot commented Jan 16, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the meta: stale This issue/PR is stale and will be closed soon label Jan 16, 2022
@stale stale bot closed this as completed Jan 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: local app meta: stale This issue/PR is stale and will be closed soon team: IDE
Projects
None yet
Development

No branches or pull requests

4 participants