Resource Cleanup
Cleaning Up on the AWS Console
First, you need to access the AWS console to delete the services you previously created manually.
- In the console, search for CloudFormation.
- Select Stacks.
- Choose the 2 Services you created and click Delete.
- Wait approximately 5 to 10 minutes for the deletion process to complete.
- Go back to the ECS cluster to check if the service has been deleted.
Since the resources in the infrastructure were created by Terraform, you can conveniently delete all resources with a single command instead of manually removing each one.
Now, go back to the location where you initially deployed the infrastructure with Terraform.
- Use the command below to delete resources.
terraform destroy
- Wait approximately 15 to 20 minutes for all resources to be deleted.
- After a successful deletion, return to the AWS console to verify that all resources have been removed.