Skip to content

blueharvest/ec2-instances-info

 
 

Repository files navigation

ec2-instances-info

Build Status Go Report Card GoDoc

Golang library providing specs and pricing information about AWS EC2 instances, based on the data that is also powering the comprehensive www.ec2instances.info instance comparison website.

History

This used to be a part of my other project AutoSpotting which uses it intensively, but I decided to extract it into a dedicated project sice it may be useful to someone else out there.

Some data fields that were not needed in AutoSpotting may not yet be exposed but they can be added upon demand.

Installation or update

go get -u github.com/cristim/ec2-instances-info/...

Usage

import "github.com/cristim/ec2-instances-info"

data, err := ec2instancesinfo.Data() // only needed once

// This would print all the available instance type names:
for _, i := range *data {
  fmt.Println("Instance type", i.InstanceType)
}

See the examples directory for a working code example.

Contributing

Pull requests and feedback are welcome.

The data can be updated for new instance type coverage using make update-data.

Try it out

Open in Cloud Shell

History

About

Golang library for specs and pricing information about AWS EC2 instances based on the data from www.ec2instances.info

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 84.7%
  • Makefile 15.3%