From f138566e30b6a9e17673c41e5452f987e4001e16 Mon Sep 17 00:00:00 2001 From: RFN <37929910+nicosuter@users.noreply.github.com> Date: Tue, 5 May 2026 13:13:13 +0200 Subject: [PATCH] remove stale script --- scripts/cost-killswitch.py | 18 ------------------ 1 file changed, 18 deletions(-) delete mode 100644 scripts/cost-killswitch.py diff --git a/scripts/cost-killswitch.py b/scripts/cost-killswitch.py deleted file mode 100644 index 41d46eb..0000000 --- a/scripts/cost-killswitch.py +++ /dev/null @@ -1,18 +0,0 @@ -import boto3 -import os - -def lambda_handler(event, context): - ec2 = boto3.client('ec2') - route_table_id = os.environ['ROUTE_TABLE_ID'] - - try: - # Drops the default route to the NAT Gateway - ec2.delete_route( - DestinationCidrBlock='0.0.0.0/0', - RouteTableId=route_table_id - ) - print(f"SUCCESS: Severed NAT Gateway route in {route_table_id}. Billing leak stopped.") - return {"status": 200, "message": "NAT route deleted"} - except Exception as e: - print(f"FAILED: Could not delete route. Error: {str(e)}") - raise e \ No newline at end of file