fab-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Does Fabric work on Windows?


From: Jeff Forcier
Subject: Re: Does Fabric work on Windows?
Date: Wed, 9 Sep 2020 20:03:49 -0400

I know some folks have used Fabric (or more specifically Paramiko; Fabric itself simply wraps Paramiko) to target Windows SSH servers (of which there are at least a few), but it's definitely a minority use case and not one I have personal experience with - which is why I can't give a simple yes/no answer.

SSH itself is entirely shell agnostic, so it really comes down to two aspects of the server software in question:

- How well does it speak the SSH protocol, as implemented by OpenSSH (which is the gold standard and what Fabric/Paramiko are typically tested against). If it does weird things it's more likely to not work well. We unfortunately don't/can't prioritize a platform that has few users and is difficult for us to personally test on.
- What is it actually doing with your commands - is it spawning a bash process (Cygwin, WSL bash, etc), running Powershell, or even running the Windows DOS prompt? This will determine what you want to be sending to it. I assume the SSHD in question will document what it does here.

Finally, there are some minor features in Fabric which assume a Unix shell on the remote end, but these are typically conveniences you can readily work around.

Hope that helps some,
Jeff

On Wed, Sep 9, 2020 at 5:32 PM <chris@cmsconstruct.com> wrote:

I would also be interested if this is the case (or direction).

 

A few years ago when I was looking for a library providing an OS agnostic shell wrapper in Python, I ended up using Fabric for Linux/Unix and writing my own wrapper for PowerShell on Windows.  Now that the open-source version of PowerShell (pwsh) has been out for a while and working on UX variants, I recently had a go at using it.  But the required OS libraries for security models (NTLM/Kerberos/etc) on the different Linux variants… too convoluted for an generic wrapper.

 

My use-case needed to talk to all servers in any customer’s datacenter, without provisioning agents or changing any configurations. I needed to use what was already there, which meant PowerShell (and not SSH) on Windows. FWIW, my purpose was to automate discovery of software application dependencies as input into application/service modeling and monitoring downstream. If it’s helpful, you can see the PowerShell wrapper I created in the Open Content Platform project (github.com/opencontentplatform/ocp).

 

What I found was that OpenSSH was pretty close to being uniform across the Windows and UX variants; heck, it’s even available now in the Features list in recent Server or workstation builds.  But pwsh, which requires OpenSSH at least currently… not close enough for my liking.

 

 

From: Fab-user <fab-user-bounces+chris=cmsconstruct.com@nongnu.org> On Behalf Of Paulo Roberto de Souza Carvalho
Sent: Wednesday, September 9, 2020 2:57 PM
To: fab-user@nongnu.org
Subject: Does Fabric work on Windows?

 

                I ask because on all the pages I entered I only found examples of Unix / Linux commands.



--
Jeff Forcier
Unix sysadmin; Python engineer
http://bitprophet.org

reply via email to

[Prev in Thread] Current Thread [Next in Thread]