UCL-MIRSG / xnat-aws

Deploy XNAT on AWS
MIT License
2 stars 0 forks source link

Use EKS and Fargate for the Container Service #76

Open p-j-smith opened 1 year ago

p-j-smith commented 1 year ago

To reduce the cost of running the workshop we could use the Elastic Kubernetes Service to deploy containers with Fargate

I've created a branch feat/eks where I've started to remove the current EC2 instance that runs the Container Service and replace it with EKS. It's using the [terraform-aws-eks]() module to create a cluster with a managed node group.

However, I've just realised that this approach (with managed nodes) means the worker nodes are always running, even when no containers are running. So this wouldn't help reduce the cost of running the workshop. Instead we should try using Fargate.

There are some tutorials on setting up EKS with terraform-aws-eks:

There are some docs on using Kubernetes with the Container Service, and some scripts to create a kube config that is compatible with the Container Service (the kube config generated by aws eks update-kubeconfig cannot be used with the Container Service)

p-j-smith commented 1 year ago

Other links that may be useful for getting the EFS volume working with EKS:

p-j-smith commented 1 year ago

There are lots of tutorials here for terraform / kubernetes / aws:

milanmlft commented 1 year ago

WIP on the feat/eks branch.