4.39 out of 5
4.39
3790 reviews on Udemy

Learn DevOps: Infrastructure Automation With Terraform

Learn how to automate your infrastructure with terraform. Covers Terraform with AWS, Packer, Docker, ECS, EKS, Jenkins
Instructor:
Edward Viaene
19,855 students enrolled
English More
Understand, use and apply terraform
Know when to use different features
Use terraform with AWS
Use terraform with Packer to create custom images
Be able to apply DevOps techniques using terraform

Terraform has gained a lot in popularity lately and is the tool you need to master if you are or about to get into a Ops / DevOps role. You typically use a technology like Ansible, Chef, or Puppet to automate the provisioning of software. Terraform starts from the same principle, infrastructure as code, but focusses on the automation of the infrastructure itself. Your whole Cloud infrastructure (instances, volumes, networking, IPs) can be described in terraform. 

In this course you’ll learn how to use terraform to automate your infrastructure. I will first show you the basics of terraform and will then explain how to automate infrastructure on AWS using terraform. You can open an AWS account for free to do the labs. I also provide a lot of code examples which you can immediately use to automate your own infrastructure.

Update (Oct-2016):

  • Added AWS Autoscaling lectures
  • Added Terraform+Packer Jenkins integration lectures
  • Added Terraform with Docker on AWS (ECR and ECS)
  • Added Terraform with Jenkins workflow using ECR and ECS

Update (Dec-2016):

  • Added a lecture about useful terraform commands
  • Added a demo on how to use terraform show/graph/taint/untaint/import
  • Added a lecture and demo about Elastic Beanstalk on AWS

Update (Jun-2018):

  • Terraform for Windows setup + puttygen
  • Interpolation
  • Conditionals
  • Built-in functions
  • Module development with an ECS + ALB module demo
  • Setting up a hosted Kubernetes cluster using AWS EKS

This course includes english captions.

Course Introduction

1
Course Introduction
2
Discussions and Support
3
Procedure Document

Contains useful information for this course

4
Important Note on terraform 0.12

Introduction to terraform

1
Introduction

Introduction to what terraform is.

2
Terraform installation

An explanation of how to install terraform on Windows / MacOS / Linux

3
Terraform Installation (on Windows)
4
Terraform installation using Vagrant

An alternative installation procedure using Vagrant. This will allow you to use exactly the same setup I have!

Terraform basics

1
First steps in terraform - AWS Setup

First steps in terraform: learn how to spin up your first instance

2
First steps in terraform - Spinning up an instance

First steps in terraform: learn how to spin up your first instance

3
First steps in terraform - summary

Summary of the first steps in terraform

4
Quiz 1

Test your knowledge

Terraform basics

1
Variables

How to use variables in terraform

2
Demo: variables

A demo of how to use variables in terraform

3
Software Provisioning

Provision software on your instance using chef / ansible / puppet / shell scripts.

4
Demo: Software provisioning

A demo to show you how to provision software using a shell script

5
Demo: Windows Server Provisioning

In this demo I'll show you how to use WinRM to provision a Windows Server

6
Outputting attributes

Using outputs in terraform you can output information on screen

7
Demo: Outputting Attributes

A demo showing how outputs work

8
Remote state

The terraform.tfstate can be stored remotely. This helps collaboration when using Terraform within a team. 

9
Demo: Remote state

This demo shows how to store the remote terraform state in an S3 bucket. By changing a few flags you can also use it to save it to a consul cluster.

10
Data Sources

You can use datasources to retrieve external information like AWS IP addresses, AMI IDs, and so on.

11
Demo: Data Sources

A demo using the AWS Region IP ranges to create a security group that only allows access from eu-west-1 and eu-central-1 in AWS.

12
Templates

You can use a template provider in terraform to render templates into strings

13
Other Providers

There's more than just AWS in terraform. An overview of other providers.

14
Modules

An overview on how to use modules in terraform

15
Demo: An external Module

A demo showing you how to use external modules. This demo will launch a full consul cluster using an external terraform module

16
Terraform Commands Overview

An overview of useful terraform commands

17
Demo: Terraform Commands

A demo of a few useful terraform commands, including terraform show, terraform graph, terraform import, terraform taint, terraform untaint

18
Quiz 2

Test your knowledge!

Terraform with AWS

1
Introduction to VPCs

An introduction to AWS VPCs (Virtual Private Cloud) - Part 1

2
Introduction to VPCs - Part II

An introduction to AWS VPCs (Virtual Private Cloud) - Part 2

3
Introduction to terraform - Part III

An introduction to AWS VPCs (Virtual Private Cloud) - Part 3

4
Demo: VPCs and NAT

A demo showing you how to launch a VPC with an internet gateway and a NAT gateway

5
Launching EC2 instances in the VPC

Now that we have created our VPC, we can launch EC2 instances in the VPC

6
Demo: Launching instances in a VPC

This is a demo showing you how to launch instances within a VPC

7
Quiz 3

Test your knowledge!

8
EBS Volumes

This lecture shows you how to use EBS (Elastic Block Storage) with an instance

9
Demo: EBS volumes

This demo shows you how to attach EBS volumes to EC2 instances

10
Userdata

Userdata can be used to execute commands at launch time

11
Demo: Userdata

In this demo userdata will be used to format and mount an EBS volume if no filesystem is present. This way EBS volumes can be persisted in an automated way when the instance needs replacement.

12
Static IPs, EIPs, and Route53

This lecture explains the difference between private static IPs, EIPs and DNS (Route53)

13
Demo: Route53

This demo shows how to use Route53 to create DNS zones in AWS

14
RDS

This lecture explains how to spin up an RDS (relational database service) instance with terraform on AWS

15
Demo: RDS

In this demo I will spin up an RDS instance (using RDS subnets, RDS parameter groups, and security groups) and will connect from an EC2 instance to MariaDB..

16
IAM

IAM stands for Identity & Access Management. In this lecture I explain the different possibilities for access management. I explain users, groups, policies, and roles.

17
Demo: IAM users and groups

In this demo I create a group with an AWS group policy and attach it to a user.

18
IAM Roles

IAM roles can be used to assume (temporary) access. In this lecture I explain how this works.

19
Demo: IAM Roles

IAM roles can be used to assume (temporary) access. In this lecture I show you how to attach a role to an EC2 instance that will give permissions to read/write to an S3 bucket.

20
Autoscaling

A lecture explaining how to setup autoscaling in AWS using terraform

21
Demo: Autoscaling

A demo of autoscaling using terraform on AWS

22
Introduction to Elastic Load Balancers (ELB)

Introduction into Elastic Load Balancers and Application Load Balancers in AWS

23
ELBs in terraform

This lecture explains how to use ELBs in terraform with a static list of instances and an autoscaling group

24
Demo: ELB with autoscaling

A demo showing how to use terraform with an ELB together with autoscaling

25
Application Load Balancer (ALB)

An introduction of how the Application Load Balancer (ALB) works in terraform

26
Elastic Beanstalk

ElasticBeanstalk (AWS's PaaS solution) setup using Terraform

27
Demo: Elastic Beanstalk

ElasticBeanstalk (AWS's PaaS solution) setup demo using Terraform

28
Quiz 4

Test your knowledge!

Advanced Terraform Usage

1
Introduction to Interpolation
2
Conditionals
3
Demo: Interpolation and Conditionals
4
Built-in Functions
5
Demo: Built-in Functions
6
Terraform Project Structure
7
Demo: Project Structure in Terraform

Packer

1
Packer introduction

With packer AMIs can be created that can be used to launch an EC2 instance.

2
Demo: Packer with terraform

Packer can be integrated with terraform. This workflow shows how to create a workflow where packer creates the AMI and terraform launches the EC2 instance with the correct AMI ID

3
Terraform with Packer and Jenkins

Where does Terraform fit in the DevOps organization? In this lecture I show you an example workflow with terraform, packer and jenkins

4
Demo: Jenkins with Terraform and Packer

This demo shows a full cycle of an app in github, the building of a custom AMI with packer in Jenkins and the provisioning and deployment with Terraform

5
Quiz 5

Test your knowledge

Docker on AWS using ECS and ECR

1
Introduction to Docker

This lectures gives an introduction of Docker

2
Docker on AWS

This lecture explains how to use Docker on AWS using terraform

3
Building Docker images

This lecture shows how to build docker images that can be pushed on ECR

4
Demo: Build NodeJS app and push to ECR

In this demo I show how to push a docker built image to ECR

5
ECS - Part I

This lecture explains part I of the setup of ECS using terraform, with autoscaling and IAM roles

6
ECS - Part II

This lecture explains part II of the setup of ECS using terraform, with autoscaling, IAM roles, ECS task definitions and ECS Service definitions

7
Demo: Running a NodeJS app on ECS

This demo shows you how to run the pushed NodeJS app on ECS

8
Demo: Terraform with Jenkins, ECR and ECS

In this demo I show you how to run a Jenkins workflow to build docker images, push the image to ECR, and use terraform to update ECS with the latest docker image

Module Development

1
Introduction to Module Development
2
ECS + ALB Module Overview
3
Demo: ECS + ALB Module (part I)
4
Demo: ECS + ALB Module (Part II)
5
Demo: ECS + ALB Module (Part III)

AWS EKS (hosted Kubernetes)

1
Introduction to AWS EKS
2
Demo: AWS EKS

Course Completion

1
Congratulations

Course Completion lecture

2
Bonus Lecture: My Other Courses
You can view and review the lecture materials indefinitely, like an on-demand channel.
Definitely! If you have an internet connection, courses on Udemy are available on any device at any time. If you don't have an internet connection, some instructors also let their students download course lectures. That's up to the instructor though, so make sure you get on their good side!
4.4
4.4 out of 5
3790 Ratings

Detailed Rating

Stars 5
1718
Stars 4
1486
Stars 3
476
Stars 2
85
Stars 1
33
be59fd642737dbe452630351277c525c
30-Day Money-Back Guarantee

Includes

7 hours on-demand video
2 articles
Full lifetime access
Access on mobile and TV
Certificate of Completion