Commit 30c2f056 authored by Alejandro Rodríguez's avatar Alejandro Rodríguez

Setup network peering with the DR environment

parent 90beb025
......@@ -34,8 +34,9 @@ variable "internal_subnets" {
variable "other_monitoring_subnets" {
type = "list"
# 10.226.1.0/24 is gstg monitoring subnet
default = ["10.226.1.0/24"]
# 10.226.1.0/24: gstg
# 10.251.17.0/24: dr
default = ["10.226.1.0/24", "10.251.17.0/24"]
}
variable "monitoring_hosts" {
......
......@@ -34,8 +34,9 @@ variable "internal_subnets" {
variable "other_monitoring_subnets" {
type = "list"
# 10.219.1.0/24 is gprd monitoring subnet
default = ["10.219.1.0/24"]
# 10.219.1.0/24: gprd
# 10.251.17.0/24: dr
default = ["10.219.1.0/24", "10.251.17.0/24"]
}
##################
......@@ -50,11 +51,12 @@ variable "peer_networks" {
type = "map"
default = {
"names" = ["ops", "gprd"]
"names" = ["ops", "gprd", "dr"]
"links" = [
"https://www.googleapis.com/compute/v1/projects/gitlab-ops/global/networks/ops",
"https://www.googleapis.com/compute/v1/projects/gitlab-production/global/networks/gprd",
"https://www.googleapis.com/compute/v1/projects/gitlab-dr/global/networks/dr",
]
}
}
......
......@@ -49,6 +49,12 @@ resource "google_compute_network_peering" "peering_gstg" {
peer_network = "${var.network_gstg}"
}
resource "google_compute_network_peering" "peering_dr" {
name = "peering-dr"
network = "${var.network_ops}"
peer_network = "${var.network_dr}"
}
##################################
#
# Log Proxy
......
......@@ -167,6 +167,10 @@ variable "network_gstg" {
default = "https://www.googleapis.com/compute/v1/projects/gitlab-staging-1/global/networks/gstg"
}
variable "network_dr" {
default = "https://www.googleapis.com/compute/v1/projects/gitlab-dr/global/networks/dr"
}
variable "tcp_lbs_bastion" {
type = "map"
......
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