Skip to main content

A new and modern SSH connector written in Python.

Project description

bitssh

GitHub issues GitHub forks GitHub stars GitHub license Open Source Love svg1 PRs Welcome contributions welcome GitHub contributors

A New and Modern SSH connector written in Python.

Terminal user interface for SSH. It uses ~/.ssh/config to list and connect to hosts.

Demo

Installation

Install bitssh with docker

  docker run --rm -it -v ~/.ssh:/root/.ssh mrsunglasses/bitssh:latest	

Install bitssh with uvx (recommended)

  uvx bitssh

Install bitssh with uv tool (recommended)

  uv tool install bitssh

Install bitssh with pip (no recommended)

  pip3 install bitssh

  bitssh

Install from source

  git clone https://github.com/Mr-Sunglasses/bitssh

  cd bitssh

  python3 -m pip3 install -e .

  bitssh

Usage

Connecting to a Host

Simply run bitssh to see all your SSH hosts and connect to one:

bitssh

This displays a table of all hosts from ~/.ssh/config and launches a fuzzy search prompt to select a host. Once selected, bitssh opens an SSH connection to that host.

Check Version

bitssh -v
bitssh --version

Adding a Host

Interactive mode (guided prompts):

bitssh add

Non-interactive mode (CLI flags):

bitssh add --host myserver --hostname 192.168.1.1
bitssh add --host myserver --hostname 192.168.1.1 --user root --port 2222
bitssh add --host myserver --hostname 192.168.1.1 --user admin --identity-file ~/.ssh/id_rsa
Flag Description
--host Alias for the SSH connection (required)
--hostname IP address or domain (required)
--user Login username
--port SSH port (default: 22)
--identity-file Path to private key file

Removing a Host

Interactive mode (multi-select prompt):

bitssh remove

Non-interactive mode (specify one or more hosts):

bitssh remove --host myserver
bitssh remove --host srv1 srv2

SSH Config Reference

bitssh reads hosts from ~/.ssh/config. Example configuration:

Host myserver
    Hostname 192.168.1.1
    User admin
    Port 22

Host production
    Hostname ec2-xxx-xxx-xxx-xxx.compute-1.amazonaws.com
    User ubuntu
    Port 22
    IdentityFile ~/.ssh/aws-key.pem

See the OpenBSD ssh_config reference for all available options.

Troubleshooting

[...]/.ssh/config: no such file or directory

  • Check if you have ~/.ssh/config file
  • If you don't, create it with touch ~/.ssh/config

Here's a sample ~/.ssh/config file that is recognized by bitssh:

Host abc
	Hostname xxx.xx.xx.xx
	User test1
	port 22

Host pqr
	Hostname ec2-xxx-xxx-xxx-xxx.compute-1.amazonaws.com
	User ubuntu
	port 22

Host wxy
	Hostname xxx.xx.xxx.xx
	User test2
	port 22

You can check the OpenBSD ssh_config reference for more information on how to setup ~/.ssh/config.

Contributing

Contributions are always welcome!

See CONTRIBUTING.md for ways to get started.

Please adhere to this project's code of conduct.

Authors

License

MIT

💪 Thanks to all Wonderful Contributors

Thanks a lot for spending your time helping bitssh grow. Thanks a lot! Keep rocking 🍻

Contributors

🙏 Support++

This project needs your shiny star ⭐. Don't forget to leave a star ⭐️

forthebadge made-with-python forthebadge

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bitssh-3.7.0.tar.gz (18.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bitssh-3.7.0-py3-none-any.whl (12.2 kB view details)

Uploaded Python 3

File details

Details for the file bitssh-3.7.0.tar.gz.

File metadata

  • Download URL: bitssh-3.7.0.tar.gz
  • Upload date:
  • Size: 18.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for bitssh-3.7.0.tar.gz
Algorithm Hash digest
SHA256 67bcafe2c1d23e1f9b4b5afe6fa8918cc120d9787ea4a446aebd686069725592
MD5 bf153884b51fb334332942080122c41e
BLAKE2b-256 65351b502bfaaf85c686a58d09c14fd9e5f00e2d587c60dcacb0b42168d1d028

See more details on using hashes here.

File details

Details for the file bitssh-3.7.0-py3-none-any.whl.

File metadata

  • Download URL: bitssh-3.7.0-py3-none-any.whl
  • Upload date:
  • Size: 12.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for bitssh-3.7.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3b234bdc00a0da7e3135492a64faf72553094b69f6b23a736c1e409e41e24791
MD5 17a16fe3a66159b211b3143d4bab3743
BLAKE2b-256 bd7069ee9d20bb46223c2edea13e03d29d5a3300e03bf3352bca85b1be640c9a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page