Skip to content

Commit f6df34c

Browse files
authored
feat: add TF 0.13 constraint and module attribution (#513)
BREAKING CHANGE: Minimum Terraform version increased to 0.13.
1 parent 0eb2431 commit f6df34c

File tree

33 files changed

+433
-57
lines changed

33 files changed

+433
-57
lines changed

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
# Make will use bash instead of sh
1919
SHELL := /usr/bin/env bash
2020

21-
DOCKER_TAG_VERSION_DEVELOPER_TOOLS := 0.12.1
21+
DOCKER_TAG_VERSION_DEVELOPER_TOOLS := 0.13
2222
DOCKER_IMAGE_DEVELOPER_TOOLS := cft/developer-tools
2323
REGISTRY_URL := gcr.io/cloud-foundation-cicd
2424

README.md

+8-8
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@ To include G Suite integration for creating groups and adding Service Accounts i
1212

1313
## Compatibility
1414

15-
This module is meant for use with Terraform 0.12. If you haven't
16-
[upgraded][terraform-0.12-upgrade] and need a Terraform
17-
0.11.x-compatible version of this module, the last released version
18-
intended for Terraform 0.11.x is [2.4.1].
15+
This module is meant for use with Terraform 0.13. If you haven't
16+
[upgraded][terraform-0.13-upgrade] and need a Terraform
17+
0.12.x-compatible version of this module, the last released version
18+
intended for Terraform 0.12.x is [9.2.0].
1919

2020
## Upgrading
2121

@@ -174,7 +174,7 @@ determining that location is as follows:
174174

175175
- [gcloud sdk](https://cloud.google.com/sdk/install) >= 269.0.0
176176
- [jq](https://stedolan.github.io/jq/) >= 1.6
177-
- [Terraform](https://www.terraform.io/downloads.html) >= 0.12.6
177+
- [Terraform](https://www.terraform.io/downloads.html) >= 0.13.0
178178
- [terraform-provider-google] plugin >= 3.1, < 4.0
179179
- [terraform-provider-google-beta] plugin >= 3.1, < 4.0
180180
- [terraform-provider-gsuite] plugin 0.1.x if GSuite functionality is desired
@@ -343,7 +343,7 @@ The core Project Factory solely deals with GCP APIs and does not integrate G Sui
343343
## Install
344344
### Terraform
345345

346-
Be sure you have the correct Terraform version (0.12.6+), you can choose the
346+
Be sure you have the correct Terraform version (0.13.0+), you can choose the
347347
binary here:
348348

349349
- https://releases.hashicorp.com/terraform/
@@ -356,5 +356,5 @@ binary here:
356356
[glossary]: /docs/GLOSSARY.md
357357
[application-default-credentials]: https://cloud.google.com/docs/authentication/production#providing_credentials_to_your_application
358358

359-
[2.4.1]: https://registry.terraform.io/modules/terraform-google-modules/project-factory/google/2.4.1
360-
[terraform-0.12-upgrade]: https://www.terraform.io/upgrade-guides/0-12.html
359+
[9.2.0]: https://registry.terraform.io/modules/terraform-google-modules/project-factory/google/9.2.0
360+
[terraform-0.13-upgrade]: https://www.terraform.io/upgrade-guides/0-13.html

build/int.cloudbuild.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ tags:
150150
- 'integration'
151151
substitutions:
152152
_DOCKER_IMAGE_DEVELOPER_TOOLS: 'cft/developer-tools'
153-
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '0.12.0'
153+
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '0.13'
154154
options:
155155
machineType: 'N1_HIGHCPU_8'
156156
env:

build/lint.cloudbuild.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ tags:
2121
- 'lint'
2222
substitutions:
2323
_DOCKER_IMAGE_DEVELOPER_TOOLS: 'cft/developer-tools'
24-
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '0.12.1'
24+
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '0.13'

examples/app_engine/versions.tf

+15-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,19 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
}
23+
google-beta = {
24+
source = "hashicorp/google-beta"
25+
}
26+
null = {
27+
source = "hashicorp/null"
28+
}
29+
random = {
30+
source = "hashicorp/random"
31+
}
32+
}
1933
}

examples/budget_project/versions.tf

+15-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,19 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
}
23+
google-beta = {
24+
source = "hashicorp/google-beta"
25+
}
26+
null = {
27+
source = "hashicorp/null"
28+
}
29+
random = {
30+
source = "hashicorp/random"
31+
}
32+
}
1933
}

examples/fabric_project/versions.tf

+9-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,13 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
}
23+
random = {
24+
source = "hashicorp/random"
25+
}
26+
}
1927
}

examples/gke_shared_vpc/versions.tf

+15-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,19 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
}
23+
google-beta = {
24+
source = "hashicorp/google-beta"
25+
}
26+
null = {
27+
source = "hashicorp/null"
28+
}
29+
random = {
30+
source = "hashicorp/random"
31+
}
32+
}
1933
}

examples/group_project/versions.tf

+18-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,22 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
}
23+
google-beta = {
24+
source = "hashicorp/google-beta"
25+
}
26+
gsuite = {
27+
source = "DeviaVir/gsuite"
28+
}
29+
null = {
30+
source = "hashicorp/null"
31+
}
32+
random = {
33+
source = "hashicorp/random"
34+
}
35+
}
1936
}

examples/project-hierarchy/versions.tf

+18-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,22 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
}
23+
google-beta = {
24+
source = "hashicorp/google-beta"
25+
}
26+
gsuite = {
27+
source = "DeviaVir/gsuite"
28+
}
29+
null = {
30+
source = "hashicorp/null"
31+
}
32+
random = {
33+
source = "hashicorp/random"
34+
}
35+
}
1936
}

examples/project_services/versions.tf

+9-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,13 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
}
23+
google-beta = {
24+
source = "hashicorp/google-beta"
25+
}
26+
}
1927
}

examples/shared_vpc/versions.tf

+15-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,19 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
}
23+
google-beta = {
24+
source = "hashicorp/google-beta"
25+
}
26+
null = {
27+
source = "hashicorp/null"
28+
}
29+
random = {
30+
source = "hashicorp/random"
31+
}
32+
}
1933
}

examples/simple_project/versions.tf

+15-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,19 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
}
23+
google-beta = {
24+
source = "hashicorp/google-beta"
25+
}
26+
null = {
27+
source = "hashicorp/null"
28+
}
29+
random = {
30+
source = "hashicorp/random"
31+
}
32+
}
1933
}

modules/app_engine/versions.tf

+5-2
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,12 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
1919

2020
required_providers {
21-
google = ">= 2.1, < 4.0"
21+
google = {
22+
source = "hashicorp/google"
23+
version = ">= 3.43, < 4.0"
24+
}
2225
}
2326
}

modules/budget/versions.tf

+12-2
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,19 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
1919

2020
required_providers {
21-
google-beta = ">= 3.1, < 4.0"
21+
google-beta = {
22+
source = "hashicorp/google-beta"
23+
version = ">= 3.43, < 4.0"
24+
}
25+
}
26+
27+
provider_meta "google" {
28+
module_name = "blueprints/terraform/terraform-google-project-factory:budget/v10.0.0"
29+
}
30+
provider_meta "google-beta" {
31+
module_name = "blueprints/terraform/terraform-google-project-factory:budget/v10.0.0"
2232
}
2333
}

modules/core_project_factory/versions.tf

+17-5
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,24 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
1919

2020
required_providers {
21-
google = ">= 3.50, < 4.0"
22-
google-beta = ">= 3.50, < 4.0"
23-
null = "~> 2.1"
24-
random = "~> 2.2"
21+
google = {
22+
source = "hashicorp/google"
23+
version = ">= 3.50, < 4.0"
24+
}
25+
google-beta = {
26+
source = "hashicorp/google-beta"
27+
version = ">= 3.50, < 4.0"
28+
}
29+
null = {
30+
source = "hashicorp/null"
31+
version = "~> 2.1"
32+
}
33+
random = {
34+
source = "hashicorp/random"
35+
version = "~> 2.2"
36+
}
2537
}
2638
}

modules/fabric-project/outputs.tf

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ output "number" {
3434

3535
output "cloudsvc_service_account" {
3636
description = "Cloud services service account (depends on services)."
37-
value = "${local.cloudsvc_service_account}"
37+
value = local.cloudsvc_service_account
3838
depends_on = [google_project_service.project_services]
3939
}
4040

modules/fabric-project/versions.tf

+11-2
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,18 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
1919

2020
required_providers {
21-
google = ">= 3.1, < 4.0"
21+
google = {
22+
source = "hashicorp/google"
23+
version = ">= 3.43, < 4.0"
24+
}
25+
}
26+
provider_meta "google" {
27+
module_name = "blueprints/terraform/terraform-google-project-factory:fabric-project/v10.0.0"
28+
}
29+
provider_meta "google-beta" {
30+
module_name = "blueprints/terraform/terraform-google-project-factory:fabric-project/v10.0.0"
2231
}
2332
}

modules/gsuite_enabled/versions.tf

+11-2
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,18 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
1919

2020
required_providers {
21-
gsuite = "~> 0.1"
21+
gsuite = {
22+
source = "DeviaVir/gsuite"
23+
version = "~> 0.1"
24+
}
25+
}
26+
provider_meta "google" {
27+
module_name = "blueprints/terraform/terraform-google-project-factory:gsuite_enabled/v10.0.0"
28+
}
29+
provider_meta "google-beta" {
30+
module_name = "blueprints/terraform/terraform-google-project-factory:gsuite_enabled/v10.0.0"
2231
}
2332
}

modules/gsuite_group/versions.tf

+7-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,11 @@
1515
*/
1616

1717
terraform {
18-
required_version = ">=0.12.6"
18+
required_version = ">= 0.13"
19+
required_providers {
20+
google = {
21+
source = "hashicorp/google"
22+
version = ">= 3.43, <4.0"
23+
}
24+
}
1925
}

0 commit comments

Comments
 (0)