ec2

package
v0.4.1-0...-d745f3b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 3, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UsageTypeNatGatewayHours = "NatGateway-Hours"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Logger  *zap.SugaredLogger
	EC2     ec2iface.EC2API
	Pricing pricingiface.PricingAPI
}

func (*Client) AnalyzeEBSVolumeWaste

func (client *Client) AnalyzeEBSVolumeWaste(ctx context.Context, region string) ([]util.AWSWastedResource, error)

func (*Client) AnalyzeElasticIPAddressWaste

func (client *Client) AnalyzeElasticIPAddressWaste(ctx context.Context, region string) ([]util.AWSWastedResource, error)

func (*Client) AnalyzeNATGatewayWaste

func (client *Client) AnalyzeNATGatewayWaste(ctx context.Context, region string) ([]util.AWSWastedResource, error)

func (*Client) GetEBSVolumePricing

func (client *Client) GetEBSVolumePricing(ctx context.Context, region string) (EBSVolumePricing, error)

func (*Client) GetElasticIPAddressPricing

func (client *Client) GetElasticIPAddressPricing(ctx context.Context, region string) (*util.Price, error)

func (*Client) GetNATGatewayPricing

func (client *Client) GetNATGatewayPricing(ctx context.Context, region string) (*NATGatewayPricing, error)

func (*Client) GetUnusedEBSVolumes

func (client *Client) GetUnusedEBSVolumes(ctx context.Context) ([]util.AWSResourceObject, error)

func (*Client) GetUnusedElasticIPAddresses

func (client *Client) GetUnusedElasticIPAddresses(ctx context.Context) ([]util.AWSResourceObject, error)

func (*Client) GetUnusedNATGateways

func (client *Client) GetUnusedNATGateways(ctx context.Context) ([]util.AWSResourceObject, error)

type EBSVolume

type EBSVolume struct {
	// contains filtered or unexported fields
}

func (EBSVolume) ID

func (r EBSVolume) ID() string

func (EBSVolume) Type

func (r EBSVolume) Type() string

func (EBSVolume) VolumeSizeinGb

func (r EBSVolume) VolumeSizeinGb() int64

func (EBSVolume) VolumeType

func (r EBSVolume) VolumeType() EBSVolumeType

type EBSVolumePricing

type EBSVolumePricing map[EBSVolumeType]*util.AWSPriceItem

type EBSVolumeType

type EBSVolumeType string

type ElasticIPAddress

type ElasticIPAddress struct {
	// contains filtered or unexported fields
}

func (ElasticIPAddress) ID

func (a ElasticIPAddress) ID() string

func (ElasticIPAddress) Type

func (a ElasticIPAddress) Type() string

type ElasticIPAddressPricing

type ElasticIPAddressPricing util.Price

type NATGatewayPricing

type NATGatewayPricing struct {
	PerHour *util.Price
}

type NatGateway

type NatGateway struct {
	// contains filtered or unexported fields
}

func (NatGateway) ID

func (r NatGateway) ID() string

func (NatGateway) Type

func (r NatGateway) Type() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL