Why it matters
Services that already build their images for several architectures can move to Graviton by changing one setting in the task definition.How nOps finds it
nOps reads the last 7 days of on-demand x86 Linux Fargate billing (vCPU-hours and GB-hours) per ECS cluster. The saving is that cost times the difference between the ARM64 and x86 list prices in the region, for vCPU and memory separately. Hours covered by Savings Plans are left out, and so are savings under $5 a month.Before you start
Container images built for ARM64 or multi-architecture, including sidecars and agents.How to implement
- Build each container image for
linux/arm64, or as a multi-architecture image, and push it. - Register a new task definition revision with
runtimePlatformset tocpuArchitecture: ARM64andoperatingSystemFamily: LINUX. - Update the service to the new revision; ECS replaces tasks with a rolling deployment.
- Check logs, errors and latency after the rollout.
- Make the change in Terraform, CloudFormation or your deployment pipeline.
Risks and considerations
- Images built only for x86 fail to start on ARM64.
- Fargate Spot is not available for ARM64 tasks, so services already on Fargate Spot may save more where they are.
- To roll back, update the service to the previous x86 task definition revision.
FAQs
Why is the recommendation per cluster and not per service?
Why is the recommendation per cluster and not per service?
Fargate billing identifies the cluster each task ran in. Check which services in the cluster run x86 tasks and move each one.