Reputation: 3097
Why does Task Definitions need Memory and CPU and Volumes when creating Task Definitions? Containers need CPU and Mem which makes sense. But why does Task Definitions need that?
I understood it as the name implies its just a task but now I'm wondering what it is?
Upvotes: 2
Views: 1150
Reputation: 238081
Your task definition can contain multiple containers. So task-level CPU and memory are hard limits on the cumulative usage of the containers in the task.
For EC2 type tasks, the task-level CPU and memory are optional. In contrast, for Fargate they are required, and used by Fargate to provision resources for you that would be sufficient to run the task and all its containers.
Upvotes: 5