Terraform Course - Automate your AWS cloud infrastructure

freeCodeCamp.org · 2.2M views · 2020 · 2:20:58

Open on YouTube

Cloud, DevOps & reliabilityEducation & learningcourse

Why Stack Overflow recommends it

Stack Overflow users cite it as the tutorial they were following when they hit Terraform and AWS errors, such as an EC2 instance that won't come up or a malformed gateway ID.

Recommended by 0 people across 0 different months, 2021 to 2023.

What it is

A 2h20m freeCodeCamp beginner course by Sanjeev Thiyagarajan on Terraform, covering AWS account setup, installing Terraform on Windows, Mac and Linux, and core concepts like state, outputs, variables and targeting resources. It ends with a practice project that builds a VPC, subnet, security group and a simple web server on AWS.

What people said

Cites Nahum · 2021-04 · Stack Overflow · on “Terraform error: error creating route: InvalidEgressOnlyInternetGatewayId.Malformed”

thanks for the reply. The code came from a course online, i followed the course step by step. [this video] I pasted the full code here, but i had some issues to upload it. if you would like to see the full code you can click the link i attached, and see everything.

Cites kanhaiyakumar · 2021-09 · Stack Overflow · on “unable to access EC2 instance created using terraform”

I have been following [this video] to learn terraform and have followed each steps. After running terraform apply it was able to setup everything as expected. I have verified this on aws console. But while trying to access the public ip it is saying connection refused. Below is the content of my main.tf file. provider "aws" { region = "us-east-1" access_key = "ACCESS-KEY" secret_key = "SECERT-KEY" } # VPC resource "aws_vpc" "prod-vpc" { cidr_block = "10.0.0.0/16" tags = { Name = "production" } } # create internet gateway resource "aws_internet_gateway" "gw" { vpc_id = aws_vpc.prod-vpc.id tags = { Name : "Prod gateway" } } # create custom route table resource "aws_route_table" "prod-route-table" {

Cites steh88 · 2022-09 · Stack Overflow · on “Assistance with deploying EC2 instance via terraform”

I am new to terraform and I am just working in a lab environment at the moment so I hope someone can help me and point me in the right direction as to where I am going wrong. I am following this video for reference [this video] . I am running terraform V1.2.9 I run a terraform init command and everything initialises, but when I run a terraform plan I get this error "No changes. Your infrastructure matches the configuration. Terraform has compared your real infrastructure against your configuration and found no differences, so no changes are needed." This is my code for reference terraform { required_providers { aws = { source = "hashicorp/aws" version = "~> 4.16" } } required_version = ">= 1.2.0"

Cites ok7877 · 2023-05 · Stack Overflow · on “Cannot understand why EC2 instance is not getting created whereas everything else such as VPC, route tables, security groups were created just fine?”

I've been trying to run the below code which I copied off a YouTube tutorial I was following ( [this video] ). My EC2 instance just isn't getting created and I also checked the AWS console which doesn't show anything. Everything else appears fine as a I mentioned the VPC, subnet, route table, Internet gateway all got created as expected. Here is the code I tried to run on windows Powershell: # Create Ubuntu server and install/enable apache2 resource "aws_instance" "web-server-instance" { ami = "ami-0aa2b7722dc1b5612" instance_type = "t2.micro" availability_zone = "us-east-1" key_name = "main-keyy" I am given the below by terraform once I hit terraform apply: [0m[1maws_vpc.prod-vpc: Creating...[0m