vscode-remote-release
vscode-remote-release copied to clipboard
Remote-Containers Podman should make SSH-agent forwarding optional
Related Issue: https://github.com/microsoft/vscode-remote-release/issues/6747
When attempting to use Podman-Remote on a Windows system via the Remote-Containers plugin, I run into the following error: Error: unable to connect to Podman. failed to create sshClient: dial unix \\.\pipe\openssh-agent: connect: No connection could be made because the target machine actively refused it.
Outside of VSCode, I have no problems because SSH_AUTH_SOCK is unset (ssh-agent-forwarding is disabled due to permissions running ssh-agent in corporate environment).
On seeing this comment, I realized VSCode automatically sets SSH_AUTH_SOCK if not defined: https://github.com/microsoft/vscode-remote-release/issues/6747#issuecomment-1143388515. This puts a requirement on ssh-agent forwarding I think. Note, this same problem doesn't affect Docker.
- VSCode Version: 1.68.1
- Local OS Version: Windows 10
- Remote OS Version: Oracle Linux Server release 8.6
- Remote Extension/Connection Type: Containers (Podman)
- Logs:
[13406 ms] Remote-Containers 0.241.3 in VS Code 1.68.1 (30d9c6cd9483b2cc586687151bcbcd635f373630)
[13406 ms] Start: Run podman version --format {{.Server.APIVersion}}
[14972 ms] Stop (1566 ms): Run: podman version --format {{.Server.APIVersion}}
[14975 ms] Cannot connect o Podman. Please verify your connection to the Linux system using `podman system connection list` or try `podman machine init` and `podman machine start` to manage a new Linux VM
Error: unable to connect to Podman. failed to create sshClient: dial unix \\.\pipe\openssh-agent: connect: No connection could be made because the target machine actively refused it.
Steps to Reproduce:
- Install podman-v4.1.0.msi
- Set Docker Path to podman: "remote.containers.dockerPath": "podman"
- Disable your local ssh-agent.
- Try to connect using Remote - Containers
In my case, I set RemoteCommand in ~/.ssh/config for another plugin, which caused the problem about SSH.
If unset this setting, Remote Container(v0.251.0) with Podman(4.1.1) in remote server worked.
@pwolf15 - can you verify that this now works on the latest insiders and pre-release of the remote extension?