GithubHelp home page GithubHelp logo

surlalwani / aws-cost-and-usage-report Goto Github PK

View Code? Open in Web Editor NEW

This project forked from hjacobs/aws-cost-and-usage-report

0.0 0.0 0.0 19 KB

Simple script to generate a TSV file using the AWS Cost Explorer API

Python 100.00%

aws-cost-and-usage-report's Introduction

AWS Resources Report Generator

This script generates a comprehensive report of various AWS resources, including EC2 instances, S3 buckets, AMIs, and snapshots. The report is generated in the form of an Excel file and can be emailed to the desired recipients using the Simple Email Service (SES). Prerequisites

Before running the script, ensure that you have the following prerequisites:

AWS Credentials: Obtain valid AWS access key ID and secret access key with sufficient permissions to access EC2, S3, and SES.

Usage

Clone this repository to your local machine.

Update the following variables in the code:

access_key_id and secret_access_key: Provide your AWS access key ID and secret access key.

SENDER and RECIPIENT: Specify the sender and recipient email addresses for sending the report.

BUCKET_NAME and KEY: Provide the name of the S3 bucket where you want to upload the report and the desired object key.

Run the script using Python: python script.py.

The script will gather information about running EC2 instances, S3 buckets, AMIs, and snapshots. It will generate an Excel report named AWSresourcesReport.xlsx in the /tmp/ directory.

The report will contain multiple sheets, each presenting information about a specific AWS resource.

The report will also include visualizations such as a bar chart depicting the time consumption of EC2 instances.

The generated report will be uploaded to the specified S3 bucket.

An email containing the report will be sent using SES to the specified recipient.

Additional Considerations

Ensure that you have the necessary IAM permissions to access and manage the desired AWS resources.

Customize the script as per your requirements, such as adding more AWS resources or modifying the report format.

Schedule the script to run periodically using AWS Lambda or any other desired method to automate the report generation process.

Please note that this README provides a high-level overview of the script's functionality. For detailed usage and configuration instructions, refer to the comments in the code and the official documentation for AWS services and Python libraries used.

Feel free to reach out if you have any questions or need further assistance.

aws-cost-and-usage-report's People

Contributors

hjacobs avatar lukewest avatar surlalwani avatar

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.