In this article, we are going to see how to achieve a Blue-Green deployment strategy with canary tests using AWS ALB and terraform scripts. Blue-green deployments and canary tests(rolling deployment) are deployment strategies that are often used by DevOps engineers to release new software gradually This strategy helps us to[...]
Read moreCategory: Terraform
Clone EC2 instance using Terraform - How to | Devops Junction
This is a familiar requirement for everyone I believe. How to clone an EC2 instance and create a new instance with the same configuration. While we want to launch multiple EC2 instances of the same configuration there are multiple ways we follow. Creating Auto Scaling Group or Launch Template Create[...]
Read moreClone EBS Volumes between AWS EC2 with Pulumi | Devops Junction
I had an Infrastructure as an automation requirement recently, where I had to create a solution that will find EBS volumes attached to an EC2 instance and create snapshots of the same and clone it and attach these cloned volumes to another EC2 instance. I know it was a little[...]
Read moreCreating EKS Cluster with SPOT instances - Terraform | Devops Junction
In this article, we are going to see how to create an EKS Cluster with SPOT and OnDemand instances using Terraform. If you have prior experience with AWS, you might know what is SPOT instances and ondemand instances are. Let us start with a quick introduction towards SPOT instances. Quick[...]
Read moreTerraform For Each Examples - How to use for_each | Devops Junction
In this post, we’ll try to cover Terraform looping constructs. We’ll cover the looping constructs that specifically work at the resource level. They handle resource creation itself. There are two Looping constructs. count: This is often brought up when talking about looping with Terraform. for_each: This technique is similar to the count[...]
Read moreTerraform remote state datasource Example - GCP | Devops Junction
In this article, we are going to see what is terraform data source is and how it helps in Infrastructure as code Before we begin, I want you to think of this requirement. "Let's say you have to create two similar infrastructure modules in two different regions of any of[...]
Read moreStore terraform state file on Terraform cloud Remote | Devops Junction
In this article, I am going to discuss how we can keep safe our terraform state file using terraform cloud. As a pioneer/Practioner of Terraform CLI, we hold responsible for Terraform state file which is the source of truth for our infrastructure. What if we lose this state file or[...]
Read moreTerraform Create Multiple EC2 with different Configs - for_each and count together
Those who have been using Terraform might already know that you can create multiple numbers of the same resources with the help of count or for_each But What if we want to create multiple resources with different configurations at the same time. For example. we can easily create No of[...]
Read moreTerraform AWS EC2 user_data example - aws_instance| Devops Junction
In this article we are going to see how to create AWS EC2 instance with user_data. While launching AWS Ec2 instances we might want to add some customizations to it like adding a key and executing few shell commands or scripts to make sure they are ready to launch your[...]
Read moreTerraform google_compute_instance Example - with Remote Exec
In this article, we are going to see how to create a Linux Virtual machine and provision it using the Terraform remote execution strategy. We are going to be using SSH method to connect to the Virtual machine and provision it on the go by executing some startup Shell script.[...]
Read more