HumanGov: Proof of Concept (POC) on AWS Elastic Container Service (ECS) fronted By Application Load Balancer (ALB) and Storing Docker Images on Elastic Container Registry (ECR)

Gabriel Varaljay
3 min readJan 6, 2024

--

Project Description:

During my latest hands-on project, I ventured into the complex and fascinating world of cloud architecture and deployment. My primary focus was on the HumanGov application, a candidate for modernisation and deployment within the AWS Cloud environment.

1. Initial Set-Up and Containerisation

The journey began with establishing foundational elements. I crafted the necessary IAM roles, ensuring secure and proper access to AWS services. Next was the initialisation of the AWS Cloud 9 environment. This involved cleaning up any outdated directories to prepare for the transition of our application.

The crux of this phase involved containerising the HumanGov application using Docker. This critical step was transforming our application into a portable and scalable solution. I meticulously built and pushed our Docker images to AWS ECR, including images for both the Flask app and the NGINX server, ensuring every layer was correctly configured.

2. Infrastructure Provisioning with Terraform

Leveraging the power of Terraform, I provisioned an AWS S3 Bucket and a DynamoDB table. Terraform’s Infrastructure as Code capability enabled me to instantiate, modify, and version our infrastructure securely and efficiently.

3. Deployment on Elastic Container Service (ECS)

With our infrastructure in place, I focused on the Elastic Container Service (ECS). After creating an ECS cluster, I meticulously developed a Task Definition for our ECS deployment. This definition was crucial, outlining the containers’ roles, configurations, and essential settings from environment variables to port configurations.

4. Final Deployment Phase

The culmination of these efforts led to the final deployment phase. I configured a service on ECS, opting for Fargate as the launch type. This facilitated the integration of our Docker containers, AWS configurations, and the resources needed for optimal application performance.

5. Results and Learning Outcomes

The outcome was a fully functional, scalable, and resilient HumanGov application hosted on the cloud. This project gave me a deep dive into the nuances of cloud deployment processes. I gained valuable insights into IAM role creation, Docker containerisation, the utilisation of AWS ECR and ECS, and the power of Terraform in cloud infrastructure management.

Personal Takeaways

This project has been a substantial learning journey. I’ve garnered in-depth knowledge and practical experience in cloud deployment, which are vital skills for my career advancement as a Cloud Engineer, Platform Engineer, or DevOps Engineer.

In summary, this project honed my technical skills and reinforced my appreciation for the endless possibilities cloud technologies offer. Each step was a lesson in best practices, troubleshooting, and the expansive potential of the cloud.

--

--

Gabriel Varaljay

Multi-Cloud & DevOps | AWS | Microsoft Azure | Google Cloud | Oracle Cloud | Linux | Terraform | digital problem solver