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

Having issues with windows client #174

Open
rcastberg opened this issue Sep 1, 2016 · 4 comments
Open

Having issues with windows client #174

rcastberg opened this issue Sep 1, 2016 · 4 comments
Labels
Milestone

Comments

@rcastberg
Copy link

assh doesn't seem to want to do anything for the windows client, i have a feeling this might be the ssh path that is messing this up. Any advice would be appreciated.

$ assh -V -D wrapper ssh testcase
time="2016-09-01T14:58:51+02:00" level=debug msg="Wrapper called with bin=C:\cygwin64\bin\ssh.exe target=testcase command=[] options=[], args=[ssh testcase]"
time="2016-09-01T14:58:51+02:00" level=debug msg="Loading config file 'C:\cygwin64\home\user/.ssh/assh.yml'"
time="2016-09-01T14:58:51+02:00" level=debug msg="Loaded config file 'C:\cygwin64\home\user/.ssh/assh.yml' (0 + 1 => 1 hosts)"
time="2016-09-01T14:58:51+02:00" level=debug msg="The configuration file is outdated, rebuilding it before calling ssh"
time="2016-09-01T14:58:51+02:00" level=debug msg="Writing SSH config file to "C:\cygwin64\home\user/.ssh/config""

And it returns to the shell here with no attempt at connecting to the server.

assh.yml:
$ cat .ssh/assh.yml
hosts:
testcase:
Hostname: test.test.org
User : testuser

@rcastberg
Copy link
Author

I think i tracked down the problem. It seems that the ssh binary isn't being called correctly in the cygwin console.

When i went into .ssh/config and manually changed the proxycommand to /usr/bin/assh.exe, instead of c:\cygwin\usr\bin\assh.exe it worked fine.

I then tried changing the ASSHBinaryPath:, but it seems it is being translated into windows format shown above.

@moul moul self-assigned this Dec 4, 2016
@moul moul added the ready label Dec 6, 2016
@moul moul modified the milestone: v2.6.0 Jan 5, 2017
@moul moul modified the milestones: v2.6.0, v2.7.0 Feb 3, 2017
@moul moul removed their assignment Sep 18, 2017
@jeffrey4l
Copy link

have the exactly same issue.

@jeffrey4l
Copy link

I use a shell script for workaround

#!/bin/bash -xe

assh.exe config build > ~/.ssh/config

sed -i 's/  ProxyCommand D:.*/  ProxyCommand assh connect --port=%p %h/g' ~/.ssh/config

@moul moul modified the milestones: v2.7.0, v2 ✌ Jun 7, 2020
@wrecklass
Copy link

Yep, I have found on Windows that ASSHBinaryPath does not do the right thing. When it is on Windows it always translates the path to a Windows-based path. I had hoped it would allow you to actually specify an alternative path, precisely as you needed it. Which doesn't seem to be what it is there for.

I've created my own config build script "wrapper" to handle the process for me if it helps:

assh config build | sed -e 's#[CD]:\\cygwin64##' -e 's#\\#/#g' > "$HOME/.ssh/config"

Note the first Regex is to change either C: or D: as I use assh on different machines with Cygwin installed on different drives.

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

4 participants