Posts

Showing posts from March, 2019

AWS Infrastructure with Terraform

Create Terraform modules for AWS and provision AWS Infrastructure Create dir ############ shashanksrivastava@197nodnb23093:~$ mkdir aws-terraform shashanksrivastava@197nodnb23093:~$ cd aws-terraform/ shashanksrivastava@197nodnb23093:~/aws-terraform$ ls shashanksrivastava@197nodnb23093:~/aws-terraform$ mkdir ec2 s3 Create modules for s3 ################# shashanksrivastava@197nodnb23093:~/aws-terraform$ mkdir modules shashanksrivastava@197nodnb23093:~/aws-terraform$ cd modules/ shashanksrivastava@197nodnb23093:~/aws-terraform/modules$ mkdir s3 shashanksrivastava@197nodnb23093:~/aws-terraform/modules$ cd s3/ shashanksrivastava@197nodnb23093:~/aws-terraform/modules/s3$ vim main.tf provider "aws" {   region  = "${var.aws_region}" } resource "aws_s3_bucket" "s3_bucket" {   bucket = "${var.bucket_name}"   acl    = "${var.bucket_acl}"   versioning {       enabled = "${var.versioning_enabled}"  ...