Skip to content

Commit 9156524

Browse files
committed
clean
1 parent b23a367 commit 9156524

File tree

3 files changed

+1
-82
lines changed

3 files changed

+1
-82
lines changed

modules/termination-watcher/termination.tf

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -4,41 +4,3 @@ module "termination_handler" {
44

55
config = local.config
66
}
7-
8-
# }
9-
10-
# resource "aws_cloudwatch_event_rule" "spot_instance_termination" {
11-
# name = "${var.config.prefix != null ? format("%s-", var.config.prefix) : ""}spot-termination"
12-
# description = "Spot Instance Termination (BidEventicedEvent)"
13-
14-
# event_pattern = <<EOF
15-
# {
16-
# "source": ["aws.ec2"],
17-
# "detail-type": ["AWS Service Event via CloudTrail"],
18-
# "detail": {
19-
# "eventSource": ["ec2.amazonaws.com"],
20-
# "eventName": ["BidEvictedEvent"]
21-
# }
22-
# }
23-
# EOF
24-
# }
25-
26-
# resource "aws_cloudwatch_event_target" "main" {
27-
# rule = aws_cloudwatch_event_rule.spot_instance_termination.name
28-
# arn = module.termination_handler.lambda.function.arn
29-
# }
30-
31-
# resource "aws_lambda_permission" "main" {
32-
# statement_id = "AllowExecutionFromCloudWatch"
33-
# action = "lambda:InvokeFunction"
34-
# function_name = module.termination_handler.lambda.function.function_name
35-
# principal = "events.amazonaws.com"
36-
# source_arn = aws_cloudwatch_event_rule.spot_instance_termination.arn
37-
# }
38-
39-
# resource "aws_iam_role_policy" "lambda_policy" {
40-
# name = "lambda-policy"
41-
# role = module.termination_warning.lambda.role.name
42-
43-
# policy = templatefile("${path.module}/policies/lambda.json", {})
44-
# }

modules/termination-watcher/variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
variable "config" {
22
description = <<-EOF
3-
Configuration for the spot termination watcher lambda function.
3+
Configuration for the spot termination watcher.
44
55
`aws_partition`: Partition for the base arn if not 'aws'
66
`architecture`: AWS Lambda architecture. Lambda functions using Graviton processors ('arm64') tend to have better price/performance than 'x86_64' functions.

modules/termination-watcher/warnings.tf

Lines changed: 0 additions & 43 deletions
This file was deleted.

0 commit comments

Comments
 (0)