aboutsummaryrefslogtreecommitdiff
path: root/terraform/dns
diff options
context:
space:
mode:
Diffstat (limited to 'terraform/dns')
-rw-r--r--terraform/dns/backend.tf16
-rw-r--r--terraform/dns/dn42.tf113
-rw-r--r--terraform/dns/main.tf12
-rw-r--r--terraform/dns/terraform.tfstate52
-rw-r--r--terraform/dns/terragrunt.hcl3
-rw-r--r--terraform/dns/trygvis.tf37
-rw-r--r--terraform/dns/vpn-cname.tf7
7 files changed, 220 insertions, 20 deletions
diff --git a/terraform/dns/backend.tf b/terraform/dns/backend.tf
new file mode 100644
index 0000000..4f05aaf
--- /dev/null
+++ b/terraform/dns/backend.tf
@@ -0,0 +1,16 @@
+# Generated by Terragrunt. Sig: nIlQXj57tbuaRZEa
+terraform {
+ required_version = "~> 1.9.5"
+
+ backend "s3" {
+ bucket = "terraform-a6726272-73ff-11ed-8bdd-c79eb8376e05"
+ key = "dns/terraform.tfstate"
+ skip_region_validation = true
+ skip_credentials_validation = true
+ skip_metadata_api_check = true
+ skip_requesting_account_id = true
+ skip_s3_checksum = true
+ region = "eu-central-1"
+ endpoints = { s3 : "https://eu-central-1.linodeobjects.com" }
+ }
+}
diff --git a/terraform/dns/dn42.tf b/terraform/dns/dn42.tf
new file mode 100644
index 0000000..c7aab96
--- /dev/null
+++ b/terraform/dns/dn42.tf
@@ -0,0 +1,113 @@
+# Generated from ansible data
+
+resource "linode_domain_record" "dn42-conflatorio" {
+ domain_id = linode_domain.root.id
+ name = "conflatorio.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2008:8042:32ff:fe0c:7161"
+}
+
+resource "linode_domain_record" "dn42-coregonus" {
+ domain_id = linode_domain.root.id
+ name = "coregonus.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2006:2e0:4cff:fe98:1bb5"
+}
+
+resource "linode_domain_record" "dn42-danneri" {
+ domain_id = linode_domain.root.id
+ name = "danneri.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2008:9422:d355:95b7:f170"
+}
+
+resource "linode_domain_record" "dn42-garasjepi" {
+ domain_id = linode_domain.root.id
+ name = "garasjepi.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2006:e9f7:418f:49fd:8d2e"
+}
+
+resource "linode_domain_record" "dn42-ha-kv24" {
+ domain_id = linode_domain.root.id
+ name = "ha-kv24.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2006:18a:90f:4264:8ca0"
+}
+
+resource "linode_domain_record" "dn42-ha-lhn2" {
+ domain_id = linode_domain.root.id
+ name = "ha-lhn2.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2008:9c59:926f:1dc9:89db"
+}
+
+resource "linode_domain_record" "dn42-hash" {
+ domain_id = linode_domain.root.id
+ name = "hash.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2007::ffff"
+}
+
+resource "linode_domain_record" "dn42-kjell" {
+ domain_id = linode_domain.root.id
+ name = "kjell.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2006:2f0:cbff:fefe:d98c"
+}
+
+resource "linode_domain_record" "dn42-knot" {
+ domain_id = linode_domain.root.id
+ name = "knot.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2004::ffff"
+}
+
+resource "linode_domain_record" "dn42-kv24ix" {
+ domain_id = linode_domain.root.id
+ name = "kv24ix.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2006::ffff"
+}
+
+resource "linode_domain_record" "dn42-lhn2-z2m" {
+ domain_id = linode_domain.root.id
+ name = "lhn2-z2m.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2008:9aed:e460:1711:7dd"
+}
+
+resource "linode_domain_record" "dn42-lhn2pi" {
+ domain_id = linode_domain.root.id
+ name = "lhn2pi.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2008::ffff"
+}
+
+resource "linode_domain_record" "dn42-netbox" {
+ domain_id = linode_domain.root.id
+ name = "netbox.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2006:be24:11ff:febb:5c7f"
+}
+
+resource "linode_domain_record" "dn42-node1" {
+ domain_id = linode_domain.root.id
+ name = "node1.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2002::ffff"
+}
+
+resource "linode_domain_record" "dn42-node2" {
+ domain_id = linode_domain.root.id
+ name = "node2.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2003::ffff"
+}
+
+resource "linode_domain_record" "dn42-unifi" {
+ domain_id = linode_domain.root.id
+ name = "unifi.dn42"
+ record_type = "AAAA"
+ target = "fdb1:4242:3538:2008:5054:ff:fe4d:96c"
+}
diff --git a/terraform/dns/main.tf b/terraform/dns/main.tf
index 753ef75..812f3b2 100644
--- a/terraform/dns/main.tf
+++ b/terraform/dns/main.tf
@@ -1,16 +1,4 @@
terraform {
- required_version = "~> 1.3.6"
-
- backend "s3" {
- bucket = "terraform-a6726272-73ff-11ed-8bdd-c79eb8376e05"
- key = "dns/terraform.tfstate"
- region = "eu-central-1"
- skip_region_validation = true
- skip_credentials_validation = true
- skip_metadata_api_check = true
- endpoint = "eu-central-1.linodeobjects.com"
- }
-
required_providers {
linode = {
version = "2.7.1"
diff --git a/terraform/dns/terraform.tfstate b/terraform/dns/terraform.tfstate
new file mode 100644
index 0000000..891db4d
--- /dev/null
+++ b/terraform/dns/terraform.tfstate
@@ -0,0 +1,52 @@
+{
+ "version": 3,
+ "serial": 1,
+ "lineage": "8244bd55-1992-3e9a-1072-28df4fb0d2f2",
+ "backend": {
+ "type": "s3",
+ "config": {
+ "access_key": null,
+ "acl": null,
+ "assume_role_duration_seconds": null,
+ "assume_role_policy": null,
+ "assume_role_policy_arns": null,
+ "assume_role_tags": null,
+ "assume_role_transitive_tag_keys": null,
+ "bucket": "terraform-a6726272-73ff-11ed-8bdd-c79eb8376e05",
+ "dynamodb_endpoint": null,
+ "dynamodb_table": null,
+ "encrypt": null,
+ "endpoint": "eu-central-1.linodeobjects.com",
+ "external_id": null,
+ "force_path_style": null,
+ "iam_endpoint": null,
+ "key": "dns/terraform.tfstate",
+ "kms_key_id": null,
+ "max_retries": null,
+ "profile": null,
+ "region": "eu-central-1",
+ "role_arn": null,
+ "secret_key": null,
+ "session_name": null,
+ "shared_credentials_file": null,
+ "skip_credentials_validation": true,
+ "skip_metadata_api_check": true,
+ "skip_region_validation": true,
+ "sse_customer_key": null,
+ "sts_endpoint": null,
+ "token": null,
+ "workspace_key_prefix": null
+ },
+ "hash": 1226279900
+ },
+ "modules": [
+ {
+ "path": [
+ "root"
+ ],
+ "outputs": {},
+ "resources": {},
+ "depends_on": []
+ }
+ ]
+}
diff --git a/terraform/dns/terragrunt.hcl b/terraform/dns/terragrunt.hcl
new file mode 100644
index 0000000..e147285
--- /dev/null
+++ b/terraform/dns/terragrunt.hcl
@@ -0,0 +1,3 @@
+include "root" {
+ path = find_in_parent_folders()
+}
diff --git a/terraform/dns/trygvis.tf b/terraform/dns/trygvis.tf
index 608dd3e..5dfc8cb 100644
--- a/terraform/dns/trygvis.tf
+++ b/terraform/dns/trygvis.tf
@@ -17,6 +17,13 @@ resource "linode_domain_record" "root-a" {
target = "176.58.112.84"
}
+resource "linode_domain_record" "root-aaaa" {
+ domain_id = linode_domain.root.id
+ name = ""
+ record_type = "AAAA"
+ target = "2a01:7e00::f03c:91ff:feae:93a3"
+}
+
resource "linode_domain_record" "root-mx" {
domain_id = linode_domain.root.id
name = ""
@@ -158,6 +165,27 @@ resource "linode_domain_record" "unifi" {
target = "trygvis.io"
}
+resource "linode_domain_record" "kv24" {
+ domain_id = linode_domain.root.id
+ name = "kv24"
+ record_type = "CNAME"
+ target = "trygvis.io"
+}
+
+resource "linode_domain_record" "kv24ix" {
+ domain_id = linode_domain.root.id
+ name = "kv24ix"
+ record_type = "A"
+ target = "81.166.205.176"
+}
+
+resource "linode_domain_record" "lhn2" {
+ domain_id = linode_domain.root.id
+ name = "lhn2"
+ record_type = "CNAME"
+ target = "trygvis.io"
+}
+
# Aliases for vs.trygvis.io
resource "linode_domain_record" "nextcloud" {
domain_id = linode_domain.root.id
@@ -170,7 +198,14 @@ resource "linode_domain_record" "grafana" {
domain_id = linode_domain.root.id
name = "grafana"
record_type = "CNAME"
- target = "vs.trygvis.io"
+ target = "hash.trygvis.io"
+}
+
+resource "linode_domain_record" "loki" {
+ domain_id = linode_domain.root.id
+ name = "loki"
+ record_type = "CNAME"
+ target = "hash.trygvis.io"
}
resource "linode_domain_record" "owncloud" {
diff --git a/terraform/dns/vpn-cname.tf b/terraform/dns/vpn-cname.tf
index 7a9fba4..c03b2bb 100644
--- a/terraform/dns/vpn-cname.tf
+++ b/terraform/dns/vpn-cname.tf
@@ -19,13 +19,6 @@ resource "linode_domain_record" "vpn-unifi" {
target = "${linode_domain_record.net-conflatorio.name}.trygvis.io"
}
-resource "linode_domain_record" "vpn-grafana" {
- domain_id = linode_domain.root.id
- name = "grafana.vpn"
- record_type = "CNAME"
- target = "${linode_domain_record.net-conflatorio.name}.trygvis.io"
-}
-
resource "linode_domain_record" "vpn-influxdb" {
domain_id = linode_domain.root.id
name = "influxdb.vpn"