mirror of
https://github.com/google/nomulus.git
synced 2025-04-30 12:07:51 +02:00
Patch terraform changes made internally (#651)
There were several LSC that made some formatting changes to our .tf files. Export these changes externally for consistency.
This commit is contained in:
parent
39e6b85837
commit
b7b4658d0c
9 changed files with 34 additions and 30 deletions
|
@ -1,4 +1,3 @@
|
||||||
provider "google" {
|
provider "google" {
|
||||||
version = ">= 1.13.0"
|
|
||||||
project = var.proxy_project_name
|
project = var.proxy_project_name
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,7 +17,7 @@ module "proxy_gke_apac" {
|
||||||
}
|
}
|
||||||
|
|
||||||
locals {
|
locals {
|
||||||
"proxy_instance_groups" = {
|
proxy_instance_groups = {
|
||||||
americas = module.proxy_gke_americas.proxy_instance_group
|
americas = module.proxy_gke_americas.proxy_instance_group
|
||||||
emea = module.proxy_gke_emea.proxy_instance_group
|
emea = module.proxy_gke_emea.proxy_instance_group
|
||||||
apac = module.proxy_gke_apac.proxy_instance_group
|
apac = module.proxy_gke_apac.proxy_instance_group
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
locals {
|
locals {
|
||||||
proxy_cluster_zone = "${lookup(var.proxy_cluster_zones, var.proxy_cluster_region)}"
|
proxy_cluster_zone = lookup(var.proxy_cluster_zones, var.proxy_cluster_region)
|
||||||
}
|
}
|
||||||
|
|
||||||
resource "google_container_cluster" "proxy_cluster" {
|
resource "google_container_cluster" "proxy_cluster" {
|
||||||
name = "proxy-cluster-${var.proxy_cluster_region}"
|
name = "proxy-cluster-${var.proxy_cluster_region}"
|
||||||
zone = local.proxy_cluster_zone
|
location = local.proxy_cluster_zone
|
||||||
|
|
||||||
timeouts {
|
timeouts {
|
||||||
update = "30m"
|
update = "30m"
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
output "proxy_instance_group" {
|
output "proxy_instance_group" {
|
||||||
value = "${google_container_cluster.proxy_cluster.instance_group_urls[0]}"
|
value = google_container_cluster.proxy_cluster.instance_group_urls[0]
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@ variable "proxy_service_account_email" {}
|
||||||
variable "proxy_cluster_region" {}
|
variable "proxy_cluster_region" {}
|
||||||
|
|
||||||
variable "proxy_cluster_zones" {
|
variable "proxy_cluster_zones" {
|
||||||
type = "map"
|
type = map
|
||||||
|
|
||||||
default = {
|
default = {
|
||||||
americas = "us-east4-a"
|
americas = "us-east4-a"
|
||||||
|
|
|
@ -1,6 +1,11 @@
|
||||||
resource "google_dns_managed_zone" "proxy_domain" {
|
resource "google_dns_managed_zone" "proxy_domain" {
|
||||||
name = "proxy-domain"
|
name = "proxy-domain"
|
||||||
dns_name = "${var.proxy_domain_name}."
|
dns_name = "${var.proxy_domain_name}."
|
||||||
|
|
||||||
|
# This is a safeguard for the google provider update to 2.8.0.
|
||||||
|
# cl/264641943
|
||||||
|
# If you like, you can remove this line after the update.
|
||||||
|
lifecycle { prevent_destroy = true }
|
||||||
}
|
}
|
||||||
|
|
||||||
module "proxy_networking" {
|
module "proxy_networking" {
|
||||||
|
|
|
@ -16,11 +16,11 @@ resource "google_compute_firewall" "proxy_firewall" {
|
||||||
protocol = "tcp"
|
protocol = "tcp"
|
||||||
|
|
||||||
ports = [
|
ports = [
|
||||||
"${var.proxy_ports["epp"]}",
|
var.proxy_ports["epp"],
|
||||||
"${var.proxy_ports["whois"]}",
|
var.proxy_ports["whois"],
|
||||||
"${var.proxy_ports["health_check"]}",
|
var.proxy_ports["health_check"],
|
||||||
"${var.proxy_ports["http-whois"]}",
|
var.proxy_ports["http-whois"],
|
||||||
"${var.proxy_ports["https-whois"]}",
|
var.proxy_ports["https-whois"],
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -38,7 +38,7 @@ resource "google_compute_health_check" "proxy_health_check" {
|
||||||
name = "proxy-health-check${var.suffix}"
|
name = "proxy-health-check${var.suffix}"
|
||||||
|
|
||||||
tcp_health_check {
|
tcp_health_check {
|
||||||
port = "${var.proxy_ports["health_check"]}"
|
port = var.proxy_ports["health_check"]
|
||||||
request = "HEALTH_CHECK_REQUEST"
|
request = "HEALTH_CHECK_REQUEST"
|
||||||
response = "HEALTH_CHECK_RESPONSE"
|
response = "HEALTH_CHECK_RESPONSE"
|
||||||
}
|
}
|
||||||
|
@ -49,7 +49,7 @@ resource "google_compute_health_check" "proxy_http_health_check" {
|
||||||
|
|
||||||
http_health_check {
|
http_health_check {
|
||||||
host = "health-check.invalid"
|
host = "health-check.invalid"
|
||||||
port = "${var.proxy_ports["http-whois"]}"
|
port = var.proxy_ports["http-whois"]
|
||||||
request_path = "/"
|
request_path = "/"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -66,15 +66,15 @@ resource "google_compute_backend_service" "epp_backend_service" {
|
||||||
port_name = "epp${var.suffix}"
|
port_name = "epp${var.suffix}"
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["americas"]}"
|
group = var.proxy_instance_groups["americas"]
|
||||||
}
|
}
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["emea"]}"
|
group = var.proxy_instance_groups["emea"]
|
||||||
}
|
}
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["apac"]}"
|
group = var.proxy_instance_groups["apac"]
|
||||||
}
|
}
|
||||||
|
|
||||||
health_checks = [
|
health_checks = [
|
||||||
|
@ -89,15 +89,15 @@ resource "google_compute_backend_service" "whois_backend_service" {
|
||||||
port_name = "whois${var.suffix}"
|
port_name = "whois${var.suffix}"
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["americas"]}"
|
group = var.proxy_instance_groups["americas"]
|
||||||
}
|
}
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["emea"]}"
|
group = var.proxy_instance_groups["emea"]
|
||||||
}
|
}
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["apac"]}"
|
group = var.proxy_instance_groups["apac"]
|
||||||
}
|
}
|
||||||
|
|
||||||
health_checks = [
|
health_checks = [
|
||||||
|
@ -112,15 +112,15 @@ resource "google_compute_backend_service" "https_whois_backend_service" {
|
||||||
port_name = "https-whois${var.suffix}"
|
port_name = "https-whois${var.suffix}"
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["americas"]}"
|
group = var.proxy_instance_groups["americas"]
|
||||||
}
|
}
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["emea"]}"
|
group = var.proxy_instance_groups["emea"]
|
||||||
}
|
}
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["apac"]}"
|
group = var.proxy_instance_groups["apac"]
|
||||||
}
|
}
|
||||||
|
|
||||||
health_checks = [
|
health_checks = [
|
||||||
|
@ -135,15 +135,15 @@ resource "google_compute_backend_service" "http_whois_backend_service" {
|
||||||
port_name = "http-whois${var.suffix}"
|
port_name = "http-whois${var.suffix}"
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["americas"]}"
|
group = var.proxy_instance_groups["americas"]
|
||||||
}
|
}
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["emea"]}"
|
group = var.proxy_instance_groups["emea"]
|
||||||
}
|
}
|
||||||
|
|
||||||
backend {
|
backend {
|
||||||
group = "${var.proxy_instance_groups["apac"]}"
|
group = var.proxy_instance_groups["apac"]
|
||||||
}
|
}
|
||||||
|
|
||||||
health_checks = [
|
health_checks = [
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
# Instance groups that the load balancer forwards traffic to.
|
# Instance groups that the load balancer forwards traffic to.
|
||||||
variable "proxy_instance_groups" {
|
variable "proxy_instance_groups" {
|
||||||
type = "map"
|
type = map
|
||||||
}
|
}
|
||||||
|
|
||||||
# Suffix (such as "-canary") added to the resource names.
|
# Suffix (such as "-canary") added to the resource names.
|
||||||
|
@ -10,7 +10,7 @@ variable "suffix" {
|
||||||
|
|
||||||
# Node ports exposed by the proxy.
|
# Node ports exposed by the proxy.
|
||||||
variable "proxy_ports" {
|
variable "proxy_ports" {
|
||||||
type = "map"
|
type = map
|
||||||
}
|
}
|
||||||
|
|
||||||
# DNS zone for the proxy domain.
|
# DNS zone for the proxy domain.
|
||||||
|
|
|
@ -22,7 +22,7 @@ variable "proxy_key" {
|
||||||
|
|
||||||
# Node ports exposed by the proxy.
|
# Node ports exposed by the proxy.
|
||||||
variable "proxy_ports" {
|
variable "proxy_ports" {
|
||||||
type = "map"
|
type = map
|
||||||
|
|
||||||
default = {
|
default = {
|
||||||
health_check = 30000
|
health_check = 30000
|
||||||
|
@ -35,7 +35,7 @@ variable "proxy_ports" {
|
||||||
|
|
||||||
# Node ports exposed by the canary proxy.
|
# Node ports exposed by the canary proxy.
|
||||||
variable "proxy_ports_canary" {
|
variable "proxy_ports_canary" {
|
||||||
type = "map"
|
type = map
|
||||||
|
|
||||||
default = {
|
default = {
|
||||||
health_check = 31000
|
health_check = 31000
|
||||||
|
|
Loading…
Add table
Reference in a new issue