Skip to content

Commit

Permalink
chore: update examples to use registry (#1821)
Browse files Browse the repository at this point in the history
  • Loading branch information
bharathkkb authored Dec 21, 2023
1 parent 46a4090 commit c3abc08
Show file tree
Hide file tree
Showing 38 changed files with 123 additions and 41 deletions.
3 changes: 3 additions & 0 deletions build/int.cloudbuild.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@

timeout: 12600s
steps:
- id: swap-module-refs
name: 'gcr.io/cloud-foundation-cicd/$_DOCKER_IMAGE_DEVELOPER_TOOLS:$_DOCKER_TAG_VERSION_DEVELOPER_TOOLS'
args: ['module-swapper']
- id: prepare
name: 'gcr.io/cloud-foundation-cicd/$_DOCKER_IMAGE_DEVELOPER_TOOLS:$_DOCKER_TAG_VERSION_DEVELOPER_TOOLS'
args: ['/bin/bash', '-c', 'source /usr/local/bin/task_helper_functions.sh && prepare_environment ; chmod 600 /builder/home/.netrc && sleep 120']
Expand Down
4 changes: 3 additions & 1 deletion examples/deploy_service/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
region = var.region
Expand Down
3 changes: 2 additions & 1 deletion examples/disable_client_cert/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
Expand Down
4 changes: 3 additions & 1 deletion examples/node_pool/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../modules/beta-public-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/beta-public-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
region = var.region
Expand Down
1 change: 1 addition & 0 deletions examples/node_pool/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -80,4 +80,5 @@ variable "cluster_autoscaling" {
auto_upgrade = true
}
description = "Cluster autoscaling configuration. See [more details](https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1beta1/projects.locations.clusters#clusterautoscaling)"

}
4 changes: 3 additions & 1 deletion examples/node_pool_update_variant/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../modules/private-cluster-update-variant"
source = "terraform-google-modules/kubernetes-engine/google//modules/private-cluster-update-variant"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = false
Expand Down
4 changes: 3 additions & 1 deletion examples/node_pool_update_variant_beta/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../modules/beta-private-cluster-update-variant"
source = "terraform-google-modules/kubernetes-engine/google//modules/beta-private-cluster-update-variant"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = false
Expand Down
4 changes: 3 additions & 1 deletion examples/node_pool_update_variant_public_beta/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../modules/beta-public-cluster-update-variant"
source = "terraform-google-modules/kubernetes-engine/google//modules/beta-public-cluster-update-variant"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
region = var.region
Expand Down
4 changes: 3 additions & 1 deletion examples/private_zonal_with_networking/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,9 @@ data "google_compute_subnetwork" "subnetwork" {
}

module "gke" {
source = "../../modules/private-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/private-cluster"
version = "~> 29.0"

project_id = var.project_id
name = var.cluster_name
regional = false
Expand Down
4 changes: 3 additions & 1 deletion examples/regional_private_node_pool_oauth_scopes/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
*/

module "gke" {
source = "../../modules/private-cluster"
source = "terraform-google-modules/kubernetes-engine/google//modules/private-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "random-test-cluster"
region = "us-west1"
Expand Down
4 changes: 3 additions & 1 deletion examples/safer_cluster/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,9 @@ resource "random_shuffle" "version" {
}

module "gke" {
source = "../../modules/safer-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/safer-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster-${random_string.suffix.result}"
regional = true
Expand Down
3 changes: 2 additions & 1 deletion examples/safer_cluster_iap_bastion/cluster.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
*/

module "gke" {
source = "../../modules/safer-cluster"
source = "terraform-google-modules/kubernetes-engine/google//modules/safer-cluster"
version = "~> 29.0"

project_id = module.enabled_google_apis.project_id
name = var.cluster_name
Expand Down
4 changes: 3 additions & 1 deletion examples/shared_vpc/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
region = var.region
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_autopilot_private/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../modules/beta-autopilot-private-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/beta-autopilot-private-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster"
regional = true
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_autopilot_private_non_default_sa/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../modules/beta-autopilot-private-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/beta-autopilot-private-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster"
regional = true
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_autopilot_public/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../modules/beta-autopilot-public-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/beta-autopilot-public-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster"
regional = true
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_regional/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = true
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_regional_beta/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../modules/beta-public-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/beta-public-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = var.regional
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_regional_private/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ data "google_compute_subnetwork" "subnetwork" {
}

module "gke" {
source = "../../modules/private-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/private-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = true
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_regional_private_beta/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ data "google_compute_subnetwork" "subnetwork" {
}

module "gke" {
source = "../../modules/beta-private-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/beta-private-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ data "google_compute_subnetwork" "subnetwork" {
}

module "gke" {
source = "../../modules/private-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/private-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = true
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_regional_with_gateway_api/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = true
Expand Down
7 changes: 5 additions & 2 deletions examples/simple_regional_with_kubeconfig/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = true
Expand All @@ -42,7 +44,8 @@ module "gke" {
}

module "gke_auth" {
source = "../../modules/auth"
source = "terraform-google-modules/kubernetes-engine/google//modules/auth"
version = "~> 29.0"

project_id = var.project_id
location = module.gke.location
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_regional_with_networking/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ module "gcp-network" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = var.cluster_name
regional = true
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_windows_node_pool/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../modules/beta-public-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/beta-public-cluster"
version = "~> 29.0"

project_id = var.project_id
regional = false
region = var.region
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_zonal_private/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ data "google_compute_subnetwork" "subnetwork" {
}

module "gke" {
source = "../../modules/private-cluster/"
source = "terraform-google-modules/kubernetes-engine/google//modules/private-cluster"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
regional = false
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_zonal_with_acm/acm.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
*/

module "acm" {
source = "../../modules/acm"
source = "terraform-google-modules/kubernetes-engine/google//modules/acm"
version = "~> 29.0"

project_id = var.project_id
location = module.gke.location
cluster_name = module.gke.name
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_zonal_with_acm/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
regional = false
region = var.region
Expand Down
8 changes: 6 additions & 2 deletions examples/simple_zonal_with_asm/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ data "google_project" "project" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = "test-prefix-cluster-test-suffix"
regional = false
Expand All @@ -54,7 +56,9 @@ module "gke" {
}

module "asm" {
source = "../../modules/asm"
source = "terraform-google-modules/kubernetes-engine/google//modules/asm"
version = "~> 29.0"

project_id = var.project_id
cluster_name = module.gke.name
cluster_location = module.gke.location
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_zonal_with_hub/hub.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
*/

module "hub" {
source = "../../modules/fleet-membership"
source = "terraform-google-modules/kubernetes-engine/google//modules/fleet-membership"
version = "~> 29.0"

project_id = var.project_id
location = module.gke.location
cluster_name = module.gke.name
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_zonal_with_hub/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
regional = false
region = var.region
Expand Down
4 changes: 3 additions & 1 deletion examples/simple_zonal_with_hub_kubeconfig/hub.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
*/

module "hub" {
source = "../../modules/hub-legacy"
source = "terraform-google-modules/kubernetes-engine/google//modules/hub-legacy"
version = "~> 29.0"

project_id = var.project_id
location = "remote"
cluster_name = kind_cluster.test-cluster.name
Expand Down
4 changes: 3 additions & 1 deletion examples/stub_domains/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
region = var.region
Expand Down
3 changes: 2 additions & 1 deletion examples/stub_domains_private/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ data "google_compute_subnetwork" "subnetwork" {
}

module "gke" {
source = "../../modules/private-cluster"
source = "terraform-google-modules/kubernetes-engine/google//modules/private-cluster"
version = "~> 29.0"

ip_range_pods = var.ip_range_pods
ip_range_services = var.ip_range_services
Expand Down
4 changes: 3 additions & 1 deletion examples/stub_domains_upstream_nameservers/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ provider "kubernetes" {
}

module "gke" {
source = "../../"
source = "terraform-google-modules/kubernetes-engine/google"
version = "~> 29.0"

project_id = var.project_id
name = "${local.cluster_type}-cluster${var.cluster_name_suffix}"
region = var.region
Expand Down
Loading

0 comments on commit c3abc08

Please sign in to comment.