File tree Expand file tree Collapse file tree 3 files changed +19
-1
lines changed
Expand file tree Collapse file tree 3 files changed +19
-1
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,14 @@ module "app_cluster" {
2525 instance_type = "t3a.medium"
2626 user_data_base64 = ""
2727 iam_instance_profile_name = "ecs_agent_access_instance_profile"
28+ root_block_device = {
29+ volume_type = "gp3"
30+ volume_size = 30
31+ tags = {
32+ "Environment" = "staging"
33+ "ManagedBy" = "Terraform"
34+ }
35+ }
2836 security_group_ids = ["sg-01", "sg-02"]
2937 },
3038 {
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ resource "aws_launch_configuration" "ecs_launch_config" {
55 instance_type = each. value . instance_type
66 user_data_base64 = each. value . user_data_base64
77 iam_instance_profile = each. value . iam_instance_profile_name
8+ root_block_device = each. value . root_block_device || {}
89 security_groups = each. value . security_group_ids
910 lifecycle {
1011 create_before_destroy = true
Original file line number Diff line number Diff line change @@ -40,7 +40,16 @@ variable "launch_configs" {
4040 instance_type = string
4141 user_data_base64 = string
4242 iam_instance_profile_name = string
43- security_group_ids = list (string )
43+ root_block_device = object ({
44+ ebs_volume_type = string
45+ ebs_volume_size = number
46+ tags = object ({
47+ Name = string
48+ Environment = string
49+ ManagedBy = string
50+ })
51+ })
52+ security_group_ids = list (string )
4453 }))
4554 description = " Launch configuration for EC2 instances."
4655}
You can’t perform that action at this time.
0 commit comments