From 6e47c50654ab0f2a0bd91ebc5bea22c11179271b Mon Sep 17 00:00:00 2001 From: Otho Date: Sat, 31 Dec 2022 02:48:10 -0500 Subject: [PATCH] Updates to dns terraform. --- domain.tf | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/domain.tf b/domain.tf index d994333..934efa7 100644 --- a/domain.tf +++ b/domain.tf @@ -18,11 +18,21 @@ terraform { provider "namecheap" {} +variable "saline-rproxy" { + type = string + default = "rprxy-0.saline.o4data.net." +} + +variable "stashbox-vip" { + type = string + default = "stashbox.delhi.o4data.net." +} + resource "namecheap_domain_records" "othonotes" { domain = "othonotes.com" record { hostname = "@" - address = "rprxy-0.saline.o4data.net" + address = var.saline-rproxy type = "ALIAS" ttl = 300 } @@ -38,7 +48,7 @@ resource "namecheap_domain_records" "othostash" { record { hostname = "@" - address = "stashbox.delhi.o4data.net" + address = var.stashbox-vip type = "ALIAS" ttl = 300 } @@ -49,12 +59,12 @@ resource "namecheap_domain_records" "othostash" { } record { hostname = "websites" - address = "rprxy-0.saline.o4data.net" + address = var.saline-rproxy type = "CNAME" } record { hostname = "filemanager" - address = "rprxy-0.saline.o4data.net" + address = var.saline-rproxy type = "CNAME" } }