ECS vs EKS: Similarities and Differences
Have you wondered what the difference is between Amazon ECS and EKS? This is a good comparison between the two.
Life became a LOT easier for us when we switched from hand-stitched EC2-based Kubernetes clusters to EKS-based Kubernetes clusters.
The biggest pain point we've run into so far is AWS has an auto-marching upgrade cycle and if you are not Johnny-on-the-spot keeping your clusters upgraded, they will happily do it for you. (This is fine if you're using the AWS Console or CLI to create/manage clusters but if you're deploying them with Terraform, the threat of disruption is a great motivating factor to keep things up to date.)
@t3hbeowulf Excellent insights here. I am guessing with Terraform, you have to go in and update your TF files for target versions that match the upgraded cluster versions, etc? I know I have seen that as an issue with Amazon RDS. They will upgrade the major version and will break some Terraform config expecting a different RDS version.
It's a bit more of a mess than that. When AWS changes the cluster that is provisioned by Terraform, the TF state is diverges from the deployed configuration. Updating your TF configs isn't enough... Terraform expects to be able to use the AWS Provider to make the deployed resource match state and will fail since it cannot reconcile its state with the out-of-band upgraded cluster.
The "clean" resolution is to destroy and recreate the cluster.
The "dirty" resolution is to try and import the remote resources into TF state. _This is fraught with peril._
The "right" solution is don't get into that situation in the first place. Keep things up to date. 🙃
As for RDS, yes... that happens too and if you're not careful, Terraform will destroy and recreate the DB to reconcile with state. Thankfully, importing state or taking and restoring a snapshot is less disruptive than dealing with an entire EKS cluster.