AWS ECS Task Definition Stuck on DELETE_IN_PROGRESS

1.6k Views Asked by At

I had an ECS cluster, service, task definitions, ECR repo, RDS database, security groups, and other EC2 services, and I managed to delete all except for a single task definition and the associated network and VPC services. I can't delete any network and other VPC services before the task definition is deleted. However, the task definition is stuck on DELETE_IN_PROGRESS.

I deleted the stacks in CloudFormation but it didn't help. CloudTrails don't show any errors either. The task definition had a task role and task execution role but both are deleted. It had one container but the ECR repo had been deleted as well. I tried using AWS CLI and some --force commands to delete other associated services but none could be deleted before this task gets deleted.

Here is a list of services I checked:

Running services:

  • EC2 Security Groups - 1
  • EC2 VPCs - 1
  • Subnets - 2
  • Route Tables - 1
  • Security Groups - 1
  • Network ACLs - 1

No running services:

  • EC2 Instances
  • EC2 Key Pairs
  • EC2 Elastic IPs
  • EC2 Instances
  • RDS Instances
  • ECS Clusters
  • ECS Task Definitions
  • ECR Repositories
  • Lambda Functions
  • S3 Buckets

Basically, I want to delete all services. Any suggestions on how to do it?

0

There are 0 best solutions below