kanjo-cli
v0.2.1
Published
CLI for Summarize AWS Billing
Downloads
13
Readme
kanjo-cli
CLI for Summarize AWS Billing
Installation
npm install --global kanjo-cli
Configuration
AWS Credentials & Region
You can create the credential file yourself. By default, its location is at ~/.aws/credentials
[default]
aws_access_key_id = YOUR_ACCESS_KEY
aws_secret_access_key = YOUR_SECRET_KEY
You may also want to set a default region. This can be done in the configuration file. By default, its location is at ~/.aws/config
[default]
region = us-east-1
More detailed configurations, please see following articles.
- Configuring the SDK in Node.js — AWS SDK for JavaScript.
- Configuring the AWS Command Line Interface - AWS Command Line Interface
Default options
You can create the config file to omit options for CLI.
By default, its location is at ~/.kanjo
.
[default]
account = "BILLING_ACCOUNT_ID"
bucket = "S3_BUCKET_NAME_STOREING_BLLING_CSV"
You can write options per profile similar to AWS credentials and config. But, Format of this file is TOML.
Usage
Usage: kanjo [options] [yyyymm]
Options:
-o, --output Set output format [choices: "table", "text"] [default: "table"]
-p, --profile Set profile name (default: default) [string] [default: "default"]
-c, --config Set config file path loading options [string] [default: "$HOME/.kanjo"]
--account Set account id for billing [string]
--bucket Set S3 bucket name storeing billing csv [string]
--region Set S3 region name storeing billing csv [string]
--help Show help [boolean]
--version Show version number [boolean]
Examples:
kanjo Show charges of current month
kanjo 201507 Show charges of July, 2015
kanjo --accont=foo --bucket=bar --region=us-east-1 No config file
Related
- kanjo - API for this module
Todo
- [x] Load account / bucket info from config file
- [ ] Add tests
- [ ] Support weekly summary
- [ ] Support daily summary
- [ ] Support monthly forecast
- [ ] Support transition of charge in period