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

forwarded_port feature with SSH tunneling does not work #1439

Closed
BerkhanBerkdemir opened this issue Jan 22, 2022 · 4 comments
Closed

forwarded_port feature with SSH tunneling does not work #1439

BerkhanBerkdemir opened this issue Jan 22, 2022 · 4 comments
Labels

Comments

@BerkhanBerkdemir
Copy link

Hello,

I have been using vagrant-libvirt for 2 years without issue. Recently, I wanted to use forwarded_port feature. In the backend it uses SSH, but I had no chance to make it work. When I reach localhost:3000, I get a log file that only shows multiple of this line

channel 2: open failed: connect failed: Connection refused

I use Vagrant 2.2.3 with vagrant-libvirt 0.0.45 on Debian Buster. Current Vagrantfile what is created after vagrant init with removing comment line of the forewarded_port.

@electrofelix
Copy link
Contributor

Please update the version of vagrant-libvirt being used, 0.0.45 was release in 2018 and there has been a lot of work done on improving the forwarding behaviour. Try retesting with 0.7.0

@ProjectInitiative
Copy link

ProjectInitiative commented Mar 17, 2022

I am not sure if this is the same issue, but it is similar. Running 0.7.0, the port forwarding works if a vagrant command is running. For instance, if I have a 5 VM cluster and I run vagrant reload, the tunnel is active and the port is forwarded until the full reload is complete. After vagrant exits, all ports and tunnels get dropped. I have tried with a bare metal install and the docker container, identical behavior with both.

@electrofelix
Copy link
Contributor

It's likely that port forwarding using the docker container would need to leave the container running as docker stopping will terminate and child processes started from within the container. No way around that.

I can't reproduce with a native install though and that would be different to this issue anyway as this is a out some failure to connect the forwarded port by the background ssh process that is running while you are saying it doesn't remain running at all

@no-response
Copy link

no-response bot commented Mar 23, 2022

This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take action. Please reach out if you have or find the answers we need so that we can investigate further.

@no-response no-response bot closed this as completed Mar 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants