AWS Cloud Financial Management team recently added feature to provide task level cost allocation both for used and unused resources. Check out the announcement blog for feature details.
Assuming you have done the following steps
- Enabled split-cost-allocation
- Enabled ECS Managed Tags and Enabled Propagate Tags -
enableECSManagedTags:TRUE
andpropagateTags:SERVICE
- Activated ECS managed tags for cost allocation tags
- Check out full pre-requisities
This repository provides Jypter NoteBook for analyzing split cost per service. Check out docs to install jupyter. Download the CUR report as CSV file with the split cost allocation data.
git clone https://github.com/arvindsoni80/ecs-ec2-cost-split.git
cd ecs-ec2-cost-split
jupyter notebook &
If Jupyter notebook doesn't start you can try:
jupyter lab build
jupyter lab &
Open the split-cost-allocation-ecs-ec2.ipynb
notebook. Change the variables such as CUR CSV file name, account id, and region as per your ECS settings. Then simply run the whole notebook. You will see the analysis done using the new split cost allocation. For example: