EC2 Reaper
CLI & module for terminating instances that match tag and age requirements.
Features
- Searches all (or specified) regions for instances.
- Matches instances against a tag pattern.
- Allows instances a grace period before termination.
- Can be used as a Python module, CLI application, or an AWS Lambda function
Usage
Tag Matchers
[{"tag": "Name", "includes": [], "excludes": ["*"]}]
This is the default tag matcher and it will match anything that lacks a Name tag.
To terminate any instance named "cirunner", the filter would look like so:
[{"tag": "Name", "includes": ["cirunner"], "excludes": []}]
Credits
This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.