Posts

Showing posts from June, 2021

Creating workspaces using Terraform Cloud

Image
 Hello, readers. Today we will see the creation of workspaces, which exist in Terraform cloud, and which can further help in maintaining multiple clouds infrastructure. Let's look into Terraform Cloud briefly. Terraform cloud  is a self-hosted SaaS product that provides services to help teams and organizations collaborate, manage, maintain a consistent environment, and most importantly, automate the process and work as a team. So, let's start now! There are two prerequisites for the process, a GitHub and an AWS Account. GitHub repository with Terraform configuration files. If you don’t have files, fork the repo  https://github.com/tithichoudhary/My-Terraform-Cloud1 AWS account as we are going to provision resources on AWS. You can Signup here   http://console.aws.amazon.com/ 1. Sign Up and Create an Organization Let us create an organization to manage workspaces. Once the account is verified, you will land on the page to create an organization. Provide an appropriate...

Creating custom Terraform module - creating submodule for s3 bucket resource from the AWS provider.

Image
Hello, readers. Today we will look into creating custom modules using Terraform. And in this blog, we will look into creating a submodule for the s3 bucket resource from the AWS provider. The code exists with double inverted commas, within which you need to edit your own required names for the buckets and various other things. Let's start with the process. Module Structure Terraform treats any local directory referenced in the source  argument of a module  block as a module. A typical file structure for a new module is: . ├── LICENSE ├── README.md ├── main.tf ├── variables.tf ├── outputs.tf Creating Module You'll need to create the directory for your module. Inside your existing configuration directory, create a directory called  modules , with a directory called  aws-s3-static-website-bucket  inside of it. And inside them, you can create the empty files as shown in the structure section above. Thus, now your skeleton should look like this: modules └── aws-s3-st...

Hosting Webpage on AWS EC2 using Terraform

Image
Hello, readers. Today we will be looking into the concept of hosting a static webpage by making use of EC2 instance, with the help of Terraform. Here is how the process flow will be for the objective: Launching a VPC Create EC2 instance in this VPC Launch Webserver using apache  Create an index.html file having content about your skills.  Start the webserver on port 80 Create the snapshot of volume attached with the EC2 instance.  Destroy all the resources created in this task.  Step 1: Launching VPC There are two methods to go through, either manually creating the required VPC, or using terraform code to create one Manual Method: In this method, you just need to give a name for the VPC and define the value for the IPv4 CIDR block. The VPC automatically gets created in your default region. Code Method: provider   "aws"  {            region   =   "ap-south-1"       ...

Integrating MySQL and WordPress to AWS instance using Terraform

Image
Hello, readers. Today we will be seeing the integration of MySQL and Wordpress to an AWS Instance. Terraform and AWS Terraform is a tool for building, changing, versioning infrastructure safely and efficiently. Terraform can manage existing and popular service providers as well as custom in-house solutions. The infrastructure terraform can manage includes low-level components such as compute instances, storage, and networking, as well as high-level components such as DNS entries, SaaS features, etc. Amazon Web Services (AWS) is a subsidiary of Amazon that provides on-demand cloud computing platforms and APIs to individuals, companies, and governments, on a metered pay-as-you-go basis. In Aggregate, these cloud computing web services provide a set of primitive abstract technical infrastructure and distributed computing building blocks and tools. The task at hand: 1. Create an AWS EC2 instance. 2. Configure the instance with Apache Webserver. Download PHP application name ""Wor...

How Unilever Benefitted by Transforming into Cloud-Based Digital-Market Empire

Hello, readers. Today, in this post, we will see a case study about how a company, Unilever, changed its dynamic in the era of new technology and started using AWS cloud-based services for the process of digital marketing. How they shifted from on-premise data storage to cloud infrastructure implementation. In- brief about Unilever's Heritage Unilever  was formed in 1930 by the merger of Dutch margarine producer, Margarine Unie, and British soap maker, Lever Brothers. Today, the consumer goods giant sells food, home care, refreshments, and personal care products in over 190 countries. Unilever has headquarters in London, United Kingdom, and Rotterdam, the Netherlands, and subsidiaries in over 90 countries. The company employs more than 170,000 people. In 2012, Unilever reported more than €51 billion in revenue.  The New Change The idea started with Unilever North America in Englewood Cliffs, New Jersey needing to re-design its infrastructure to support Unilever’s digital ...