Skip to content

Commit 9410a0a

Browse files
committed
PR name changes
1 parent d01f3ae commit 9410a0a

File tree

2 files changed

+24
-15
lines changed

2 files changed

+24
-15
lines changed

main.tf

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ resource "aws_launch_template" "default" {
276276
user_data = base64encode(var.user_data)
277277

278278
monitoring {
279-
enabled = var.detailed_monitoring
279+
enabled = var.monitoring_enabled
280280
}
281281

282282
network_interfaces {
@@ -304,9 +304,9 @@ resource "aws_launch_template" "default" {
304304
}
305305

306306
metadata_options {
307-
http_endpoint = "enabled"
308-
http_tokens = var.enable_imdsv2 ? "required" : "optional"
309-
http_protocol_ipv6 = var.metadata_ipv6 ? "enabled" : "disabled"
307+
http_endpoint = var.metadata_http_endpoint_enabled ? "enabled" : "disabled"
308+
http_tokens = var.metadata_imdsv2_enabled ? "required" : "optional"
309+
http_protocol_ipv6 = var.metadata_http_protocol_ipv6_enabled ? "enabled" : "disabled"
310310
}
311311
}
312312

variables.tf

Lines changed: 20 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -62,29 +62,38 @@ variable "additional_security_group_ids" {
6262
default = []
6363
}
6464

65-
variable "detailed_monitoring" {
65+
variable "monitoring_enabled" {
6666
description = "Enable detailed monitoring of instance"
67-
type = bool
68-
default = true
67+
type = bool
68+
default = true
6969
}
7070

7171
variable "associate_public_ip_address" {
7272
description = "Associate public IP address"
73-
type = bool
73+
type = bool
7474
# default should fall back to subnet setting
7575
default = null
7676
}
7777

78-
variable "enable_imdsv2" {
79-
description = "Enable IMDSv2"
80-
type = bool
81-
default = true
78+
variable "metadata_http_endpoint_enabled" {
79+
description = "Whether or not to enable the metadata http endpoint"
80+
type = bool
81+
default = true
82+
}
83+
84+
variable "metadata_imdsv2_enabled" {
85+
description = <<-EOT
86+
Whether or not the metadata service requires session tokens,
87+
also referred to as Instance Metadata Service Version 2 (IMDSv2).
88+
EOT
89+
type = bool
90+
default = true
8291
}
8392

84-
variable "metadata_ipv6" {
93+
variable "metadata_http_protocol_ipv6_enabled" {
8594
description = "Enable IPv6 metadata endpoint"
86-
type = bool
87-
default = false
95+
type = bool
96+
default = false
8897
}
8998

9099
######################

0 commit comments

Comments
 (0)