--- id: fabric2 version: "3.2.3" license: BSD license_treatment: permissive maintenance: active --- # fabric2 — High level SSH command execution License: permissive · Maintenance: active · Downloads: 98.3K/mo ## What it is and what it does Fabric is a Python library for executing shell commands on remote systems over SSH. It wraps Invoke (for local subprocess and CLI features) and Paramiko (for SSH protocol) into a unified API that lets you write Python code to automate system administration, deployment, and orchestration tasks across multiple servers. You define tasks in Python, connect to remote hosts via SSH, run commands, and capture their output as Python objects. This makes it natural to script complex multi-host operations, error handling, and conditional logic in Python rather than shell scripts. The library is actively maintained, has no known vulnerabilities, and supports modern Python versions across Linux, macOS, and Windows. Use it for: - Deploy applications to production servers by running remote build, test, and install commands over SSH. - Automate system administration tasks like user provisioning, log rotation, or service restarts across a fleet of servers. - Orchestrate multi-step workflows that require conditional logic and error handling across multiple remote hosts. - Run ad-hoc commands on remote systems and capture output for monitoring, auditing, or reporting. - Build custom deployment pipelines that integrate with your Python codebase and CI/CD workflows. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Fabric executes shell commands remotely over SSH and returns Python objects, building on Invoke and Paramiko to provide a high-level interface for remote command execution and system administration tasks. Yes. Fabric is a mature, actively maintained library with no known vulnerabilities, low install friction, and a permissive license. It is the standard choice for Python-based SSH automation and remote command execution. Install it if you need to automate tasks across remote systems from Python code. ## Install pip install fabric2 uv add fabric2 poetry add fabric2 ## Installing fabric2 Before you install: Low install friction with a pure-Python wheel distribution. The package is actively maintained with a recent commit history and carries four straightforward runtime dependencies (invoke, paramiko, decorator, deprecated), all of which are well-established libraries. License in practice: Licensed under BSD (permissive), so you can use Fabric in commercial and proprietary projects without restriction, though you must include the license notice in distributions. Quickstart: pip install fabric2 from fabric import Connection conn = Connection('user@example.com') result = conn.run('ls -la') print(result.stdout) Requires SSH access to a remote host; the remote system must have a shell available for command execution. Verify before relying: - Whether Python 2.7 support mentioned in the description excerpt is still active in version 3.2.3 or has been dropped. - Specific performance characteristics or limits for concurrent remote command execution. ## Package facts - License: BSD (permissive) - Python support: unspecified - Install friction: low - Maintenance: active - Downloads: 98.3K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags remote ssh command execution, python ssh library, remote server automation, fabric deployment tool, ssh task runner, paramiko wrapper, remote shell commands, ssh-automation, deployment, systems-administration [View on SkillFed](https://skillfed.io/packages/fabric2) · [View on PyPI](https://pypi.org/project/fabric2/)