Skip to content

Commit

Permalink
Add remote command line access to container exec
Browse files Browse the repository at this point in the history
  • Loading branch information
keirbadger authored Oct 18, 2024
1 parent f307209 commit 309bf0a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ resource "aws_ecs_service" "service" {
deployment_minimum_healthy_percent = var.deployment_minimum_healthy_percent
deployment_maximum_percent = var.deployment_maximum_percent
health_check_grace_period_seconds = var.health_check_grace_period_seconds
enable_execute_command = true

load_balancer {
target_group_arn = var.target_group_arn
Expand Down Expand Up @@ -59,6 +60,7 @@ resource "aws_ecs_service" "service_multiple_loadbalancers" {
deployment_minimum_healthy_percent = var.deployment_minimum_healthy_percent
deployment_maximum_percent = var.deployment_maximum_percent
health_check_grace_period_seconds = var.health_check_grace_period_seconds
enable_execute_command = true

dynamic "load_balancer" {
for_each = var.multiple_target_group_arns
Expand Down Expand Up @@ -112,6 +114,7 @@ resource "aws_ecs_service" "service_no_loadbalancer" {
deployment_minimum_healthy_percent = var.deployment_minimum_healthy_percent
deployment_maximum_percent = var.deployment_maximum_percent
health_check_grace_period_seconds = var.health_check_grace_period_seconds
enable_execute_command = true

ordered_placement_strategy {
type = "spread"
Expand Down Expand Up @@ -155,6 +158,7 @@ resource "aws_ecs_service" "service_for_awsvpc_no_loadbalancer" {
deployment_minimum_healthy_percent = var.deployment_minimum_healthy_percent
deployment_maximum_percent = var.deployment_maximum_percent
health_check_grace_period_seconds = var.health_check_grace_period_seconds
enable_execute_command = true

network_configuration {
subnets = var.network_configuration_subnets
Expand Down

0 comments on commit 309bf0a

Please sign in to comment.