Skip to content

Commit

Permalink
feat: update TPG version constraints to allow 4.0 (#34)
Browse files Browse the repository at this point in the history
* feat: update TPG version constraints to allow 4.0

* remove kms id in example

* kitchen verify version skip

Co-authored-by: bharathkkb <[email protected]>
  • Loading branch information
cloud-foundation-bot and bharathkkb authored Feb 23, 2022
1 parent ed5c200 commit 374ab2d
Show file tree
Hide file tree
Showing 12 changed files with 40 additions and 18 deletions.
1 change: 1 addition & 0 deletions .kitchen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
driver:
name: "terraform"
command_timeout: 1800
verify_version: false

provisioner:
name: "terraform"
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
# Make will use bash instead of sh
SHELL := /usr/bin/env bash

DOCKER_TAG_VERSION_DEVELOPER_TOOLS := 1.0
DOCKER_TAG_VERSION_DEVELOPER_TOOLS := 1.3
DOCKER_IMAGE_DEVELOPER_TOOLS := cft/developer-tools
REGISTRY_URL := gcr.io/cloud-foundation-cicd

Expand Down
2 changes: 1 addition & 1 deletion build/int.cloudbuild.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,4 @@ tags:
- 'integration'
substitutions:
_DOCKER_IMAGE_DEVELOPER_TOOLS: 'cft/developer-tools'
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '1.0'
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '1.3'
2 changes: 1 addition & 1 deletion build/lint.cloudbuild.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ tags:
- 'lint'
substitutions:
_DOCKER_IMAGE_DEVELOPER_TOOLS: 'cft/developer-tools'
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '1.0'
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '1.3'
5 changes: 2 additions & 3 deletions examples/dlp_api_example/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
*/

provider "google" {
version = "~> 3.53"
region = var.region
region = var.region
}

resource "random_id" "random_suffix" {
Expand Down Expand Up @@ -86,7 +85,7 @@ resource "google_kms_key_ring" "create_kms_ring" {
resource "google_kms_crypto_key" "create_kms_key" {
count = var.create_key_ring ? 1 : 0
name = var.kms_key_name
key_ring = google_kms_key_ring.create_kms_ring[0].self_link
key_ring = google_kms_key_ring.create_kms_ring[0].id
depends_on = [google_kms_key_ring.create_kms_ring]
}

Expand Down
14 changes: 13 additions & 1 deletion examples/dlp_api_example/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,17 @@
*/

terraform {
required_version = ">= 0.12"
required_version = ">= 0.13"
required_providers {
google = {
source = "hashicorp/google"
version = "~> 4.0"
}
null = {
source = "hashicorp/null"
}
random = {
source = "hashicorp/random"
}
}
}
5 changes: 2 additions & 3 deletions examples/simple_example/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
*/

provider "google" {
version = "~> 3.53"
region = var.region
region = var.region
}

resource "random_id" "random_suffix" {
Expand All @@ -29,7 +28,7 @@ locals {

module "vpc" {
source = "terraform-google-modules/network/google"
version = "~> 3.0"
version = "~> 4.0"
project_id = var.project_id
network_name = "dataflow-network"

Expand Down
11 changes: 10 additions & 1 deletion examples/simple_example/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,14 @@
*/

terraform {
required_version = ">= 0.12"
required_version = ">= 0.13"
required_providers {
google = {
source = "hashicorp/google"
version = "~> 4.0"
}
random = {
source = "hashicorp/random"
}
}
}
2 changes: 1 addition & 1 deletion modules/dataflow_bucket/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ terraform {

google = {
source = "hashicorp/google"
version = "~> 3.53"
version = ">= 3.53, < 5.0"
}
}

Expand Down
4 changes: 0 additions & 4 deletions test/setup/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,6 @@
* limitations under the License.
*/

provider "google" {
version = "~> 3.53"
}

module "project-ci-dataflow" {
source = "terraform-google-modules/project-factory/google"
version = "~> 10.0"
Expand Down
8 changes: 7 additions & 1 deletion test/setup/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,11 @@
*/

terraform {
required_version = ">= 0.12"
required_version = ">= 0.13"
required_providers {
google = {
source = "hashicorp/google"
version = "~> 3.53"
}
}
}
2 changes: 1 addition & 1 deletion versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ terraform {

google = {
source = "hashicorp/google"
version = "~> 3.53"
version = ">= 3.53, < 5.0"
}
}

Expand Down

0 comments on commit 374ab2d

Please sign in to comment.