From 4feb85393eb9a22e0e3e68e6d140a61db6ec12c6 Mon Sep 17 00:00:00 2001 From: Moritz Graf Date: Thu, 9 Apr 2020 23:13:20 +0200 Subject: [PATCH] Changin corona & corona-api to haumdaucher --- terraform/ovh.tf | 15 ++++++- terraform/terraform.tfstate | 65 +++++++++++++++++------------- terraform/terraform.tfstate.backup | 24 ++++++++++- 3 files changed, 73 insertions(+), 31 deletions(-) diff --git a/terraform/ovh.tf b/terraform/ovh.tf index 6bec40f..da0cbaf 100644 --- a/terraform/ovh.tf +++ b/terraform/ovh.tf @@ -10,7 +10,7 @@ locals { } variable "subdomains_moritzgraf" { - default = ["git","corona","corona-api","auth","prometheus","alertmanager","chat","mqtt", "cloud", + default = ["git","auth","prometheus","alertmanager","chat","mqtt", "cloud", "monitoring","smtp","pop3","imap","jaeger","ldap","code","hub", "grafana","tt-rss","phpmyadmin","phppgadmin","www","rstudio","code" ] } @@ -24,6 +24,19 @@ resource "ovh_domain_zone_record" "moritzgraf_subdomains" { target = "moritzgraf.de." } +variable "subdomains_moritzgraf_k8s" { + default = ["corona","corona-api" ] +} + +resource "ovh_domain_zone_record" "moritzgraf_subdomains_k8s" { + for_each = toset( var.subdomains_moritzgraf_k8s ) + zone = "moritzgraf.de" + subdomain = each.key + fieldtype = "CNAME" + ttl = local.ttl + target = "haumdaucher.de." +} + variable "subdomains_haumdaucher" { default = ["corona"] } diff --git a/terraform/terraform.tfstate b/terraform/terraform.tfstate index ad0ec72..33c9e1c 100644 --- a/terraform/terraform.tfstate +++ b/terraform/terraform.tfstate @@ -1,7 +1,7 @@ { "version": 4, - "terraform_version": "0.12.20", - "serial": 73, + "terraform_version": "0.12.24", + "serial": 78, "lineage": "8aff5d23-05f6-10eb-0ae6-1084c787677e", "outputs": {}, "resources": [ @@ -337,32 +337,6 @@ }, "private": "bnVsbA==" }, - { - "index_key": "corona", - "schema_version": 0, - "attributes": { - "fieldtype": "CNAME", - "id": "5110384646", - "subdomain": "corona", - "target": "moritzgraf.de.", - "ttl": 60, - "zone": "moritzgraf.de" - }, - "private": "bnVsbA==" - }, - { - "index_key": "corona-api", - "schema_version": 0, - "attributes": { - "fieldtype": "CNAME", - "id": "5110478866", - "subdomain": "corona-api", - "target": "moritzgraf.de.", - "ttl": 60, - "zone": "moritzgraf.de" - }, - "private": "bnVsbA==" - }, { "index_key": "git", "schema_version": 0, @@ -573,6 +547,41 @@ } ] }, + { + "mode": "managed", + "type": "ovh_domain_zone_record", + "name": "moritzgraf_subdomains_k8s", + "each": "map", + "provider": "provider.ovh", + "instances": [ + { + "index_key": "corona", + "schema_version": 0, + "attributes": { + "fieldtype": "CNAME", + "id": "5113233478", + "subdomain": "corona", + "target": "haumdaucher.de.", + "ttl": 60, + "zone": "moritzgraf.de" + }, + "private": "bnVsbA==" + }, + { + "index_key": "corona-api", + "schema_version": 0, + "attributes": { + "fieldtype": "CNAME", + "id": "5113233479", + "subdomain": "corona-api", + "target": "haumdaucher.de.", + "ttl": 60, + "zone": "moritzgraf.de" + }, + "private": "bnVsbA==" + } + ] + }, { "mode": "managed", "type": "ovh_domain_zone_record", diff --git a/terraform/terraform.tfstate.backup b/terraform/terraform.tfstate.backup index 00a045a..df70ab5 100644 --- a/terraform/terraform.tfstate.backup +++ b/terraform/terraform.tfstate.backup @@ -1,7 +1,7 @@ { "version": 4, - "terraform_version": "0.12.20", - "serial": 71, + "terraform_version": "0.12.24", + "serial": 73, "lineage": "8aff5d23-05f6-10eb-0ae6-1084c787677e", "outputs": {}, "resources": [ @@ -225,6 +225,26 @@ } ] }, + { + "mode": "managed", + "type": "ovh_domain_zone_record", + "name": "haumdaucher_wildcard_domain", + "provider": "provider.ovh", + "instances": [ + { + "schema_version": 0, + "attributes": { + "fieldtype": "A", + "id": "5112336220", + "subdomain": "*", + "target": "91.121.84.190", + "ttl": 60, + "zone": "haumdaucher.de" + }, + "private": "bnVsbA==" + } + ] + }, { "mode": "managed", "type": "ovh_domain_zone_record",