List Lambdas functions
(Based on photo by Valve Software / CC BY-SA 4.0)
Motivation
- Read our blog post, "The curse of dead Lambda functions": https://medium.com/epsagon/the-curse-of-dead-lambda-functions-228bf812c10a
- Enumerate list of Lambda functions from every region.
- Detect "dead" or unused Lambda functions.
Setup
git clone https://github.com/epsagon/list-lambdas
cd list-lambdas/
pip install -r requirements.txt
python list_lambdas.py
Example Outputs
CLI:
CSV file:
Usage
Filter only Lambda functions that have not been active in the last 10 days:
python list_lambdas.py --inactive-days-filter 10
Print extended information to the screen (same as in the CSV file):
python list_lambdas.py --all
Sort by a chosen column (e.g. by last invocation time):
python list_lambdas.py --sort-by last-invocation
Output table (with extra data) to a CSV file:
python list_lambdas.py --csv lambdas.csv
Provide credentials:
python list_lambdas.py --token_key_id <access_key_id> --token_secret <secret_access_key>