Code Monkey home page Code Monkey logo

aws_audit_exporter's Introduction

Prometheus AWS audit exporter

This program is intended to export various AWS statistics as prometheus metrics. It is primarily intended to assist with billing. Currently the following metrics are exported:

EC2 Instance Counts

  • aws_ec2_instances_count: Count of istances

The following labels are exposed:

  • az: availability zone
  • instance_type: type of instance
  • lifecycle: spot or scheduled instance
  • groups: sorted comma separated list of groups.
  • owner_id: The owner id
  • requester_id: The requester id (default to owner id if none is present)
  • aws_tag_: Any tags passed in with the -instance-tags flag are added as labels

EC2 Reserved Instances

Every set of instance reservations gets its own time series, this is intended to allow the end time of reserved intances to be tracked and potentially alerted upon.

  • aws_ec2_reserved_instances_usage_price_dollars: cost of reserved instance usage in dollars
  • aws_ec2_reserved_instances_fixed_price_dollars: fixed cost of reserved instance in dollars
  • aws_ec2_reserved_instances_price_per_hour_dollars: hourly cost of reserved instance in dollars
  • aws_ec2_reserved_instances_count: Number of reserved instances in this reservation
  • aws_ec2_reserved_instances_start_time: Start time of this reservation
  • aws_ec2_reserved_instances_end_time: End time of this reservation

The following labels are exposed:

  • id: the reservation id
  • az: availability zone
  • instance_type: type of instance
  • product: The product description
  • tenancy:
  • offer_type:

EC2 Spot Instance Request

Only fullfilled active spot instances requests are currently tracke

  • aws_ec2_spot_request_count: How active spot instances of a given type you have running
  • aws_ec2_spot_request_bid_price_hourly_dollars: Your maximum bid price
  • aws_ec2_spot_request_actual_block_price_hourly_dollars: The price paid for limited duration spot instances

The following labels are exposed:

  • az: availability zone
  • instance_type: type of instance
  • product: The product description

EC2 Spot Instance Pricing

Only prices for products that have been seen in spot instance requests are tracked.

  • aws_ec2_spot_price_per_hour_dollars: The current market price for a spot instance

The following labels are exposed:

  • az: availability zone
  • instance_type: type of instance
  • product: The product description

Usage

Your aws credentials should either be in $HOME/.aws/credentials , or set via AWS_ACCESS_KEY and AWS_SECRET_ACCESS_KEY

Usage of /go/bin/aws_audit_exporter: -addr string port to listen on (default ":9190") -duration duration How often to query the API (default 4m0s) -instance-tags string comma seperated list of tag keys to use as metric labels -region string the region to query (default "eu-west-1")

TODO

  • Add optional Push gateway support
  • Make tracking full Reserved instance tracking optional and pre-aggregate

aws_audit_exporter's People

Contributors

mzupan avatar tcolgate avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

aws_audit_exporter's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.