DEV Community

Discussion on: From EC2 to Kubernetes on EKS

Collapse
 
fiantyogalihp profile image
Fiyuu

Why must migrate to EKS from EC2? What's the pros and cons?

Collapse
 
guilleojeda profile image
Guille Ojeda AWS Community Builders

The cons of running your app in a single EC2 instance are that it doesn't scale, and it fails if the instance fails. Some options to fix that are an auto scaling group, migrating to Lambda, or using an ECS or EKS cluster. If you're running several separate services, ECS or EKS are a great choice to let them scale independently and make management much easier.

Choosing EKS or ECS (I wrote a very similar guide from EC2 to ECS) is a big topic. I generally prefer ECS, if you don't care for cloud vendor lock-in. EKS makes you more independent (not 100% independent though) from the cloud vendor, and will let you re-use more easily apps that are published as Helm charts (in some domains like data processing lots of apps are already available as Helm charts). It's also harder to learn and use.