Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3383471
D8716.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1020 B
Referenced Files
None
Subscribers
None
D8716.diff
View Options
diff --git a/services/terraform/remote/aws_ecs.tf b/services/terraform/remote/aws_ecs.tf
--- a/services/terraform/remote/aws_ecs.tf
+++ b/services/terraform/remote/aws_ecs.tf
@@ -36,13 +36,19 @@
}
# Autoscaling configuration
+resource "aws_iam_instance_profile" "ecs_instance_profile" {
+ # AWS Console creates profiles with the same name as IAM roles.
+ # We do the same here.
+ name = aws_iam_role.ecs_instance_role.name
+ role = aws_iam_role.ecs_instance_role.name
+}
resource "aws_launch_template" "ecs_services" {
name_prefix = "services-ecs-ec2-"
image_id = data.aws_ami.al2_x86_ecs.id
instance_type = "t3.small"
iam_instance_profile {
- name = aws_iam_role.ecs_instance_role.name
+ name = aws_iam_instance_profile.ecs_instance_profile.name
}
metadata_options {
@@ -61,6 +67,8 @@
echo ECS_CLUSTER=${aws_ecs_cluster.comm_services.name} >> /etc/ecs/ecs.config;
EOT
)
+
+ update_default_version = true
}
resource "aws_autoscaling_group" "ecs_services" {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 29, 3:54 PM (21 h, 10 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2597421
Default Alt Text
D8716.diff (1020 B)
Attached To
Mode
D8716: [terraform] Add missing Instance Profile resource
Attached
Detach File
Event Timeline
Log In to Comment