Skip to content

Instantly share code, notes, and snippets.

@bensojona
Last active August 26, 2015 21:34
Show Gist options
  • Save bensojona/cea8d2a7db0fc99ccfe1 to your computer and use it in GitHub Desktop.
Save bensojona/cea8d2a7db0fc99ccfe1 to your computer and use it in GitHub Desktop.
Notice the odd behavior between `terraform plan`s. There were no changes made in-between running these commands and the environment was reset before each gist . Notice the output is different almost every time. Sometime it errors saying `"region": required field is not set`, sometimes it asks for you to enter the `region` variable then it works,…
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › rm -rf .terraform && rm -rf terraform.tfstate && rm -rf terraform.tfstate.backup
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform get
Get: file:///Users/jb/projects/bensojona/tf-region-bug/terraform/network
Get: file:///Users/jb/projects/bensojona/tf-region-bug/terraform/network/vpc
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-1
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-1
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/projects/bensojona/tf-region-bug/terraform 🚧 master 😎 › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › rm -rf .terraform && rm -rf terraform.tfstate && rm -rf terraform.tfstate.backup
~/Downloads/test-ops/terraform › tree -a
.
├── .DS_Store
├── main.tf
└── network
├── .DS_Store
├── main.tf
└── vpc
└── main.tf
2 directories, 5 files
~/Downloads/test-ops/terraform › terraform get
Get: file:///Users/jb/Downloads/test-ops/terraform/network
Get: file:///Users/jb/Downloads/test-ops/terraform/network/vpc
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › tree -a
.
├── .DS_Store
├── .terraform
│   └── modules
│   ├── 227c2a52cd6711145d873c2974e857ae -> /Users/jb/Downloads/test-ops/terraform/network
│   └── ba8d2d049a0cb175e57b3140e9f3ec0d -> /Users/jb/Downloads/test-ops/terraform/network/vpc
├── main.tf
└── network
├── .DS_Store
├── main.tf
└── vpc
└── main.tf
6 directories, 5 files
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-1
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-1
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-1
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › tree -a
.
├── .DS_Store
├── .terraform
│   └── modules
│   ├── 227c2a52cd6711145d873c2974e857ae -> /Users/jb/Downloads/test-ops/terraform/network
│   └── ba8d2d049a0cb175e57b3140e9f3ec0d -> /Users/jb/Downloads/test-ops/terraform/network/vpc
├── main.tf
├── network
│   ├── .DS_Store
│   ├── main.tf
│   └── vpc
│   └── main.tf
├── terraform.tfstate
└── terraform.tfstate.backup
6 directories, 7 files
~/Downloads/test-ops/terraform › rm -rf .terraform && rm -rf terraform.tfstate && rm -rf terraform.tfstate.backup
~/Downloads/test-ops/terraform › tree -a
.
├── .DS_Store
├── main.tf
└── network
├── .DS_Store
├── main.tf
└── vpc
└── main.tf
2 directories, 5 files
~/Downloads/test-ops/terraform › terraform get
Get: file:///Users/jb/Downloads/test-ops/terraform/network
Get: file:///Users/jb/Downloads/test-ops/terraform/network/vpc
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › tree -a
.
├── .DS_Store
├── .terraform
│   └── modules
│   ├── 227c2a52cd6711145d873c2974e857ae -> /Users/jb/Downloads/test-ops/terraform/network
│   └── ba8d2d049a0cb175e57b3140e9f3ec0d -> /Users/jb/Downloads/test-ops/terraform/network/vpc
├── main.tf
└── network
├── .DS_Store
├── main.tf
└── vpc
└── main.tf
6 directories, 5 files
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-2
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-2
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › tree -a
.
├── .DS_Store
├── .terraform
│   └── modules
│   ├── 227c2a52cd6711145d873c2974e857ae -> /Users/jb/Downloads/test-ops/terraform/network
│   └── ba8d2d049a0cb175e57b3140e9f3ec0d -> /Users/jb/Downloads/test-ops/terraform/network/vpc
├── main.tf
├── network
│   ├── .DS_Store
│   ├── main.tf
│   └── vpc
│   └── main.tf
├── terraform.tfstate
└── terraform.tfstate.backup
6 directories, 7 files
~/Downloads/test-ops/terraform › rm -rf .terraform && rm -rf terraform.tfstate && rm -rf terraform.tfstate.backup
~/Downloads/test-ops/terraform › tree -a
.
├── .DS_Store
├── main.tf
└── network
├── .DS_Store
├── main.tf
└── vpc
└── main.tf
2 directories, 5 files
~/Downloads/test-ops/terraform › terraform get
Get: file:///Users/jb/Downloads/test-ops/terraform/network
Get: file:///Users/jb/Downloads/test-ops/terraform/network/vpc
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-2
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › rm -rf .terraform && rm -rf terraform.tfstate && rm -rf terraform.tfstate.backup
~/Downloads/test-ops/terraform › terraform get
Get: file:///Users/jb/Downloads/test-ops/terraform/network
Get: file:///Users/jb/Downloads/test-ops/terraform/network/vpc
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-2
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-2
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-2
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "region": required field is not set
~/Downloads/test-ops/terraform › terraform plan
provider.aws.region
The region where AWS operations will take place. Examples
are us-east-1, us-west-2, etc.
Default: us-east-1
Enter a value: us-west-2
Refreshing Terraform state prior to plan...
The Terraform execution plan has been generated and is shown below.
Resources are shown in alphabetical order for quick scanning. Green resources
will be created (or destroyed and then created if an existing resource
exists), yellow resources are being changed in-place, and red resources
will be destroyed.
Note: You didn't specify an "-out" parameter to save this plan, so when
"apply" is called, Terraform can't guarantee this is what will execute.
+ module.network.vpc
1 resource(s)
Plan: 1 to add, 0 to change, 0 to destroy.
~/Downloads/test-ops/terraform › rm -rf .terraform && rm -rf terraform.tfstate && rm -rf terraform.tfstate.backup
~/Downloads/test-ops/terraform › terraform get
Get: file:///Users/jb/Downloads/test-ops/terraform/network
Get: file:///Users/jb/Downloads/test-ops/terraform/network/vpc
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "secret_key": required field is not set
* module.network.module.vpc.provider.aws: "region": required field is not set
* module.network.module.vpc.provider.aws: "access_key": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "access_key": required field is not set
* module.network.module.vpc.provider.aws: "secret_key": required field is not set
~/Downloads/test-ops/terraform › terraform plan
There are warnings and/or errors related to your configuration. Please
fix these before continuing.
Errors:
* module.network.module.vpc.provider.aws: "secret_key": required field is not set
* module.network.module.vpc.provider.aws: "region": required field is not set
* module.network.module.vpc.provider.aws: "access_key": required field is not set
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment