Love containers but hate managing the infrastructure they run on? If so, AWS Fargate may be for you.

On the other hand, Fargate isn’t the only way to simplify container infrastructure management. Depending on your specific needs, it may be best to leverage one of AWS’ other solutions for infrastructure management.

Read on for a dive into what Fargate does and why you may or may not want to use it.

What is AWS Fargate?

Fargate is an optional way to deploy containers on Elastic Kubernetes Service (EKS) and Elastic Container Service (ECS), the two managed container services in the AWS Cloud.

When you use Fargate to deploy containers on EKS or ECS, Fargate automates most of the tasks needed to set up and manage the host infrastructure. Specifically, Fargate automatically provisions host servers (or nodes) and scales them up or down to accommodate changes in your application demand.

AWS calls Fargate a “serverless compute engine.” It does, in the sense that Fargate eliminates the need to manage servers when deploying containers in the AWS Cloud.

What problems does AWS Fargate solve?

The main problem that Fargate solves is the challenge of managing the infrastructure to host the containers.

Modern container tools already solve most other problems associated with deploying and managing containerized applications. You can use continuous integration/continuous delivery (CI/CD) software to automatically create containers. You can manage container images in a simplified way with container registries. You can orchestrate container instances, load balance, and automate other orchestration tasks using Kubernetes.

The one thing standard container platforms don’t do, however, is configure the host infrastructure for you, or scale that infrastructure as your load fluctuates.

With Fargate, you can deploy containers without worrying about the underlying infrastructure. You simply load your container images into EKS or ECS, and Fargate runs them. The infrastructure is managed for you, automatically.

Do you have to use Fargate to use EKS or ECS?

As mentioned above, Fargate is an optional deployment mode for EKS and ECS. You can use it if you use one of these services, but you don’t have to.

EKS and ECS work fine without Fargate. In this case, you just need to manage the host infrastructure yourself – usually, at least.

I say “generally” because AWS provides two other features that help automate container infrastructure management independent of Fargate:

  • Groups of managed nodes, a feature of EKS that automatically provisions nodes for you.
  • Automatic scaling of clusters, a feature available in both ECS and EKS that automatically adds or removes servers from your container environment in response to load changes.

Like Fargate, both of these features are optional. But when enabled, they more or less serve as Fargate alternatives as they automate most infrastructure-related management tasks.

Fargate vs managed node groups vs autoscaling

That said, there are subtle differences between Fargate, managed node groups, and autoscaling.

The main reason to choose Fargate over the other two solutions is simplicity: Fargate requires virtually no configuration. With the other features, you have to do more work to tell AWS how to manage your nodes.

On the other hand, the trade-off for simplicity is less control. With Fargate, you completely entrust the management of the infrastructure to AWS. You cannot set parameters that define when or how often your servers are scaled.

When AWS Fargate is not an option

Also note that in some use cases, Fargate just isn’t an option. It is not available in all AWS Regions. Also, Fargate is not currently supported on AWS Outposts Where EKS anywhere, Amazon’s hybrid cloud services.

Depending on your AWS setup, you might need to run ECS or EKS without using Fargate.

So who needs Fargate?

For most people, however, AWS Fargate is a convenient way to minimize the effort required to run containers in the Amazon cloud. But the main trade-off is controlling your host infrastructure. If you want full control over how your infrastructure is provisioned and scaled, use ECS or EKS in standard mode. Alternatively, if you want help managing the infrastructure but don’t want to go as far as Fargate, consider autoscaling or managed node groups instead.

About The Author

Related Posts