- Creatoin of FastAPI Service
- Contanerize the application using Docker Client
- Upload the Docker Image to Docker Hub
- Create a Elastic Container Repository (ECR) with Terraform
- Upload the Docker Inage to Elastic Container Repository (ECR) by cmd line
- Create a Cluster with Terraform
- Create Task defination in Cluster, assign resource type like CPU, Memory with Terraform
- Create Service as Fargate and Fargate Spot
- Create a Capacity provider strategy, if Fargate Spot is available use it primilarily and if failed then use Fargate with Terraform
- Deploy ECR Image to ECS Cluster and run the task in the service we created earlier.
- hence, the final
Public IP
will be the hosted service and ready to use it.
-
Notifications
You must be signed in to change notification settings - Fork 0
Jacer7/fastapi-fargate
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
Terraform code with FastAPI service for backend and host it to AWS FARGATE and FARGATE SPOT
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published