Skip to content

Commit

Permalink
Alphabetize resource attributes in examples/basic_usage/
Browse files Browse the repository at this point in the history
  • Loading branch information
mcdonnnj committed Feb 27, 2024
1 parent b5f2179 commit 3f1c503
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 18 deletions.
10 changes: 5 additions & 5 deletions examples/basic_usage/outputs.tf
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
output "arn" {
value = module.example.arn
description = "The EC2 instance ARN."
value = module.example.arn
}

output "availability_zone" {
value = module.example.availability_zone
description = "The AZ where the EC2 instance is deployed."
value = module.example.availability_zone
}

output "id" {
value = module.example.id
description = "The EC2 instance ID."
value = module.example.id
}

output "private_ip" {
value = module.example.private_ip
description = "The private IP of the EC2 instance."
value = module.example.private_ip
}

output "subnet_id" {
value = module.example.subnet_id
description = "The ID of the subnet where the EC2 instance is deployed."
value = module.example.subnet_id
}
18 changes: 9 additions & 9 deletions examples/basic_usage/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
# ------------------------------------------------------------------------------

variable "tf_role_arn" {
type = string
description = "The ARN of the role that can terraform non-specialized resources."
type = string
}

# ------------------------------------------------------------------------------
Expand All @@ -16,27 +16,27 @@ variable "tf_role_arn" {
# ------------------------------------------------------------------------------

variable "ami_owner_account_id" {
type = string
description = "The ID of the AWS account that owns the AMI, or \"self\" if the AMI is owned by the same account as the provisioner."
default = "self"
description = "The ID of the AWS account that owns the AMI, or \"self\" if the AMI is owned by the same account as the provisioner."
type = string
}

variable "aws_availability_zone" {
type = string
description = "The AWS availability zone to deploy into (e.g. a, b, c, etc.)."
default = "a"
description = "The AWS availability zone to deploy into (e.g. a, b, c, etc.)."
type = string
}

variable "aws_region" {
type = string
description = "The AWS region to deploy into (e.g. us-east-1)."
default = "us-east-1"
description = "The AWS region to deploy into (e.g. us-east-1)."
type = string
}

variable "tags" {
type = map(string)
description = "Tags to apply to all AWS resources created."
default = {
Testing = true
}
description = "Tags to apply to all AWS resources created."
type = map(string)
}
6 changes: 3 additions & 3 deletions examples/basic_usage/versions.tf
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
terraform {
# We want to hold off on 1.1 or higher until we have tested it.
required_version = "~> 1.0"

# If you use any other providers you should also pin them to the
# major version currently being used. This practice will help us
# avoid unwelcome surprises.
Expand All @@ -20,4 +17,7 @@ terraform {
version = "~> 4.9"
}
}

# We want to hold off on 1.1 or higher until we have tested it.
required_version = "~> 1.0"
}
2 changes: 1 addition & 1 deletion examples/basic_usage/vpc.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ resource "aws_vpc" "example" {
resource "aws_subnet" "example" {
availability_zone = "${var.aws_region}${var.aws_availability_zone}"
cidr_block = "10.230.0.0/28"
vpc_id = aws_vpc.example.id
tags = { "Name" : "Example" }
vpc_id = aws_vpc.example.id
}

0 comments on commit 3f1c503

Please sign in to comment.