Simple golang script that returns all ec2 inventory in a JSON payload divided by whether the instance type is latest generation or not and keyed by instance type.
Build
This is a go project so installing go is a requirement
make build to build the binaries. This will also download the dependencies.
Run
Two binaries are generated. One is for linux/amd64 and the other is for darwin/amd64. AWS access is controlled by the default environment variables defined here. The exception is AWS_REGION instead of AWS_DEFAULT_REGION as that is the environment variable the go sdk looks for.