Skip to content

Terraform workflow#1

Open
shikharbhardwaj3110 wants to merge 2 commits intoPromact:mainfrom
shikharbhardwaj3110:terraform-workflow
Open

Terraform workflow#1
shikharbhardwaj3110 wants to merge 2 commits intoPromact:mainfrom
shikharbhardwaj3110:terraform-workflow

Conversation

@shikharbhardwaj3110
Copy link
Copy Markdown

Terraform Script:

  • Provisioned an AWS ECS cluster of EC2 type.
  • Included an Auto Scaling Group for dynamic instance scaling.
  • Configured an Application Load Balancer (ALB) for distributing traffic.
  • Implemented appropriate networking components:
  • Created a Virtual Private Cloud (VPC).
  • Defined subnets within the VPC.
  • Configured security groups to control inbound and outbound traffic.
  • Applied permissions as needed for ECS resources.

YAML Workflow File for CI/CD Pipeline:

  • Added a YAML workflow file for the CI/CD pipeline.
  • Defined pipeline stages and jobs for building, testing, and deploying infrastructure.
  • Integrated with Terraform for infrastructure provisioning.
  • Configured triggers for automatic execution on code changes.
  • Specified deployment steps for updating the ECS cluster.
  • This setup aims to automate the process of building and deploying your AWS ECS infrastructure, ensuring consistency and efficiency in your development workflow.

Steps to run

  • Change Github Secrets appropriately by comparing with main.yml file
  • Simply add terraform apply -auto-approve in workflow file main.yml in step name: Provision underlying infrastructure for ECS Cluster to provision the infrastructure for app image for the application.

Note

  • The certificate.pfx was flagged as expired by AWS ACM, forcing me to change container port to 80 as well as load balancer listener port to 80.
  • The tasks for application are no running as expected in ECS Cluster Services, hence resulting in 503 Service Temporarily Unavailable ERROR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants