Slide 1

Slide 1 text

Taming Infrastructure Workflow at Scale https://unsplash.com/photos/-a4tzI2fNW8 Photo by Rita Morais @build1point0 

Slide 2

Slide 2 text

$ whoami @build1point0 Anubhav Mishra Technical Advisor to the CTO, HashiCorp

Slide 3

Slide 3 text

No content

Slide 4

Slide 4 text

No content

Slide 5

Slide 5 text

No content

Slide 6

Slide 6 text

No content

Slide 7

Slide 7 text

Open Source

Slide 8

Slide 8 text

Atlan&s Open Source

Slide 9

Slide 9 text

Vault in Action Book

Slide 10

Slide 10 text

Gopher Artwork by Ashley McNamara

Slide 11

Slide 11 text

No content

Slide 12

Slide 12 text

PRIVATE CLOUD AWS AZURE GCP Run Development Connect Networking Secure 
 Security Provision Operations HashiCorp Suite

Slide 13

Slide 13 text

Evolution

Slide 14

Slide 14 text

Copyright © 2019 HashiCorp @build1point0  DATACENTER Evolution !11 ~30 years ago

Slide 15

Slide 15 text

Copyright © 2019 HashiCorp @build1point0  DATACENTER Evolution !12 ~20 years ago

Slide 16

Slide 16 text

Copyright © 2019 HashiCorp @build1point0  DATACENTER Evolution !13 ~15-20 years ago

Slide 17

Slide 17 text

Copyright © 2019 HashiCorp @build1point0  DATACENTER Evolution !14 ~10 years ago

Slide 18

Slide 18 text

Copyright © 2019 HashiCorp @build1point0  DATACENTER Evolution !15 VIRTUAL MACHINES ~10 years ago

Slide 19

Slide 19 text

Copyright © 2019 HashiCorp @build1point0  DATACENTER Evolution !16 CONTAINERS VIRTUAL MACHINES ~5 years ago

Slide 20

Slide 20 text

Copyright © 2019 HashiCorp @build1point0  DATACENTER Evolution !17 CONTAINERS VIRTUAL MACHINES ~5 years ago

Slide 21

Slide 21 text

Copyright © 2019 HashiCorp @build1point0  DATACENTER Evolution !18 CONTAINERS VIRTUAL MACHINES ~5 years ago

Slide 22

Slide 22 text

Copyright © 2019 HashiCorp @build1point0  DATACENTER DNS Evolution !19 DATABASE Presently SERVERLESS

Slide 23

Slide 23 text

Copyright © 2019 HashiCorp @build1point0  DC 1 Evolution !20 DC 2 Presently

Slide 24

Slide 24 text

Copyright © 2019 HashiCorp @build1point0  Evolution !21 Rise in Complexity

Slide 25

Slide 25 text

Workflow Photo by Daniel Apodaca on Unsplash

Slide 26

Slide 26 text

Copyright © 2019 HashiCorp @build1point0  Workflow !23 Previously

Slide 27

Slide 27 text

Copyright © 2019 HashiCorp @build1point0  Workflow !23 BUY Previously

Slide 28

Slide 28 text

Copyright © 2019 HashiCorp @build1point0  Workflow !23 BUY PROVISION Previously

Slide 29

Slide 29 text

Copyright © 2019 HashiCorp @build1point0  Workflow !23 BUY PROVISION UPDATE/DESTROY -/+ Previously

Slide 30

Slide 30 text

Copyright © 2019 HashiCorp @build1point0  BUY Workflow !24 PROVISION UPDATE/DESTROY -/+ Previously

Slide 31

Slide 31 text

Copyright © 2019 HashiCorp @build1point0  BUY Workflow !24 Previously

Slide 32

Slide 32 text

Copyright © 2019 HashiCorp @build1point0  Workflow !25 BUY Presently

Slide 33

Slide 33 text

Copyright © 2019 HashiCorp @build1point0  Workflow !25 BUY Presently

Slide 34

Slide 34 text

Copyright © 2019 HashiCorp @build1point0  Workflow !26 PROVISION UPDATE/DESTROY -/+ BUY Presently

Slide 35

Slide 35 text

Copyright © 2019 HashiCorp @build1point0  Workflow !26 PROVISION BUY Presently

Slide 36

Slide 36 text

Copyright © 2019 HashiCorp @build1point0  Workflow !26 PROVISION Presently

Slide 37

Slide 37 text

Copyright © 2019 HashiCorp @build1point0  Workflow !26 PROVISION Presently

Slide 38

Slide 38 text

Copyright © 2019 HashiCorp @build1point0  PROVISION Workflow !27 Presently

Slide 39

Slide 39 text

Copyright © 2019 HashiCorp @build1point0  PROVISION Workflow !27 Presently

Slide 40

Slide 40 text

Copyright © 2019 HashiCorp @build1point0  Workflow !28 BUY PROVISION UPDATE/DESTROY -/+ Presently

Slide 41

Slide 41 text

Copyright © 2019 HashiCorp @build1point0  Workflow !28 UPDATE/DESTROY -/+ Presently

Slide 42

Slide 42 text

Copyright © 2019 HashiCorp @build1point0  Workflow !29 UPDATE/DESTROY -/+ CLOUD PROVIDER API Presently

Slide 43

Slide 43 text

Copyright © 2019 HashiCorp @build1point0  Complete Workflow !30 Presently

Slide 44

Slide 44 text

Copyright © 2019 HashiCorp @build1point0  !31 CDW

Slide 45

Slide 45 text

Copyright © 2019 HashiCorp @build1point0  !31 CDW

Slide 46

Slide 46 text

Copyright © 2019 HashiCorp @build1point0  !31 CDW

Slide 47

Slide 47 text

Copyright © 2019 HashiCorp @build1point0  !32 CDW

Slide 48

Slide 48 text

No content

Slide 49

Slide 49 text

$ ssh [email protected]
 $ sudo apt-get install default-jre $ echo “the oracle way” $ sudo add-apt-repository ppa:webupd8team/java $ sudo apt-get update $ sudo apt-get install oracle-java8-installer $ ./setup-java.sh Terminal

Slide 50

Slide 50 text

No content

Slide 51

Slide 51 text

No content

Slide 52

Slide 52 text

$ aws usage: aws [options] [ ...] [parameters] To see help text, you can run: aws help aws help aws help Terminal Terminal $ az /\ / \ _____ _ _ ___ _ / /\ \ |_ / | | | \'__/ _\ / ____ \ / /| |_| | | | __/ /_/ \_\/___|\__,_|_| \___|

Slide 53

Slide 53 text

No content

Slide 54

Slide 54 text

No content

Slide 55

Slide 55 text

Why Did We Change? Photo by Maxime Rossignol on Unsplash

Slide 56

Slide 56 text

Copyright © 2019 HashiCorp @build1point0  !40 Deliver Applications at a Rapid Pace

Slide 57

Slide 57 text

Copyright © 2019 HashiCorp @build1point0  !41 Deliver Applications at Scale

Slide 58

Slide 58 text

What could be an ideal workflow? Photo by Alvaro Reyes on Unsplash

Slide 59

Slide 59 text

Copyright © 2019 HashiCorp @build1point0  !43 • Describe your infrastructure in code • Version control • Share infrastructure code • Make safe and predictable changes • Fast provisioning

Slide 60

Slide 60 text

Copyright © 2019 HashiCorp @build1point0  Questions !44 How Do We Provision Resources? • Compute (Cloud Servers) • Network (VPCs, ACLs, Firewalls) • Storage (Databases, Object Stores)

Slide 61

Slide 61 text

Copyright © 2019 HashiCorp @build1point0  Questions !45 How Do We Manage the Lifecycle of Resources? • Compute (Cloud Servers) • Network (VPCs, ACLs, Firewalls) • Storage (Databases, Object Stores)

Slide 62

Slide 62 text

Copyright © 2019 HashiCorp @build1point0  Questions !46 How Do We Enforce Policies Across the Resources? • Compute (Cloud Servers) • Network (VPCs, ACLs, Firewalls) • Storage (Databases, Object Stores)

Slide 63

Slide 63 text

Copyright © 2019 HashiCorp @build1point0  Questions !47 How Do We Automate and Share the Configurations? • Compute (Cloud Servers) • Network (VPCs, ACLs, Firewalls) • Storage (Databases, Object Stores)

Slide 64

Slide 64 text

No content

Slide 65

Slide 65 text

Goal

Slide 66

Slide 66 text

Copyright © 2019 HashiCorp @build1point0  Goal !50 Provide a Unified Workflow Using Infrastructure as Code to Iterate Over Infrastructure Safely that is Capable of Provisioning Anything Anywhere.

Slide 67

Slide 67 text

Copyright © 2019 HashiCorp @build1point0  !51 Terminal resource "TYPE" "NAME" { ATTRIBUTES }

Slide 68

Slide 68 text

Copyright © 2019 HashiCorp @build1point0  !52 Terminal resource "azurerm_virtual_machine" "web" { storage_image_reference { publisher = "Canonical" offer = "UbuntuServer" sku = "16.04-LTS" version = "latest" } } resource "aws_instance" "web" { ami = "ami-b123125" } main.tf

Slide 69

Slide 69 text

Copyright © 2019 HashiCorp @build1point0  !53 Terminal resource "azurerm_public_ip" "web" { name = "webserver-ip" location = "West US" resource_group_name = "webserver-rg" public_ip_address_allocation = "static" } resource "dnsimple_record" "hello" { domain = "example.com" name = "test" value = "${azurerm_public_ip.web.ip_address}" type = "A" } main.tf

Slide 70

Slide 70 text

Copyright © 2019 HashiCorp @build1point0  !54 Terminal resource "azurerm_public_ip" "web" { name = "webserver-ip" location = "West US" resource_group_name = "webserver-rg" public_ip_address_allocation = "static" } resource "dnsimple_record" "hello" { domain = "example.com" name = "test" value = "${azurerm_public_ip.web.ip_address}" type = "A" } main.tf

Slide 71

Slide 71 text

Copyright © 2019 HashiCorp @build1point0  !55 Terminal resource "cloudflare_page_rule" "www" { # ... } resource "fastly_service_v1" "myservice" { name = "myawesometestservice" # ... } main.tf

Slide 72

Slide 72 text

Copyright © 2019 HashiCorp @build1point0  !56 Terminal resource "github_membership" "membership_for_some_user" { username = "admin" role = "owner" } resource "gitlab_project" "example" { name = "example" description = "My awesome codebase" visibility_level = "public" } main.tf

Slide 73

Slide 73 text

Copyright © 2019 HashiCorp @build1point0  !57 Core Config Parser DAG Schema

Slide 74

Slide 74 text

Copyright © 2019 HashiCorp @build1point0  !58 Core Config Parser DAG Schema Plugins Providers Provisioners

Slide 75

Slide 75 text

Copyright © 2019 HashiCorp @build1point0  !59

Slide 76

Slide 76 text

Copyright © 2019 HashiCorp @build1point0  !59 Amazon BitBucket CenturyLink Cloud CloudFlare CloudStack Cobbler Consul Datadog DigitalOcean DNSMadeEasy DNSimple Docker Dyn GitHub Fastly Google Heroku Librato Microsoft Azure MySQL OpenStack Packet PostgreSQL SoftLayer UltraDNS VMware Sphere and more...

Slide 77

Slide 77 text

Copyright © 2019 HashiCorp @build1point0  !59 Amazon BitBucket CenturyLink Cloud CloudFlare CloudStack Cobbler Consul Datadog DigitalOcean DNSMadeEasy DNSimple Docker Dyn GitHub Fastly Google Heroku Librato Microsoft Azure MySQL OpenStack Packet PostgreSQL SoftLayer UltraDNS VMware Sphere and more...

Slide 78

Slide 78 text

Copyright © 2019 HashiCorp @build1point0  !59 Amazon BitBucket CenturyLink Cloud CloudFlare CloudStack Cobbler Consul Datadog DigitalOcean DNSMadeEasy DNSimple Docker Dyn GitHub Fastly Google Heroku Librato Microsoft Azure MySQL OpenStack Packet PostgreSQL SoftLayer UltraDNS VMware Sphere and more... 100s Terraform Providers

Slide 79

Slide 79 text

Copyright © 2019 HashiCorp @build1point0  !59 Amazon BitBucket CenturyLink Cloud CloudFlare CloudStack Cobbler Consul Datadog DigitalOcean DNSMadeEasy DNSimple Docker Dyn GitHub Fastly Google Heroku Librato Microsoft Azure MySQL OpenStack Packet PostgreSQL SoftLayer UltraDNS VMware Sphere and more...

Slide 80

Slide 80 text

Copyright © 2019 HashiCorp @build1point0  !59

Slide 81

Slide 81 text

Copyright © 2019 HashiCorp @build1point0  !59

Slide 82

Slide 82 text

Copyright © 2019 HashiCorp @build1point0  !60 CRUD API =

Slide 83

Slide 83 text

Copyright © 2019 HashiCorp @build1point0  !61 CRUD API =

Slide 84

Slide 84 text

Copyright © 2019 HashiCorp @build1point0  !61 CRUD API = Create()

Slide 85

Slide 85 text

Copyright © 2019 HashiCorp @build1point0  !61 CRUD API = Create() Read()

Slide 86

Slide 86 text

Copyright © 2019 HashiCorp @build1point0  !61 CRUD API = Create() Read() Update()

Slide 87

Slide 87 text

Copyright © 2019 HashiCorp @build1point0  !61 CRUD API = Create() Read() Update() Destroy()

Slide 88

Slide 88 text

Copyright © 2019 HashiCorp @build1point0  !62 Describe Your Infrastructure in Text Files

Slide 89

Slide 89 text

Copyright © 2019 HashiCorp @build1point0  !63 Human Friendly Configuration

Slide 90

Slide 90 text

Copyright © 2019 HashiCorp @build1point0  !64 Human Friendly Configuration <3 JSON

Slide 91

Slide 91 text

Copyright © 2019 HashiCorp @build1point0  !65 Store in Any VCS

Slide 92

Slide 92 text

Copyright © 2019 HashiCorp @build1point0  !66 Track the History of Your Infrastructure

Slide 93

Slide 93 text

Copyright © 2019 HashiCorp @build1point0  Terraform Usage !67 • Contributors ~4600 • Downloads ~300,000/month (unique) • Modules ~2000

Slide 94

Slide 94 text

Copyright © 2019 HashiCorp @build1point0  Goal !68 Provide a Unified Workflow Using Infrastructure as Code to Iterate Over Infrastructure Safely that is Capable of Provisioning Anything Anywhere.

Slide 95

Slide 95 text

Copyright © 2019 HashiCorp @build1point0  Goal !69 Provide a Unified Workflow Using Infrastructure as Code to Iterate Over Infrastructure Safely that is Capable of Provisioning Anything Anywhere.

Slide 96

Slide 96 text

PLAN & APPLY

Slide 97

Slide 97 text

Copyright © 2019 HashiCorp @build1point0  !71 Terminal resource "azurerm_public_ip" "web" { resource_group_name = "webserver-rg" public_ip_address_allocation = "static" } resource "azurerm_network_interface" "web" { resource_group_name = "webserver-rg" ip_configuration { ..... public_ip_address_id = "${azurerm_public_ip.web.id}" } } resource "azurerm_virtual_machine" "web" { count = 1 network_interface_ids = ["${azurerm_network_interface.web.id}"] storage_image_reference { offer = "UbuntuServer" ..... } } resource "dnsimple_record" "web" { domain = "example.com" name = "webs" value = "${azurerm_public_ip.web.ip_address}" type = "A" } main.tf

Slide 98

Slide 98 text

Copyright © 2019 HashiCorp @build1point0  !72 Terminal resource "azurerm_public_ip" "web" { resource_group_name = "webserver-rg" public_ip_address_allocation = "static" } resource "azurerm_network_interface" "web" { resource_group_name = "webserver-rg" ip_configuration { ..... public_ip_address_id = "${azurerm_public_ip.web.id}" } } resource "azurerm_virtual_machine" "web" { count = 1 network_interface_ids = ["${azurerm_network_interface.web.id}"] storage_image_reference { offer = "UbuntuServer" ..... } } resource "dnsimple_record" "web" { domain = "example.com" name = "webs" value = "${azurerm_public_ip.web.ip_address}" type = "A" } main.tf

Slide 99

Slide 99 text

Copyright © 2019 HashiCorp @build1point0  !73 Terminal $ terraform plan main.tf

Slide 100

Slide 100 text

Copyright © 2019 HashiCorp @build1point0  !74 “Shows You What Will Happen Before It Actually Happens” TERRAFORM PLAN Anubhav Mishra Rootconf Hyderabad 2019

Slide 101

Slide 101 text

Copyright © 2019 HashiCorp @build1point0  !75 Terminal + azurerm_public_ip.web ..... + azurerm_network_interface.web ..... + azurerm_virtual_machine.webserver ..... + dnsimple_record.hello id: domain: "example.com" domain_id: hostname: name: "test" priority: ttl: "3600" type: "A" value: "${azurerm_public_ip.web.ip_address}" shell

Slide 102

Slide 102 text

Copyright © 2019 HashiCorp @build1point0  !76 Terminal + azurerm_public_ip.web ..... + azurerm_network_interface.web ..... + azurerm_virtual_machine.webserver ..... + dnsimple_record.hello id: domain: "example.com" domain_id: hostname: name: "test" priority: ttl: "3600" type: "A" value: "${azurerm_public_ip.web.ip_address}" shell

Slide 103

Slide 103 text

Copyright © 2019 HashiCorp @build1point0  !77 Terminal + azurerm_public_ip.web ..... + azurerm_network_interface.web ..... + azurerm_virtual_machine.webserver ..... + dnsimple_record.hello id: domain: "example.com" domain_id: hostname: name: "test" priority: ttl: "3600" type: "A" value: "${azurerm_public_ip.web.ip_address}" shell

Slide 104

Slide 104 text

Copyright © 2019 HashiCorp @build1point0  !78 Terminal + azurerm_public_ip.web ..... + azurerm_network_interface.web ..... + azurerm_virtual_machine.webserver ..... + dnsimple_record.hello id: domain: "example.com" domain_id: hostname: name: "test" priority: ttl: "3600" type: "A" value: "${azurerm_public_ip.web.ip_address}" shell

Slide 105

Slide 105 text

Copyright © 2019 HashiCorp @build1point0  !79 Terminal $ terraform apply shell

Slide 106

Slide 106 text

Copyright © 2019 HashiCorp @build1point0  !80 Previously?????

Slide 107

Slide 107 text

No content

Slide 108

Slide 108 text

No content

Slide 109

Slide 109 text

State

Slide 110

Slide 110 text

Copyright © 2019 HashiCorp @anubhavm  !83 Map of Real World Resources to Your Configuration. TERRAFORM STATE

Slide 111

Slide 111 text

Copyright © 2019 HashiCorp @anubhavm  !84 Terminal { "version": 3, "terraform_version": "0.11.5", "serial": 4, "lineage": "af985fb6-6e75-66bc-984a-7635ea4249c7", "modules": [ { "path": [ "root" ], "outputs": {}, "resources": { "azurerm_resource_group.default": { "type": "azurerm_resource_group", "depends_on": [], "primary": { "id": "", }, }, "deposed": [], "provider": "provider.azurerm" } }, "depends_on": [] }, terraform.tfstate

Slide 112

Slide 112 text

Copyright © 2019 HashiCorp @anubhavm  !85 Terminal { "version": 3, "terraform_version": "0.11.5", "serial": 4, "lineage": "af985fb6-6e75-66bc-984a-7635ea4249c7", "modules": [ { "path": [ "root" ], "outputs": {}, "resources": { "azurerm_resource_group.default": { "type": "azurerm_resource_group", "depends_on": [], "primary": { "id": "", }, }, "deposed": [], "provider": "provider.azurerm" } }, "depends_on": [] }, terraform.tfstate

Slide 113

Slide 113 text

Copyright © 2019 HashiCorp @anubhavm  !85 Terminal { "version": 3, "terraform_version": "0.11.5", "serial": 4, "lineage": "af985fb6-6e75-66bc-984a-7635ea4249c7", "modules": [ { "path": [ "root" ], "outputs": {}, "resources": { "azurerm_resource_group.default": { "type": "azurerm_resource_group", "depends_on": [], "primary": { "id": "", }, }, "deposed": [], "provider": "provider.azurerm" } }, "depends_on": [] }, terraform.tfstate

Slide 114

Slide 114 text

Copyright © 2019 HashiCorp @anubhavm  !85 Terminal { "version": 3, "terraform_version": "0.11.5", "serial": 4, "lineage": "af985fb6-6e75-66bc-984a-7635ea4249c7", "modules": [ { "path": [ "root" ], "outputs": {}, "resources": { "azurerm_resource_group.default": { "type": "azurerm_resource_group", "depends_on": [], "primary": { "id": "", }, }, "deposed": [], "provider": "provider.azurerm" } }, "depends_on": [] }, terraform.tfstate Storage: Terraform Cloud, file, consul, azurerm, s3, gcs, etc.

Slide 115

Slide 115 text

No content

Slide 116

Slide 116 text

No content

Slide 117

Slide 117 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION

Slide 118

Slide 118 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..)

Slide 119

Slide 119 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..)

Slide 120

Slide 120 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) FOO SERVICE (EC2 instances, ASGs…..)

Slide 121

Slide 121 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) FOO SERVICE (EC2 instances, ASGs…..)

Slide 122

Slide 122 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) BAR SERVICE (Lambda, RDS instances…..) FOO SERVICE (EC2 instances, ASGs…..)

Slide 123

Slide 123 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) BAR SERVICE (Lambda, RDS instances…..) FOO SERVICE (EC2 instances, ASGs…..) DEVELOPMENT

Slide 124

Slide 124 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) BAR SERVICE (Lambda, RDS instances…..) FOO SERVICE (EC2 instances, ASGs…..) DEVELOPMENT STAGING

Slide 125

Slide 125 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) BAR SERVICE (Lambda, RDS instances…..) FOO SERVICE (EC2 instances, ASGs…..) DEVELOPMENT STAGING PRODUCTION

Slide 126

Slide 126 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) BAR SERVICE (Lambda, RDS instances…..) FOO SERVICE (EC2 instances, ASGs…..) DEVELOPMENT STAGING PRODUCTION DEVELOPMENT

Slide 127

Slide 127 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) BAR SERVICE (Lambda, RDS instances…..) FOO SERVICE (EC2 instances, ASGs…..) DEVELOPMENT STAGING PRODUCTION DEVELOPMENT STAGING

Slide 128

Slide 128 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) BAR SERVICE (Lambda, RDS instances…..) FOO SERVICE (EC2 instances, ASGs…..) DEVELOPMENT STAGING PRODUCTION DEVELOPMENT STAGING Terraform Workspaces

Slide 129

Slide 129 text

Copyright © 2019 HashiCorp @anubhavm  !87 TERRAFORM STATE ORGANIZATION NETWORKING (VPCs, ACLs, Routing Table..) BAR SERVICE (Lambda, RDS instances…..) FOO SERVICE (EC2 instances, ASGs…..) DEVELOPMENT STAGING PRODUCTION DEVELOPMENT STAGING Terraform Workspaces }

Slide 130

Slide 130 text

Collaboration Photo by rawpixel on Unsplash

Slide 131

Slide 131 text

Modules

Slide 132

Slide 132 text

Copyright © 2019 HashiCorp @build1point0  !90 Terminal resource "azurerm_public_ip" "web" { ..... } resource "azurerm_network_interface" "web" { ip_configuration { ..... public_ip_address_id = "${azurerm_public_ip.web.id}" } } resource "azurerm_virtual_machine" "web" { count = 1 network_interface_ids = ["${azurerm_network_interface.web.id}"] storage_image_reference { publisher = "Canonical" offer = "UbuntuServer" sku = "16.04-LTS" version = "latest" } } resource "dnsimple_record" "web" { domain = "example.com" name = "test" value = "${azurerm_public_ip.web.ip_address}" type = "A" } main.tf

Slide 133

Slide 133 text

Copyright © 2019 HashiCorp @build1point0  !91 Terminal resource "azurerm_public_ip" "web" { ..... } resource "azurerm_network_interface" "web" { ip_configuration { ..... public_ip_address_id = "${azurerm_public_ip.web.id}" } } resource "azurerm_virtual_machine" "web" { count = "${var.count}" network_interface_ids = ["${azurerm_network_interface.web.id}"] storage_image_reference { publisher = "Canonical" offer = "${var.os_name}" sku = "${var.sku}" version = "latest" } } resource "dnsimple_record" "web" { domain = "example.com" name = "test" value = "${azurerm_public_ip.web.ip_address}" type = "A" } main.tf

Slide 134

Slide 134 text

Copyright © 2019 HashiCorp @build1point0  !92 Terminal resource "azurerm_public_ip" "web" { ..... } resource "azurerm_network_interface" "web" { ip_configuration { ..... public_ip_address_id = "${azurerm_public_ip.web.id}" } } resource "azurerm_virtual_machine" "web" { count = "${var.count}" network_interface_ids = ["${azurerm_network_interface.web.id}"] storage_image_reference { publisher = "Canonical" offer = "${var.os_name}" sku = “${var.sku}" version = "latest" } } resource "dnsimple_record" "web" { domain = "example.com" name = "test" value = "${azurerm_public_ip.web.ip_address}" type = "A" } main.tf

Slide 135

Slide 135 text

Copyright © 2019 HashiCorp @build1point0  !93 Terminal module "webserver" { source = "mishracorp/webserver" count = 10 os_name = "UbuntuServer" } main.tf

Slide 136

Slide 136 text

Copyright © 2019 HashiCorp @build1point0  !94 Terminal module "webserver" { source = "mishracorp/webserver" count = 10 os_name = "UbuntuServer" } main.tf Inputs Outputs

Slide 137

Slide 137 text

Copyright © 2019 HashiCorp @build1point0  !95

Slide 138

Slide 138 text

Copyright © 2019 HashiCorp @build1point0  !96 Terminal module "webserver" { source = "mishracorp/webserver" count = 10 os_name = "UbuntuServer" } main.tf

Slide 139

Slide 139 text

Copyright © 2019 HashiCorp @build1point0  !97 Terminal module "webserver" { source = "mishracorp/webserver" count = 10 os_name = "UbuntuServer" } main.tf OPERATIONS ENGINEER

Slide 140

Slide 140 text

Copyright © 2019 HashiCorp @build1point0  !98 Terminal module "webserver" { source = "mishracorp/webserver" count = 10 os_name = "UbuntuServer" } main.tf OPERATIONS ENGINEER SOFTWARE ENGINEER

Slide 141

Slide 141 text

Copyright © 2019 HashiCorp @build1point0  !99 Terminal module "webserver" { source = "mishracorp/webserver" count = 10 os_name = "UbuntuServer" } main.tf OPERATIONS ENGINEER SOFTWARE ENGINEER WEBSERVERS

Slide 142

Slide 142 text

Copyright © 2019 HashiCorp @build1point0  !100 Terminal module "webserver" { source = "mishracorp/webserver?ref=v1.2.0" count = 10 os_name = "UbuntuServer" environment = "development" service_name = "profile" contact = "Anubhav Mishra" } main.tf

Slide 143

Slide 143 text

Copyright © 2019 HashiCorp @build1point0  !101 Terminal module "webserver" { source = "mishracorp/webserver?ref=v1.2.0" count = 10 os_name = "UbuntuServer" environment = "development" service_name = "profile" contact = "Anubhav Mishra" } main.tf Module Versioning

Slide 144

Slide 144 text

Copyright © 2019 HashiCorp @build1point0  !102 Terminal module "webserver" { source = "mishracorp/webserver" count = 10 os_name = "UbuntuServer" } main.tf Terminal module "webserver" { source = “mishracorp/mysql- database“ read_replica_count = 10 } main.tf Terminal module "webserver" { source = “mishracorp/pub-sub” } main.tf Terminal module "webserver" { source = “mishracorp/ autoscaling-group” min_count = 10 } main.tf Terminal module "webserver" { source = “mishracorp/ kubernetes" nodes = 10 } main.tf

Slide 145

Slide 145 text

Copyright © 2019 HashiCorp @build1point0  !103 CORE MODULES SERVICE MODULES

Slide 146

Slide 146 text

Copyright © 2019 HashiCorp @build1point0  !103 CORE MODULES SERVICE MODULES PRODUCERS

Slide 147

Slide 147 text

Copyright © 2019 HashiCorp @build1point0  !103 CORE MODULES SERVICE MODULES OPERATIONS ENGINEER PRODUCERS

Slide 148

Slide 148 text

Copyright © 2019 HashiCorp @build1point0  !103 CORE MODULES SERVICE MODULES OPERATIONS ENGINEER PRODUCERS

Slide 149

Slide 149 text

Copyright © 2019 HashiCorp @build1point0  !103 CORE MODULES SERVICE MODULES OPERATIONS ENGINEER PLATFORM ENGINEER PRODUCERS

Slide 150

Slide 150 text

Copyright © 2019 HashiCorp @build1point0  !103 CORE MODULES SERVICE MODULES OPERATIONS ENGINEER PLATFORM ENGINEER PRODUCERS

Slide 151

Slide 151 text

Copyright © 2019 HashiCorp @build1point0  !103 CORE MODULES SERVICE MODULES OPERATIONS ENGINEER PLATFORM ENGINEER PRODUCERS

Slide 152

Slide 152 text

Copyright © 2019 HashiCorp @build1point0  !103 CORE MODULES SERVICE MODULES OPERATIONS ENGINEER PLATFORM ENGINEER PRODUCERS CONSUMERS

Slide 153

Slide 153 text

INFRASTRUCTURE WORKFLOW FOR THE CLOUD

Slide 154

Slide 154 text

s Copyright © 2017 HashiCorp @build1point0  !105 DEMO

Slide 155

Slide 155 text

www.hashicorp.com FOR EVERYONE, EVERYWHERE Ask me anything. @build1point0 Anubhav Mishra Thank you! mishra.dev/rootconf