Skip to content

Commit

Permalink
chore(terraform,cloudflare): swap deprecated key
Browse files Browse the repository at this point in the history
  • Loading branch information
raisedadead committed Aug 28, 2024
1 parent f417cee commit d20a303
Show file tree
Hide file tree
Showing 15 changed files with 75 additions and 76 deletions.
8 changes: 4 additions & 4 deletions terraform/ops-cluster-mintworld/network/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -259,8 +259,8 @@ resource "cloudflare_record" "internal_lb_dnsrecord" {
proxied = false
ttl = 120

name = "${local.cloudflare_subdomain}.${data.cloudflare_zone.cf_zone.name}"
value = aws_lb.internal_lb.dns_name
name = "${local.cloudflare_subdomain}.${data.cloudflare_zone.cf_zone.name}"
content = aws_lb.internal_lb.dns_name
}

resource "cloudflare_record" "all__internal_lb_dnsrecord" {
Expand All @@ -269,6 +269,6 @@ resource "cloudflare_record" "all__internal_lb_dnsrecord" {
proxied = false
ttl = 120

name = "*.${local.cloudflare_subdomain}.${data.cloudflare_zone.cf_zone.name}"
value = aws_lb.internal_lb.dns_name
name = "*.${local.cloudflare_subdomain}.${data.cloudflare_zone.cf_zone.name}"
content = aws_lb.internal_lb.dns_name
}
8 changes: 4 additions & 4 deletions terraform/ops-standalone/next-00-backoffice.tf
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ resource "cloudflare_record" "ops_backoffice_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.backoffice.${var.network_subdomain}"
value = linode_instance.ops_backoffice.ip_address
name = "pub.backoffice.${var.network_subdomain}"
content = linode_instance.ops_backoffice.ip_address
}

resource "cloudflare_record" "ops_backoffice_dnsrecord__private" {
Expand All @@ -107,8 +107,8 @@ resource "cloudflare_record" "ops_backoffice_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.backoffice"
value = linode_instance.ops_backoffice.private_ip_address
name = "prv.backoffice"
content = linode_instance.ops_backoffice.private_ip_address
}

resource "linode_firewall" "ops_backoffice_firewall" {
Expand Down
8 changes: 4 additions & 4 deletions terraform/ops-test/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,8 @@ resource "cloudflare_record" "ops_test_records" {
proxied = false
ttl = 120

name = "test"
value = linode_instance.ops_test.ip_address
name = "test"
content = linode_instance.ops_test.ip_address
}

resource "cloudflare_record" "ops_test_records__public" {
Expand All @@ -136,8 +136,8 @@ resource "cloudflare_record" "ops_test_records__public" {
proxied = false
ttl = 120

name = "pub.test.${var.network_subdomain}"
value = linode_instance.ops_test.ip_address
name = "pub.test.${var.network_subdomain}"
content = linode_instance.ops_test.ip_address
}

resource "linode_firewall" "ops_test_firewall" {
Expand Down
12 changes: 6 additions & 6 deletions terraform/prd-cluster-oldeworld/next-01-pxy.tf
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,8 @@ resource "cloudflare_record" "prd_oldeworld_pxy_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "pxy-${count.index + 1}.oldeworld.prd"
value = trimsuffix(linode_instance_config.prd_oldeworld_pxy_config[count.index].interface[1].ipam_address, "/24")
name = "pxy-${count.index + 1}.oldeworld.prd"
content = trimsuffix(linode_instance_config.prd_oldeworld_pxy_config[count.index].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "prd_oldeworld_pxy_dnsrecord__public" {
Expand All @@ -120,8 +120,8 @@ resource "cloudflare_record" "prd_oldeworld_pxy_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.pxy-${count.index + 1}.oldeworld.prd.${var.network_subdomain}"
value = linode_instance.prd_oldeworld_pxy[count.index].ip_address
name = "pub.pxy-${count.index + 1}.oldeworld.prd.${var.network_subdomain}"
content = linode_instance.prd_oldeworld_pxy[count.index].ip_address
}

resource "cloudflare_record" "prd_oldeworld_pxy_dnsrecord__private" {
Expand All @@ -132,6 +132,6 @@ resource "cloudflare_record" "prd_oldeworld_pxy_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.pxy-${count.index + 1}.oldeworld.prd"
value = linode_instance.prd_oldeworld_pxy[count.index].private_ip_address
name = "prv.pxy-${count.index + 1}.oldeworld.prd"
content = linode_instance.prd_oldeworld_pxy[count.index].private_ip_address
}
2 changes: 1 addition & 1 deletion terraform/prd-cluster-oldeworld/next-02-pxy-origins.tf
Original file line number Diff line number Diff line change
Expand Up @@ -128,5 +128,5 @@ resource "cloudflare_record" "prd_oldeworld_nb_pxy_dnsrecord__public" {
ttl = 120

name = "oldeworld.prd.${var.network_subdomain}"
value = data.linode_nodebalancers.prd_oldeworld_pxy_1_nbs.nodebalancers[0].ipv4
content = data.linode_nodebalancers.prd_oldeworld_pxy_1_nbs.nodebalancers[0].ipv4
}
12 changes: 6 additions & 6 deletions terraform/prd-cluster-oldeworld/next-03-clt.tf
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,8 @@ resource "cloudflare_record" "prd_oldeworld_clt_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "clt-${each.value.instance}.oldeworld.prd"
value = trimsuffix(linode_instance_config.prd_oldeworld_clt_config[each.key].interface[1].ipam_address, "/24")
name = "clt-${each.value.instance}.oldeworld.prd"
content = trimsuffix(linode_instance_config.prd_oldeworld_clt_config[each.key].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "prd_oldeworld_clt_dnsrecord__public" {
Expand All @@ -120,8 +120,8 @@ resource "cloudflare_record" "prd_oldeworld_clt_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.clt-${each.value.instance}.oldeworld.prd.${var.network_subdomain}"
value = linode_instance.prd_oldeworld_clt[each.key].ip_address
name = "pub.clt-${each.value.instance}.oldeworld.prd.${var.network_subdomain}"
content = linode_instance.prd_oldeworld_clt[each.key].ip_address
}

resource "cloudflare_record" "prd_oldeworld_clt_dnsrecord__private" {
Expand All @@ -132,6 +132,6 @@ resource "cloudflare_record" "prd_oldeworld_clt_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.clt-${each.value.instance}.oldeworld.prd"
value = linode_instance.prd_oldeworld_clt[each.key].private_ip_address
name = "prv.clt-${each.value.instance}.oldeworld.prd"
content = linode_instance.prd_oldeworld_clt[each.key].private_ip_address
}
12 changes: 6 additions & 6 deletions terraform/prd-cluster-oldeworld/next-04-api.tf
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,8 @@ resource "cloudflare_record" "prd_oldeworld_api_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "api-${count.index + 1}.oldeworld.prd"
value = trimsuffix(linode_instance_config.prd_oldeworld_api_config[count.index].interface[1].ipam_address, "/24")
name = "api-${count.index + 1}.oldeworld.prd"
content = trimsuffix(linode_instance_config.prd_oldeworld_api_config[count.index].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "prd_oldeworld_api_dnsrecord__public" {
Expand All @@ -120,8 +120,8 @@ resource "cloudflare_record" "prd_oldeworld_api_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.api-${count.index + 1}.oldeworld.prd.${var.network_subdomain}"
value = linode_instance.prd_oldeworld_api[count.index].ip_address
name = "pub.api-${count.index + 1}.oldeworld.prd.${var.network_subdomain}"
content = linode_instance.prd_oldeworld_api[count.index].ip_address
}

resource "cloudflare_record" "prd_oldeworld_api_dnsrecord__private" {
Expand All @@ -132,6 +132,6 @@ resource "cloudflare_record" "prd_oldeworld_api_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.api-${count.index + 1}.oldeworld.prd"
value = linode_instance.prd_oldeworld_api[count.index].private_ip_address
name = "prv.api-${count.index + 1}.oldeworld.prd"
content = linode_instance.prd_oldeworld_api[count.index].private_ip_address
}
12 changes: 6 additions & 6 deletions terraform/prd-cluster-oldeworld/next-05-nws.tf
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@ resource "cloudflare_record" "prd_oldeworld_nws_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "nws-${each.value.name}.oldeworld.prd"
value = trimsuffix(linode_instance_config.prd_oldeworld_nws_config[each.key].interface[1].ipam_address, "/24")
name = "nws-${each.value.name}.oldeworld.prd"
content = trimsuffix(linode_instance_config.prd_oldeworld_nws_config[each.key].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "prd_oldeworld_nws_dnsrecord__public" {
Expand All @@ -132,8 +132,8 @@ resource "cloudflare_record" "prd_oldeworld_nws_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.nws-${each.value.name}.oldeworld.prd.${var.network_subdomain}"
value = linode_instance.prd_oldeworld_nws[each.key].ip_address
name = "pub.nws-${each.value.name}.oldeworld.prd.${var.network_subdomain}"
content = linode_instance.prd_oldeworld_nws[each.key].ip_address
}

resource "cloudflare_record" "prd_oldeworld_nws_dnsrecord__private" {
Expand All @@ -144,6 +144,6 @@ resource "cloudflare_record" "prd_oldeworld_nws_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.nws-${each.value.name}.oldeworld.prd"
value = linode_instance.prd_oldeworld_nws[each.key].private_ip_address
name = "prv.nws-${each.value.name}.oldeworld.prd"
content = linode_instance.prd_oldeworld_nws[each.key].private_ip_address
}
12 changes: 6 additions & 6 deletions terraform/prd-cluster-oldeworld/next-06-nws-jms.tf
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,8 @@ resource "cloudflare_record" "prd_oldeworld_jms_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "jms-${count.index + 1}.oldeworld.prd"
value = trimsuffix(linode_instance_config.prd_oldeworld_jms_config[count.index].interface[1].ipam_address, "/24")
name = "jms-${count.index + 1}.oldeworld.prd"
content = trimsuffix(linode_instance_config.prd_oldeworld_jms_config[count.index].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "prd_oldeworld_jms_dnsrecord__public" {
Expand All @@ -120,8 +120,8 @@ resource "cloudflare_record" "prd_oldeworld_jms_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.jms-${count.index + 1}.oldeworld.prd.${var.network_subdomain}"
value = linode_instance.prd_oldeworld_jms[count.index].ip_address
name = "pub.jms-${count.index + 1}.oldeworld.prd.${var.network_subdomain}"
content = linode_instance.prd_oldeworld_jms[count.index].ip_address
}

resource "cloudflare_record" "prd_oldeworld_jms_dnsrecord__private" {
Expand All @@ -132,6 +132,6 @@ resource "cloudflare_record" "prd_oldeworld_jms_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.jms-${count.index + 1}.oldeworld.prd"
value = linode_instance.prd_oldeworld_jms[count.index].private_ip_address
name = "prv.jms-${count.index + 1}.oldeworld.prd"
content = linode_instance.prd_oldeworld_jms[count.index].private_ip_address
}
12 changes: 6 additions & 6 deletions terraform/stg-cluster-oldeworld/next-01-pxy.tf
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,8 @@ resource "cloudflare_record" "stg_oldeworld_pxy_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "pxy-${count.index + 1}.oldeworld.stg"
value = trimsuffix(linode_instance_config.stg_oldeworld_pxy_config[count.index].interface[1].ipam_address, "/24")
name = "pxy-${count.index + 1}.oldeworld.stg"
content = trimsuffix(linode_instance_config.stg_oldeworld_pxy_config[count.index].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "stg_oldeworld_pxy_dnsrecord__public" {
Expand All @@ -120,8 +120,8 @@ resource "cloudflare_record" "stg_oldeworld_pxy_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.pxy-${count.index + 1}.oldeworld.stg.${var.network_subdomain}"
value = linode_instance.stg_oldeworld_pxy[count.index].ip_address
name = "pub.pxy-${count.index + 1}.oldeworld.stg.${var.network_subdomain}"
content = linode_instance.stg_oldeworld_pxy[count.index].ip_address
}

resource "cloudflare_record" "stg_oldeworld_pxy_dnsrecord__private" {
Expand All @@ -132,6 +132,6 @@ resource "cloudflare_record" "stg_oldeworld_pxy_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.pxy-${count.index + 1}.oldeworld.stg"
value = linode_instance.stg_oldeworld_pxy[count.index].private_ip_address
name = "prv.pxy-${count.index + 1}.oldeworld.stg"
content = linode_instance.stg_oldeworld_pxy[count.index].private_ip_address
}
4 changes: 2 additions & 2 deletions terraform/stg-cluster-oldeworld/next-02-pxy-origins.tf
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,6 @@ resource "cloudflare_record" "stg_oldeworld_nb_pxy_dnsrecord__public" {
proxied = false
ttl = 120

name = "oldeworld.stg.${var.network_subdomain}"
value = data.linode_nodebalancers.stg_oldeworld_pxy_nbs.nodebalancers[0].ipv4
name = "oldeworld.stg.${var.network_subdomain}"
content = data.linode_nodebalancers.stg_oldeworld_pxy_nbs.nodebalancers[0].ipv4
}
12 changes: 6 additions & 6 deletions terraform/stg-cluster-oldeworld/next-03-clt.tf
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,8 @@ resource "cloudflare_record" "stg_oldeworld_clt_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "clt-${each.value.instance}.oldeworld.stg"
value = trimsuffix(linode_instance_config.stg_oldeworld_clt_config[each.key].interface[1].ipam_address, "/24")
name = "clt-${each.value.instance}.oldeworld.stg"
content = trimsuffix(linode_instance_config.stg_oldeworld_clt_config[each.key].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "stg_oldeworld_clt_dnsrecord__public" {
Expand All @@ -120,8 +120,8 @@ resource "cloudflare_record" "stg_oldeworld_clt_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.clt-${each.value.instance}.oldeworld.stg.${var.network_subdomain}"
value = linode_instance.stg_oldeworld_clt[each.key].ip_address
name = "pub.clt-${each.value.instance}.oldeworld.stg.${var.network_subdomain}"
content = linode_instance.stg_oldeworld_clt[each.key].ip_address
}

resource "cloudflare_record" "stg_oldeworld_clt_dnsrecord__private" {
Expand All @@ -132,6 +132,6 @@ resource "cloudflare_record" "stg_oldeworld_clt_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.clt-${each.value.instance}.oldeworld.stg"
value = linode_instance.stg_oldeworld_clt[each.key].private_ip_address
name = "prv.clt-${each.value.instance}.oldeworld.stg"
content = linode_instance.stg_oldeworld_clt[each.key].private_ip_address
}
13 changes: 6 additions & 7 deletions terraform/stg-cluster-oldeworld/next-04-api.tf
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,8 @@ resource "cloudflare_record" "stg_oldeworld_api_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "api-${count.index + 1}.oldeworld.stg"
value = trimsuffix(linode_instance_config.stg_oldeworld_api_config[count.index].interface[1].ipam_address, "/24")

name = "api-${count.index + 1}.oldeworld.stg"
content = trimsuffix(linode_instance_config.stg_oldeworld_api_config[count.index].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "stg_oldeworld_api_dnsrecord__public" {
Expand All @@ -121,8 +120,8 @@ resource "cloudflare_record" "stg_oldeworld_api_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.api-${count.index + 1}.oldeworld.stg.${var.network_subdomain}"
value = linode_instance.stg_oldeworld_api[count.index].ip_address
name = "pub.api-${count.index + 1}.oldeworld.stg.${var.network_subdomain}"
content = linode_instance.stg_oldeworld_api[count.index].ip_address
}

resource "cloudflare_record" "stg_oldeworld_api_dnsrecord__private" {
Expand All @@ -133,6 +132,6 @@ resource "cloudflare_record" "stg_oldeworld_api_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.api-${count.index + 1}.oldeworld.stg"
value = linode_instance.stg_oldeworld_api[count.index].private_ip_address
name = "prv.api-${count.index + 1}.oldeworld.stg"
content = linode_instance.stg_oldeworld_api[count.index].private_ip_address
}
12 changes: 6 additions & 6 deletions terraform/stg-cluster-oldeworld/next-05-nws.tf
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@ resource "cloudflare_record" "stg_oldeworld_nws_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "nws-${each.value.name}.oldeworld.stg"
value = trimsuffix(linode_instance_config.stg_oldeworld_nws_config[each.key].interface[1].ipam_address, "/24")
name = "nws-${each.value.name}.oldeworld.stg"
content = trimsuffix(linode_instance_config.stg_oldeworld_nws_config[each.key].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "stg_oldeworld_nws_dnsrecord__public" {
Expand All @@ -132,8 +132,8 @@ resource "cloudflare_record" "stg_oldeworld_nws_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.nws-${each.value.name}.oldeworld.stg.${var.network_subdomain}"
value = linode_instance.stg_oldeworld_nws[each.key].ip_address
name = "pub.nws-${each.value.name}.oldeworld.stg.${var.network_subdomain}"
content = linode_instance.stg_oldeworld_nws[each.key].ip_address
}

resource "cloudflare_record" "stg_oldeworld_nws_dnsrecord__private" {
Expand All @@ -144,6 +144,6 @@ resource "cloudflare_record" "stg_oldeworld_nws_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.nws-${each.value.name}.oldeworld.stg"
value = linode_instance.stg_oldeworld_nws[each.key].private_ip_address
name = "prv.nws-${each.value.name}.oldeworld.stg"
content = linode_instance.stg_oldeworld_nws[each.key].private_ip_address
}
12 changes: 6 additions & 6 deletions terraform/stg-cluster-oldeworld/next-06-nws-jms.tf
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,8 @@ resource "cloudflare_record" "stg_oldeworld_jms_dnsrecord__vlan" {
proxied = false
ttl = 120

name = "jms-${count.index + 1}.oldeworld.stg"
value = trimsuffix(linode_instance_config.stg_oldeworld_jms_config[count.index].interface[1].ipam_address, "/24")
name = "jms-${count.index + 1}.oldeworld.stg"
content = trimsuffix(linode_instance_config.stg_oldeworld_jms_config[count.index].interface[1].ipam_address, "/24")
}

resource "cloudflare_record" "stg_oldeworld_jms_dnsrecord__public" {
Expand All @@ -120,8 +120,8 @@ resource "cloudflare_record" "stg_oldeworld_jms_dnsrecord__public" {
proxied = false
ttl = 120

name = "pub.jms-${count.index + 1}.oldeworld.stg.${var.network_subdomain}"
value = linode_instance.stg_oldeworld_jms[count.index].ip_address
name = "pub.jms-${count.index + 1}.oldeworld.stg.${var.network_subdomain}"
content = linode_instance.stg_oldeworld_jms[count.index].ip_address
}

resource "cloudflare_record" "stg_oldeworld_jms_dnsrecord__private" {
Expand All @@ -132,6 +132,6 @@ resource "cloudflare_record" "stg_oldeworld_jms_dnsrecord__private" {
proxied = false
ttl = 120

name = "prv.jms-${count.index + 1}.oldeworld.stg"
value = linode_instance.stg_oldeworld_jms[count.index].private_ip_address
name = "prv.jms-${count.index + 1}.oldeworld.stg"
content = linode_instance.stg_oldeworld_jms[count.index].private_ip_address
}

0 comments on commit d20a303

Please sign in to comment.