Skip to content

khanhcd92/clear-lambda-storage-nodejs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Clear Lambda code storage

Motivation

AWS limits the total code storage for Lambda functions to 75GB.

The main reason of reaching such size is because for every deployment of existing function, AWS stores the previous version ("qualifier").

Usually, when you reach that point, you want to remove old version. This tool will help you to!

Setup

Install via source

git clone https://github.com/khanhcd92/clear-lambda-storage-nodejs.git
cd clear-lambda-storage-nodejs/
npm i
node index.js

Advanced usage

Provide credentials:

node index.js --access-key <access_key_id> --secret-key <secret_access_key> --num-to-keep <number>

Provide credentials with one region:

node index.js --access-key <access_key_id> --secret-key <secret_access_key> --num-to-keep <number> --regions <region_code>

Provide profile:

node index.js --profile <profile_id> --num-to-keep <number>

Provide profile with one region:

node index.js --profile <profile_id> --num-to-keep <number> --regions <region_code>

About

Removes old versions of Lambda functions

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published