Update GKE in testbed

Update testbed to latest GKE module.

https://gitlab.com/gitlab-com/gl-infra/infrastructure/-/issues/7861Signed-off-by: Ben Kochie's avatarBen Kochie <[email protected]>
parent b570c758
......@@ -27,13 +27,13 @@ variable "gitlab_net_zone_id" {
## Google
provider "google" {
version = "~> 2.20.0"
version = "~> 3.39"
project = var.project
region = var.region
}
provider "google-beta" {
version = "~> 3.22.0"
version = "~> 3.39"
project = var.project
region = var.region
}
......@@ -287,18 +287,30 @@ module "gitaly" {
# for this are https://gitlab.com/gitlab-com/runbooks/tree/master/docs/uncategorized/gke-runner
module "gke-runner" {
environment = var.environment
name = "gke-runner"
environment = var.environment
vpc = module.network.self_link
# TODO: migrate to v6.0.0+: https://gitlab.com/gitlab-com/gl-infra/infrastructure/issues/7861
source = "git::ssh://[email protected]/gitlab-com/gl-infra/terraform-modules/google/gke.git?ref=craigf/v1.0.0-tf0.12"
initial_node_count = 1
ip_cidr_range = var.subnetworks["gke-runner"]
dns_zone_name = var.dns_zone_name
machine_type = var.machine_types["gke-runner"]
project = var.project
region = var.region
pod_ip_cidr_range = var.subnetworks["gke-runner-pod-cidr"]
service_ip_cidr_range = var.subnetworks["gke-runner-service-cidr"]
kubernetes_version = "1.13.12-gke.25"
source = "git::ssh://[email protected]/gitlab-com/gl-infra/terraform-modules/google/gke.git?ref=v10.7.1"
authorized_master_access = [
]
ip_cidr_range = var.subnetworks["gke-runner"]
disable_network_policy = "false"
dns_zone_name = var.dns_zone_name
kubernetes_version = "1.16"
private_master_cidr = var.master_cidr_subnets["gke-runner"]
project = var.project
region = var.region
pod_ip_cidr_range = var.subnetworks["gke-runner-pod-cidr"]
service_ip_cidr_range = var.subnetworks["gke-runner-service-cidr"]
service_account = "default"
node_pools = {
"default-20200921-0" = {
machine_type = var.machine_types["gke-runner"]
type = "default"
}
}
}
......@@ -33,12 +33,12 @@ variable "machine_types" {
type = map(string)
default = {
"bastion" = "n1-standard-1"
"web" = "n1-standard-16"
"monitoring" = "n1-standard-2"
"sd-exporter" = "n1-standard-1"
"gke-runner" = "n1-standard-2"
"gitaly" = "n1-standard-2"
"bastion" = "n1-standard-1"
"web" = "n1-standard-16"
"monitoring" = "n1-standard-2"
"sd-exporter" = "n1-standard-1"
"gke-runner" = "n1-standard-2"
"gitaly" = "n1-standard-2"
}
}
......@@ -104,6 +104,15 @@ variable "subnetworks" {
}
}
variable "master_cidr_subnets" {
type = map(string)
default = {
"gke-runner" = "172.16.0.0/28"
}
}
##################
# Network Peering
##################
......@@ -127,9 +136,9 @@ variable "public_ports" {
type = map(list(string))
default = {
"bastion" = [22]
"sd-exporter" = []
"gitaly" = []
"bastion" = [22]
"sd-exporter" = []
"gitaly" = []
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment