trafficlight
start and stop ec2 instances.
installation
install with pip
pip install trafficlight
dependencies
-aws cli (installed and configured)
-python3
flags
-h, --help show this help message and exit
--key KEY optional. use a tag key besides Name
-R REGION, --region REGION
specify a different region
-g, --green start.
-r, --red stop.
-L, --leave do not change instance state.
-y, --yes automatically approve instance state change.
-H, --host use hostnames instead of ip addresses.
-c, --connect begin an ssh session.
-K, --keyfile write pem keyfile to trafficlight config.
-p, --pipe output instance ip or hostname via standard out to pipe into other commands.
-v, --version show program's version number and exit
usage
show trafficlight help page, including usage and flags.
$ trafficlight -h
switch instance with tag Name:example. if instance is stopped it will start, if it's running it will stop.
$ trafficlight example
connect to ec2 instance with tag Name:example. if instance is stopped it will start the instance first.
$ trafficlight example -c
specify a different region.
$ trafficlight example -R us-west-1
update trafficlight's config file with keyfile for using -c --connect flag.
$ trafficlight -K
start all instances with tag Name:example. if instances are started already they will stay up.
$ trafficlight example -g
stop all instances tag Name:example. if instances are stopped already they will stay stopped.
$ trafficlight example -r
get instance info for tag, but don't change instance state.
$ trafficlight example -L
stop all instances with tag Products:example.
$ trafficlight example --key Products -r
list all ec2s and do nothing.
$ trafficlight
list all ec2s and stop them.
$ trafficlight -r
Metadata
Release files for trafficlight 1.4.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| trafficlight-1.4.7.tar.gz | 8.0 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| trafficlight-1.4.7-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 16.5 kB
Release files / trafficlight-1.4.7.tar.gz
| Download URL | trafficlight-1.4.7.tar.gz |
|---|---|
| Size | 8.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
84190c63b65ebf98b68b207fa199c98691f0d09ba95366e8c466188dd6cb55d2
|
|
BLAKE2b-256 checksum How to use checksums |
0ab8c1c99cf3761b95be6b706433e49418a7e15dfabcd18a4e3238f1a81d24e0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.6.1 requests/2.24.0 setuptools/46.0.0 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.3
|
Release files / trafficlight-1.4.7-py3-none-any.whl
| Download URL | trafficlight-1.4.7-py3-none-any.whl |
|---|---|
| Size | 8.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d78dd79f0536cb6ec0797b032a4a77694a6df61e1e810ab7c6c5b5b7091bc256
|
|
BLAKE2b-256 checksum How to use checksums |
0fd85e0dd0f35348590ad599f28024c03cdcb6f7358521e2b7dc55ba9e4f4b79
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.6.1 requests/2.24.0 setuptools/46.0.0 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.3
|
Security for trafficlight 1.4.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.