cdk-ecs-rollback-cleanup

Resolve CDK ECS Fargate stack rollbacks stuck by security group DependencyViolation errors.

2|Updated May 10, 2026
One-click install
npx skills add https://github.com/freedomw1987/tree_monstor --skill cdk-ecs-rollback-cleanup
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cdk-ecs-rollback-cleanup
Source: https://github.com/freedomw1987/tree_monstor/tree/main/skills/devops/cdk-ecs-rollback-cleanup
Command: npx skills add https://github.com/freedomw1987/tree_monstor --skill cdk-ecs-rollback-cleanup

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill resolves CDK ECS Fargate stack rollbacks that are stuck in ROLLBACK_COMPLETE or DELETE_FAILED states due to security group DependencyViolation errors, which typically occur when manual ingress rules are added to an RDS security group that references the backend security group managed by CDK.

Core Features & Use Cases

  • Blocking Dependency Identification: Guides users to run AWS CLI commands to locate the specific security group and resource causing the deletion failure.
  • Conflict Resolution: Provides the exact commands to revoke the conflicting ingress rule that creates the circular dependency between security groups.
  • Residual Resource Cleanup: Includes steps to verify load balancer deletion and handle stale Route53 DNS records after a successful rollback.
  • Use Case: DevOps engineers managing AWS CDK ECS Fargate deployments can use this Skill to quickly resolve stuck rollbacks without manually troubleshooting complex CloudFormation dependency chains.

Quick Start

Use this skill to fix a stuck CDK ECS Fargate stack rollback caused by a security group dependency violation in your AWS ap-east-1 deployment.

Frequently Asked Questions about cdk-ecs-rollback-cleanup

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
Why does my CDK ECS Fargate stack rollback fail with a DependencyViolation error?

A CDK ECS Fargate stack rollback fails with a DependencyViolation when manual ingress rules added to an RDS security group reference the backend security group managed by CDK, creating a blocking circular dependency.

How do I fix a CloudFormation stack stuck in ROLLBACK_COMPLETE state?

Fix a CloudFormation stack stuck in ROLLBACK_COMPLETE by running AWS CLI commands to identify the blocking security group dependency, revoking the conflicting ingress rule, and then retrying the stack deletion.

How do I clean up residual load balancer and Route53 DNS records after an ECS rollback?

Clean up residual load balancer and Route53 DNS records after an ECS rollback by verifying load balancer deletion status and manually removing stale Route53 DNS entries using AWS CLI commands.

Can I use AWS CLI to resolve security group dependency conflicts in CDK deployments?

Yes, you can use AWS CLI to resolve security group dependency conflicts in CDK deployments by locating the specific blocking resource, revoking the conflicting ingress rule, and successfully retrying the stack deletion.

What is the best way to remove manual ingress rules blocking CDK stack deletion?

The best way to remove manual ingress rules blocking CDK stack deletion is to identify the specific RDS security group via AWS CLI and revoke the conflicting rule that creates a circular dependency on the backend security group.

Does resolving security group dependency violations require manual CloudFormation troubleshooting?

No, resolving security group dependency violations does not require manual CloudFormation troubleshooting if you follow step-by-step AWS CLI commands to revoke the conflicting ingress rule and retry the CDK stack deletion.