Slide 1

Slide 1 text

How to Get Your Website Into the Cloud

Slide 2

Slide 2 text

Sr. Developer Advocate at HashiCorp he / him @ksatirli Kerim Satirli

Slide 3

Slide 3 text

Infrastructure as Code 01

Slide 4

Slide 4 text

Challenge: Be a Lazy Engineer.

Slide 5

Slide 5 text

resource "compute_instance" "os101_website" { count = 10 image = "rhel-7.0" type = "small" has_public_ip = true region = "us-east-nc" } Infrastructure as Code server.tf

Slide 6

Slide 6 text

resource "compute_instance" "os101_website" { count = 10 image = var.image type = var.type has_public_ip = var.has_public_ip region = var.region } Infrastructure as Code server.tf

Slide 7

Slide 7 text

your code is executable documentation versioned code supports collaboration workflows become safer and more predictable code is text and can be versioned Recap

Slide 8

Slide 8 text

Let’s Build A Website 02

Slide 9

Slide 9 text

A Website https://opensource101.fun/

Slide 10

Slide 10 text

A Website needs a place to put HTML, CSS, JS, images, etc. needs TLS certificate optionally: needs a CDN to handle all of the traffic needs a domain, DNS Zone, and DNS records

Slide 11

Slide 11 text

terraform.io/downloads

Slide 12

Slide 12 text

Install Terraform https://developer.hashicorp.com/terraform/downloads

Slide 13

Slide 13 text

opensource101.fun/repo

Slide 14

Slide 14 text

Clone the Repository https://github.com/ksatirli/get-your-website-into-the-cloud

Slide 15

Slide 15 text

git clone [email protected]:ksatirli/get-your-website-into-the-cloud.git Clone the Repository Terminal Cloning into 'get-your-website-into-the-cloud'... remote: Enumerating objects: 36, done. remote: Counting objects: 100% (36/36), done. remote: Compressing objects: 100% (31/31), done. remote: Total 36 (delta 4), reused 29 (delta 2), pack-reused 0 Receiving objects: 100% (36/36), 19.55 KiB | 2.79 MiB/s, done. Resolving deltas: 100% (4/4), done.

Slide 16

Slide 16 text

cd get-your-website-into-the-cloud Inspect the Code Terminal

Slide 17

Slide 17 text

Inspect the Code tree . . ├── LICENSE ├── README.md ├── dns.tf ├── github.tf ├── outputs.tf ├── providers.tf ├── templates ├── terraform.tf ├── terraform.tfvars.sample ├── variables.tf └── website.tf Terminal

Slide 18

Slide 18 text

Initialize Terraform terraform init Terminal Initializing the backend... Initializing modules... Initializing provider plugins... - Installed go-gandi/gandi v2.2.3 (self-signed) - Installed integrations/github v5.18.3 (signed by a HashiCorp partner) - Installed hashicorp/local v2.4.0 (signed by HashiCorp) - Installed hashicorp/random v3.4.3 (signed by HashiCorp) - Installed hashicorp/aws v4.59.0 (signed by HashiCorp) Terraform has been successfully initialized!

Slide 19

Slide 19 text

Terraform Registry https://registry.terraform.io/

Slide 20

Slide 20 text

Hands-On Workshop

Slide 21

Slide 21 text

Next Steps 03

Slide 22

Slide 22 text

HashiCorp Developer Zone https://developer.hashicorp.com/terraform/

Slide 23

Slide 23 text

Thank you speakerdeck.com/ksatirli