Skip to content

Commit e77b8f9

Browse files
committed
Update all code samples to Terraform 0.8.x
1 parent 65faac5 commit e77b8f9

File tree

74 files changed

+219
-79
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+219
-79
lines changed

code/bash/02-intro-to-terraform-syntax/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
This folder contains an example of a Bash script that can be used to start a web server that listens on port 8080
44
and returns the text "Hello, World" for the URL `/`.
55

6-
For more info, please see Chapter 2, "An Introduction to Terraform Syntax", of
6+
For more info, please see Chapter 2, "Getting started with Terraform", of
77
*[Terraform: Up and Running](http://www.terraformupandrunning.com)*.
88

99
## Pre-requisites

code/ruby/06-terraform-team/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
This folder shows an example of how to write automated tests for a web server cluster defined in
44
[Terraform](https://www.terraform.io/) templates. The folder contains a Ruby script, `terraform-test.rb`, that will
5-
apply your Terraform templates and then test the web server cluster URL to make sure it returns "Hello, World".
5+
apply your Terraform configurations and then test the web server cluster URL to make sure it returns "Hello, World".
66

77
For more info, please see Chapter 6, "How to use Terraform as a Team", of
88
*[Terraform: Up and Running](http://www.terraformupandrunning.com)*.
@@ -29,7 +29,7 @@ export AWS_SECRET_ACCESS_KEY=(your secret access key)
2929
```
3030

3131
Deploy a test database of some sort that the web server cluster can connect to. For example, you could deploy the
32-
Terraform templates under
32+
Terraform configurations under
3333
[code/terraform/06-terraform-team/live/stage/data-stores/mysql](/code/terraform/06-terraform-team/live/stage/data-stores/mysql).
3434
Make sure to note down the AWS region you're deploying into (e.g. `us-east-1`) as well as the S3 bucket name (e.g.
3535
`my-terraform-state`) and key (e.g. `qa/stage/data-stores/mysql/terraform.tfstate`) you use to store the remote state

code/terraform/00-preface/hello-world/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ For more info, please see the preface of *[Terraform: Up and Running](http://www
1010
* You must have [Terraform](https://www.terraform.io/) installed on your computer.
1111
* You must have an [Amazon Web Services (AWS) account](http://aws.amazon.com/).
1212

13-
Please note that this code was written for Terraform 0.7.x.
13+
Please note that this code was written for Terraform 0.8.x.
1414

1515
## Quick start
1616

code/terraform/00-preface/hello-world/main.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
terraform {
2+
required_version = ">= 0.8, < 0.9"
3+
}
4+
15
provider "aws" {
26
region = "us-east-1"
37
}

code/terraform/01-why-terraform/server-db-elb/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ For more info, please see Chapter 1, "Why Terraform", of
1313
* You must have [Terraform](https://www.terraform.io/) installed on your computer.
1414
* You must have an [Amazon Web Services (AWS) account](http://aws.amazon.com/).
1515

16-
Please note that this code was written for Terraform 0.7.x.
16+
Please note that this code was written for Terraform 0.8.x.
1717

1818
## Quick start
1919

code/terraform/01-why-terraform/server-db-elb/main.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
terraform {
2+
required_version = ">= 0.8, < 0.9"
3+
}
4+
15
provider "aws" {
26
region = "us-east-1"
37
}

code/terraform/02-intro-to-terraform-syntax/one-server/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@
33
This folder contains an example [Terraform](https://www.terraform.io/) template that deploys a single server (using
44
[EC2](https://aws.amazon.com/ec2/)) in an [Amazon Web Services (AWS) account](http://aws.amazon.com/).
55

6-
For more info, please see Chapter 2, "An Introduction to Terraform Syntax", of
6+
For more info, please see Chapter 2, "Getting started with Terraform", of
77
*[Terraform: Up and Running](http://www.terraformupandrunning.com)*.
88

99
## Pre-requisites
1010

1111
* You must have [Terraform](https://www.terraform.io/) installed on your computer.
1212
* You must have an [Amazon Web Services (AWS) account](http://aws.amazon.com/).
1313

14-
Please note that this code was written for Terraform 0.7.x.
14+
Please note that this code was written for Terraform 0.8.x.
1515

1616
## Quick start
1717

code/terraform/02-intro-to-terraform-syntax/one-server/main.tf

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
terraform {
2+
required_version = ">= 0.8, < 0.9"
3+
}
4+
15
provider "aws" {
26
region = "us-east-1"
37
}
@@ -7,6 +11,6 @@ resource "aws_instance" "example" {
711
instance_type = "t2.micro"
812

913
tags {
10-
name = "terraform-example"
14+
Name = "terraform-example"
1115
}
1216
}

code/terraform/02-intro-to-terraform-syntax/one-webserver-with-vars/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ This folder contains example [Terraform](https://www.terraform.io/) templates th
55
listens on port 8080 (which is defined as a variable in this example) and returns the text "Hello, World" for the `/`
66
URL.
77

8-
For more info, please see Chapter 2, "An Introduction to Terraform Syntax", of
8+
For more info, please see Chapter 2, "Getting started with Terraform", of
99
*[Terraform: Up and Running](http://www.terraformupandrunning.com)*.
1010

1111
## Pre-requisites
1212

1313
* You must have [Terraform](https://www.terraform.io/) installed on your computer.
1414
* You must have an [Amazon Web Services (AWS) account](http://aws.amazon.com/).
1515

16-
Please note that this code was written for Terraform 0.7.x.
16+
Please note that this code was written for Terraform 0.8.x.
1717

1818
## Quick start
1919

code/terraform/02-intro-to-terraform-syntax/one-webserver-with-vars/main.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
terraform {
2+
required_version = ">= 0.8, < 0.9"
3+
}
4+
15
provider "aws" {
26
region = "us-east-1"
37
}

0 commit comments

Comments
 (0)