The AWS Helper is a go based command line interface utility for AWS
$ wget -O /usr/local/bin/aws-helper XXX/artifacts/raw/aws-helper_linux-amd64
$ chmod +x /usr/local/bin/aws-helper
$ wget -O /usr/local/bin/aws-helper XXX/artifacts/raw/aws-helper_darwin-arch386
$ chmod +x /usr/local/bin/aws-helper
In order to work properly, AWS Helper needs to be checked out at the following location: $GOPATH/src/github.com/kj187/aws-helper
$ git clone XXX/aws-helper.git $GOPATH/src/github.com/kj187/aws-helper
$ cd $GOPATH/src/github.com/kj187/aws-helper
$ make setup
$ cd $GOPATH/src/github.com/kj187/aws-helper
$ make test
____ _ _ _ ____ _ _ ____ _ ___ ____ ____
|__| | | | [__ |__| |___ | |__] |___ |__/
| | |_|_| ___] | | |___ |___ | |___ | \
The AWS Helper is a go based command line interface utility for AWS.
Author: Julian Kleinhans <mail@kj187.de>, alias @kj187
Usage:
aws-helper [flags]
aws-helper [command]
Examples:
aws-helper ec2:list -c Name -C KeyName -f AZ:eu-central-1
Available Commands:
ec2:list List all EC2 instances
help Help about any command
Flags:
-a, --access_key string set aws access_key
-h, --help help for aws-helper
-p, --profile string set aws profile
-r, --region string set region (default "eu-central-1")
-s, --secret_key string set aws secret_key
Use "aws-helper [command] --help" for more information about a command.
The default region is eu-central-1
. You can define the region with an environment variable AWS_DEFAULT_REGION
or with the flag --region
Example with env var:
$ export AWS_DEFAULT_REGION=us-east-1
$ aws-helper ec2:list
Example with flag:
$ aws-helper ec2:list --region us-east-1
$ aws-helper ec2:list
TODO
TODO
Usage:
aws-helper ec2:list [flags]
Flags:
-c, --column stringSlice add additional column (tag)
-f, --filter stringSlice filter with column (Example: InstanceType:t2.micro)
-h, --help help for ec2:list
-C, --remove-column stringSlice remove default column
-t, --tag stringSlice filter with tag (Example: Name:Jenkins)
Global Flags:
-a, --access_key string set aws access_key
-p, --profile string set aws profile
-r, --region string set region (default "eu-central-1")
-s, --secret_key string set aws secret_key
- InstanceId
- ImageId
- State
- SubnetId
- AZ
- InstanceType
- KeyName
- PrivateIpAddress
- PublicIpAddress
With the uppercase C flag -C
or --remove-column
you have the possibility to remove a default column.
Example
$ aws-helper ec2:list -C SubnetId -C AZ
As you can see you could also remove multiple columns.
Imagine your instances have a "Name" tag, with the lowercase -c
or --column
yu have the possibility to add tags as a column.
Example
$ aws-helper ec2:list -c Name
Yes, you could also add multiple columns.
There a two different ways to filter your results. You could use a tag filter or a column filter.
Example
$ aws-helper ec2:list -t Name:Jenkins
Example
$ aws-helper ec2:list -f InstanceType:t2.micro