Git Product home page Git Product logo

pricy's Introduction

Pricy

Go Report Card codecov

Install

brew tap stangirard/tap
brew install pricy

Run

pricy

If you are using sso for credentials on aws

pricy --sso

Usage

Cloud Providers

These are the flags required for enabling a cloud provider

  • --aws - Enable AWS
    • --sso: Use sso for credentials for aws
  • --azure - Enable Azure
    • subscription: Azure subscription id you want the report to be generated for

Flags for configuration

There are a couple of parameters that you can use

  • --details: Show the details of the report with the pricing by service
  • --csv: Output the report as csv to reports.csv
  • --evolution: Show the evolution of the report as evolution.csv
  • --days: Number of days to look back for
  • --interval: Date Interval on which the report is generated (Default last 14 days) (Format: YYYY-MM-DD:YYYY-MM-DD)
  • --granularity: Granularity of the report, can be daily, monthly
  • --html: Output the report as html to pricy.html
  • --prometheus: Outputs as prometheus metrics on http://localhost:2112/metrics that can be scraped by prometheus
  • --gsheets: Outputs the report to a google sheets spreadsheet

Example

Generate a Google Spreadsheet

You need to export the variable GOOGLE_APPLICATION_CREDENTIALS to the path of your json file which contains your OAuth2 credentials. In oder to get the credentials, you follow this guide:

export GOOGLE_APPLICATION_CREDENTIALS="/path/to/credentials.json"
pricy --aws --sso --csv --gsheet --days 30

gsheets

HTML Report Generation

pricy --aws --sso --days 150 --granularity monthly --html

Generates a report for the price starting a 150 days ago

html-report

Prometheus Metrics

pricy --aws --sso --prometheus  

Generates the prometheus metrics for the price updating every 8 hours

prometheus

pricy's People

Contributors

goreleaserbot avatar renovate[bot] avatar stangirard 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  avatar

Watchers

 avatar  avatar

pricy's Issues

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • chore(deps): update goreleaser/goreleaser-action action to v6

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

github-actions
.github/workflows/codecov.yml
  • actions/checkout v3
  • actions/setup-go v3
  • codecov/codecov-action v3
.github/workflows/release.yml
  • actions/checkout v3
  • actions/setup-go v3
  • goreleaser/goreleaser-action v3
gomod
go.mod
  • go 1.18
  • github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.1.0
  • github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/costmanagement/armcostmanagement v1.0.0
  • github.com/Azure/go-autorest/autorest/to v0.4.0
  • github.com/aws/aws-sdk-go v1.44.69
  • github.com/prometheus/client_golang v1.12.2
  • github.com/stretchr/testify v1.8.0
  • golang.org/x/oauth2 v0.0.0-20220722155238-128564f6959c@128564f6959c
  • google.golang.org/api v0.91.0

  • Check this box to trigger a request for Renovate to run again on this repository

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.