@schematichq/taskonaut v1.6.0
taskonaut
░██████╗░█████╗░██╗░░██╗███████╗███╗░░░███╗░█████╗░████████╗██╗░█████╗░
██╔════╝██╔══██╗██║░░██║██╔════╝████╗░████║██╔══██╗╚══██╔══╝██║██╔══██╗
╚█████╗░██║░░╚═╝███████║█████╗░░██╔████╔██║███████║░░░██║░░░██║██║░░╚═╝
░╚═══██╗██║░░██╗██╔══██║██╔══╝░░██║╚██╔╝██║██╔══██║░░░██║░░░██║██║░░██╗
██████╔╝╚█████╔╝██║░░██║███████╗██║░╚═╝░██║██║░░██║░░░██║░░░██║╚█████╔╝
╚═════╝░░╚════╝░╚═╝░░╚═╝╚══════╝╚═╝░░░░░╚═╝╚═╝░░╚═╝░░░╚═╝░░░╚═╝░╚════╝░
Interactive CLI tool for exec into AWS ECS tasks (containers) - from SchematicHQ
taskonautis a combination of "Task" (ECS tasks) and "Astronaut" We followed Command Line Interface Guidelines, An open-source guide to help you write better command-line programs, taking traditional UNIX principles and updating them for the modern day.
Features
- 🔐 AWS SSO authentication support
- 🚀 Interactive cluster selection
- 📦 Task listing and selection
- 🐳 Container execution
- ⚙️ Profile and region management
- 💾 Persistent configuration
- 🎨 Beautiful CLI interface
- 📍 Navigation between clusters, tasks, and containers.
Prerequisites
!WARNING Make sure you have met the Amazon ECS Exec prerequisites.
- Node.js 18+
- AWS CLI v2
- AWS Session Manager Plugin
- AWS credentials configured (supports AWS SSO, access keys, etc.)
Installation
npm install -g @schematichq/taskonautUsage
# Configure AWS profile and region
taskonaut config set
# Show current configuration
taskonaut config show
# Clear configuration
taskonaut config cleanup
# Run diagnostics to check environment setup
taskonaut doctor
# Start interactive session
taskonautCommand Line Options
Usage: taskonaut [options] [command]
✨ Interactive ECS task executor
Options:
-h, --help display help for command
Commands:
config Manage configuration settings
doctor Run diagnostics to check your environment setupConfiguration
Configuration is stored in:
- macOS:
~/Users/$USER/Library/Preferences/taskonaut-nodejs - Linux:
~/.config/taskonaut-nodejs - Windows:
%APPDATA%\taskonaut-nodejs
AWS authentication
aws sso login
aws sso login --porfile PORFILE_NAME
taskonautassume
- TBD
vault
- TBD
Troubleshooting (macOS)
!CAUTION Error messages:
Task not found: Ensure the ECS task is runningContainer not found: Task may have zero containersInvalid AWS profile: Configure AWS profile firstNo clusters found: Ensure you have access to ECS clusters in the selected AWS region.AWS CLI is not installed: Install AWS CLI v2.Session Manager Plugin is not installed: Install the Session Manager Plugin.AWS initialization failed: Check your AWS credentials and network connectivity.
AWS CLI not found
brew install awscliSession Manager Plugin not found
brew install session-manager-pluginInvalid AWS profileEnsure your AWS profile is configured correctly. If using AWS SSO, log in with:
aws sso login --profile your-profileAWS Credentials not configuredConfigure your AWS credentials by setting up your
~/.aws/credentialsand~/.aws/configfiles. You can use aws configure to set up access keys, or set up AWS SSO profiles.No clusters foundEnsure you have access to ECS clusters in the selected AWS region and that your AWS credentials have the necessary permissions.
ECS Exec Checker from AWS
https://github.com/aws-containers/amazon-ecs-exec-checker
bash <( curl -Ls https://raw.githubusercontent.com/aws-containers/amazon-ecs-exec-checker/main/check-ecs-exec.sh ) <YOUR_ECS_CLUSTER_NAME> <YOUR_ECS_TASK_ID>License
MIT
Contributing
Pull requests welcome! Please read CONTRIBUTING.md for details.
Dependabot
We use Dependabot to keep our dependencies up to date.
Semantic Release
We use Semantic Release to automate the release process.
GitHub Actions
We use GitHub Actions to run our tests and build our project.
ToDo
- Add support for
aws-vault