From d319315b3ab55462fc565a2e1b5dc6b934ea992e Mon Sep 17 00:00:00 2001 From: Jeremy Cook Date: Tue, 5 Dec 2023 09:25:50 +1300 Subject: [PATCH] updated makefile - changed fn name --- lambda_function.py | 11 ++++++++++- makefile | 2 +- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/lambda_function.py b/lambda_function.py index 13dc5c6..6ab8d5a 100644 --- a/lambda_function.py +++ b/lambda_function.py @@ -25,4 +25,13 @@ def lambda_handler(event, context): print("EBS vols to delete:") for vol in unused_volumes: - print(vol) \ No newline at end of file + print(vol) + + return { + "statusCode": 200, + "isBase64Encoded": False, + "headers": { + "Content-Type": "application/json" + }, + "body": {"unused_volumes": unused_volumes} + } \ No newline at end of file diff --git a/makefile b/makefile index 424d36d..f1291ff 100644 --- a/makefile +++ b/makefile @@ -1,4 +1,4 @@ -export LAMBDA_NAME=finops-janitor +export LAMBDA_NAME=cloudacademy-finops-janitor export LAMBDA_REGION=us-west-2 export IAM_ROLE_ARN=TOKEN_IAM_ROLE_ARN export S3_BUCKET_NAME=TOKEN_S3_BUCKET_NAME