Skip to main content

Some AWS CLI commands with a beautiful TUI

Project description

cloudsnake 🐍

Wrapping some useful AWS cli commands to operate AWS like EC2 SSM instance connection or RDS connection using IAM authentication


pre-commit GitHub code size in bytes GitHub last commit GitHub issues GitHub pull requests GitHub Repo stars GitHub watchers Python version PyPiP version License Linter


In your terminal, set the corresponding AWS_PROFILE=MyProfile if not using the default. (~/.aws/credentials). Copy this helper function called aws-profile into your favourite shell (.bashrc, .zshrc, ~/.config/fish/function) to easily switch between AWS profiles. In case of using fish shell, use this other function.



SSM session

aws-profile




SSM session

SSM session

Install the REQUIRED plugin to use SSM sessions.

cloudsnake ssm start-session -is # will print all your instances in a terminal menu
cloudsnake ssm start-session --target i-XXXXXX  # connect to the instance specifying the target id



SSM get parameter

SSM parameter

cloudsnake ssm get-parameter # default region eu-west-1
cloudsnake --region us-east-1 ssm get-parameters # specify region



SSO get-credentials

SSO get-credentials

cloudsnake --region eu-west-1 sso get-credentials --start-url https://myapp.awsapps.com/start

[!NOTE] This command will open your default browser. You will need to approve manually the authentication. More use cases and examples for cloudsnake sso get-credentials can be found in docs/sso-get-credentials.md.

Installation

Using pipx (Recommended)

Install pipx with your system package manager (apt, dnf, pacman...).

pipx install cloudsnake

Using pip

pip3 install cloudsnake

[!WARNING] Probably your system will not allow this installation method due to a broken system package.

Example error
Error:

error: externally-managed-environment

× This environment is externally managed ╰─> To install Python packages system-wide, try 'pacman -S python-xyz', where xyz is the package you are trying to install.

If you wish to install a non-Arch-packaged Python package,
create a virtual environment using 'python -m venv path/to/venv'.
Then use path/to/venv/bin/python and path/to/venv/bin/pip.

If you wish to install a non-Arch packaged Python application,
it may be easiest to use 'pipx install xyz', which will manage a
virtual environment for you. Make sure you have python-pipx
installed via pacman.

note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages. hint: See PEP 668 for the detailed specification.

Uninstall

pipx uninstall cloudsnake
# or
pip3 uninstall cloudsnake

Debug AWS SDK API calls

cloudsnake --log-level debug command subcommand [options]

License

cloudsnake is distributed under the terms of the GPL3 license.

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

cloudsnake-0.8.0.tar.gz (31.9 kB view details)

Uploaded Source

Built Distribution

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

cloudsnake-0.8.0-py3-none-any.whl (33.3 kB view details)

Uploaded Python 3

File details

Details for the file cloudsnake-0.8.0.tar.gz.

File metadata

  • Download URL: cloudsnake-0.8.0.tar.gz
  • Upload date:
  • Size: 31.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.13.9 Darwin/25.1.0

File hashes

Hashes for cloudsnake-0.8.0.tar.gz
Algorithm Hash digest
SHA256 c628ce94e1d6c164012831f97b44b33a47b3dee4653dc17929ace142008daa86
MD5 d03ebc9efc5c58d8209bfe2475ec8b23
BLAKE2b-256 b0671bff55857bc991d4068d26c2b81aefe1ce7d1f8ab99cfaba1b45f2861104

See more details on using hashes here.

File details

Details for the file cloudsnake-0.8.0-py3-none-any.whl.

File metadata

  • Download URL: cloudsnake-0.8.0-py3-none-any.whl
  • Upload date:
  • Size: 33.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.13.9 Darwin/25.1.0

File hashes

Hashes for cloudsnake-0.8.0-py3-none-any.whl
Algorithm Hash digest
SHA256 61f5798090a1d46806353a60ba189edc5e3c017361042b9a0ea3441a5505ef67
MD5 181daeb489dfb8b44ee2fba5117468a9
BLAKE2b-256 0ed3789487f364b05ab23a3cddf03aae43a310057834136ddfe955c27a21e8d4

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