diff --git a/README.md b/README.md index 75dfbfc..a9d70e3 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,45 @@ -# garbo -Garbo- a garbage collector for the clouds +# Garbo - Graph-based cloud resource cleanup + +## Notes +* This is a *very* early version + * Only AWS discovery + * No resources cleanup, just reporting + +## Quick Start +1. Copy and modify the example configuration file + + ```bash + cp garbo.cfg.example garbo.cfg.example + vim garbo.cfg + ``` +2. Create a Core Resources file, eg. + + ```yml + --- # My applications + Backend: + - "AWS://AutoScalingGroup/us-east-1/Backend-ASG" + QA: + - "AWS://Instance/us-east-1/i-abc12345" # Mock server + ``` +3. Find unused resources + + ```bash + python garbo.py -d -g -a /path/to/core_resources.yml + # And start a simple web server to view the resulted d3js graph (assuming Python 2.7) + python -m SimpleHTTPServer 8000 + ``` +4. Browse to: + +## Usage +``` +usage: garbo.py [-h] [--applications APPLICATIONS] [--discovery] [--gen-d3js] + +optional arguments: + -h, --help show this help message and exit + --applications APPLICATIONS, -a APPLICATIONS + YAML file containing Core Resources per application + --discovery, -d Perform a discovery (don't use stored graph). + default: False + --gen-d3js, -g Generate a json file for D3JS Directed Force Graph. + default: False +``` \ No newline at end of file diff --git a/garbo.py b/garbo.py index eaafb65..b26a3eb 100644 --- a/garbo.py +++ b/garbo.py @@ -19,13 +19,13 @@ def _get_parsed_arguments(): parser = argparse.ArgumentParser() parser.add_argument('--applications', '-a', default=False, - help='a YAML file containing the name and root resources of your application') + help='YAML file containing Core Resources per application') parser.add_argument('--discovery', '-d', action='store_true', default=False, - help='should garbo perform a discovery, or just use stored graph') + help='Perform a discovery (don\'t use stored graph). default: False') parser.add_argument('--gen-d3js', '-g', action='store_true', default=False, - help='should garbo generate a json file for D3JS Directed Force Graph') + help='Generate a json file for D3JS Directed Force Graph. default: False') return parser.parse_args()