Code Monkey home page Code Monkey logo

aws-ebs-volumes-clean-up's Introduction

AWS-EBS-VOLUMES-CLEAN-UP

This code will fetch all your CBS volumes and delete all volumes except:

  • Those volumes created between the last 24 hours (according to the name)
  • The last volume of each 15th day in the month

Go to /config/default.json and replace your credentials

{
  "AWS": {
    "config": {
      "accessKeyId": "REPLACE_ACCESS_KEY_ID",
      "secretAccessKey": "REPLACE_SECRET_ACCESS_KEY",
      "region": "REPLACE_AWS_REGION"
    }
  }
}

To install dependencies and execute run on console

npm start

If you prefer to use docker just clone and

docker-compose up

Reports will be located at /reports directory

  • Reports are created as csv files
  • there are 3 reports, summary, deleted volumes and not deleted volumes

Just need to delete some snapshots

If you have Docker installed just run the script replacing the enviroment variables and let the magic happen

docker run -it --rm  -e ACCESS_KEY_ID=[REPLACE] -e SECRET_ACCESS_KEY=[REPLACE] -e AWS_REGION=[REPLACE] jsalgado/aws-ebs-cleanup:latest

aws-ebs-volumes-clean-up's People

Watchers

 avatar  avatar  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.