Skip to main content

Easily ssh to your AWS EC2 instances

Project description


PyPI version Build Status

GitHub issues GitHub closed issues GitHub closed pull requests

PyPI - Python Version GitHub GitHub last commit

Easily manage your AWS EC2 instances


pip install zec2


You should have this two files on your computer:





To learn more about AWS credentials and how to install them on your computer, please read this:


You can put as many profiles in your aws credentials file and call them with zec2:

# use default aws profile
> zec2 ls

# use different aws profile
> zec2 -p my_profile ls

Use this option with every command.


# list all EC2 instances
> zec2 ls

# list all EC2 instances using custom aws profile (applies to all commands)
> zec2 -p work ls

# live list all EC2 instances
> zec2 ls -f

# ssh to 1st instance from the list
> $(zec2 ssh 1)

# ssh using different user (the default is ec2-user)
> $(zec2 ssh 1 -u ubuntu)

# ssh using different pem key path (the default is ~/.ssh/__instance_key_pair__.pem)
> $(zec2 ssh 1 -i ~/path/to/key.pem)

# stop 1st EC2 instance from the list
> zec2 stop 1

# start 1st EC2 instance from the list
> zec2 start 1

# restart 1st EC2 instance from the list
> zec2 restart 1

# terminate 1st EC2 instance from the list
> zec2 terminate 1

Project details

Download files

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

Files for zec2, version 0.3.0
Filename, size File type Python version Upload date Hashes
Filename, size zec2-0.3.0.tar.gz (5.4 kB) File type Source Python version None Upload date Hashes View
Filename, size zec2-0.3.0-py2.py3-none-any.whl (6.1 kB) File type Wheel Python version py2.py3 Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page