AWS Ssm Connector to able access EC2 instance without access to AWS dashboard.This tools presents a simple menu for that purposes.
connect tool basically developed as a pip3 package you easily setup all the dependencies and build the packages like this;
$ pip3 install . --upgrade
After your installation completed you can get the output like this
$ connect --region eu-west-1
> kubernetes-worker-1 , i-INSTANCE_ID
> kubernetes-master , i-INSTANCE_ID
$ connect.py --region eu-west-2 --tag Name --value asg-development
For more details
connect --help
Usage: connect [options]
Options:
-h, --help show this help message and exit
-r REGION, --region=REGION
Region name of the aws account
-t TAG, --tag=TAG Tag of the EC2 instance
You can select easily with interactive menu
You can install python3 dependencies like that :
$ pip3 install -r requirements.txt
To connect your instance over ssm client you have to install this plugin following to this documents of AWS: Session Manager Plugin Installation
After than you should specify default AWS_PROFILE, or credential values into your terminal session (I prefer profile usage):
$ export AWS_PROFILE=<MY_ACCOUNT_ID> AWS_DEFAULT_REGION=<REGION> AWS_SDK_LOAD_CONFIG=1
Notice : If you want to run this via your shell, you should move somewhere in your $PATH directory: