From 410ddef7351ff7f784ff7a86ec7969230f3ac093 Mon Sep 17 00:00:00 2001 From: clarkzjw Date: Fri, 13 Jan 2023 01:22:11 -0800 Subject: update files --- clarkzjw.ca/cloudflare.tf | 22 ++++------------------ clarkzjw.ca/variables.tf | 4 ++++ clarkzjw.ca/versions.tf | 8 ++++++++ 3 files changed, 16 insertions(+), 18 deletions(-) create mode 100644 clarkzjw.ca/variables.tf create mode 100644 clarkzjw.ca/versions.tf diff --git a/clarkzjw.ca/cloudflare.tf b/clarkzjw.ca/cloudflare.tf index 1a17e3c..68ab88f 100644 --- a/clarkzjw.ca/cloudflare.tf +++ b/clarkzjw.ca/cloudflare.tf @@ -1,35 +1,21 @@ -terraform { - required_providers { - cloudflare = { - source = "cloudflare/cloudflare" - version = "~> 3.29" - } - } -} - -variable "homelab_main_domain" { - description = "HomeLab Main Domain" - default = "clarkzjw.ca" -} - data "cloudflare_zones" "homelab_main_domain" { filter { name = var.homelab_main_domain } } -variable "homelab_root" { +variable "homelab_www_domain" { default = "clarkzjw.ca" } -variable "homelab_root_ip" { +variable "homelab_www_ip" { default = "8.8.8.8" } resource "cloudflare_record" "main" { zone_id = data.cloudflare_zones.homelab_main_domain.zones[0].id - name = var.homelab_root - value = var.homelab_root_ip + name = var.homelab_www_domain + value = var.homelab_www_ip type = "A" ttl = 1 diff --git a/clarkzjw.ca/variables.tf b/clarkzjw.ca/variables.tf new file mode 100644 index 0000000..2847d76 --- /dev/null +++ b/clarkzjw.ca/variables.tf @@ -0,0 +1,4 @@ +variable "homelab_main_domain" { + description = "HomeLab Main Domain" + default = "clarkzjw.ca" +} diff --git a/clarkzjw.ca/versions.tf b/clarkzjw.ca/versions.tf new file mode 100644 index 0000000..1551173 --- /dev/null +++ b/clarkzjw.ca/versions.tf @@ -0,0 +1,8 @@ +terraform { + required_providers { + cloudflare = { + source = "cloudflare/cloudflare" + version = "~> 3.29" + } + } +} -- cgit v1.2.3