Compare commits

...

17 Commits

Author SHA1 Message Date
dc390ed095 Version bump 2023-07-02 23:05:41 -05:00
63a1d8c8b9 Version bump 2023-05-07 14:34:48 -05:00
5252eea43d Version bump 2023-04-22 15:43:37 -05:00
83d747e375 Version bump 2023-04-02 14:32:27 -05:00
586f696b11 Version bump 2023-03-09 21:25:13 -06:00
c89d4e79b2 Version bump 2023-02-12 13:32:59 -06:00
27502c868e Version bump 2023-02-12 13:32:14 -06:00
003bf523e6 Provider version bump 2022-12-06 19:52:35 -06:00
502a17f145 Version bumps 2022-07-03 12:37:46 -05:00
5746be68e4 Version bumps 2022-06-15 22:50:21 -05:00
21bacbe714 Make variables variable, add watched_enabled 2022-06-05 15:18:07 -05:00
883538a97a Again remove rdns so we can work before migration... 2022-06-01 21:58:31 -05:00
490b2279b4 Don't wait 2022-06-01 21:48:08 -05:00
ed8e4a55c4 Register hosts in Linode Managed DNS 2022-05-30 20:58:41 -05:00
3e74388f97 Default to Fedora 36 2022-05-30 20:23:23 -05:00
fb12a159a4 Version bumps 2022-05-30 19:50:10 -05:00
a2b268c889 Remove reverse dns until I have working forward dns configurations 2022-05-09 22:57:48 -05:00
13 changed files with 44 additions and 21 deletions

View File

@@ -0,0 +1,3 @@
data "linode_domain" "this" {
domain = var.domain_name
}

View File

@@ -1,4 +1,3 @@
output "instance" {
value = linode_instance.this
}

View File

@@ -0,0 +1,6 @@
resource "linode_domain_record" "this_ipv4" {
domain_id = data.linode_domain.this.id
name = var.host_name
record_type = "A"
target = linode_instance.this.ip_address
}

View File

@@ -0,0 +1,6 @@
resource "linode_domain_record" "this_ipv6" {
domain_id = data.linode_domain.this.id
name = var.host_name
record_type = "AAAA"
target = element(split("/", linode_instance.this.ipv6), 0)
}

View File

@@ -1,11 +1,12 @@
resource "linode_instance" "this" {
authorized_keys = var.authorized_keys
backups_enabled = true
booted = true
label = "${var.host_name}.${var.domain_name}"
image = var.image
private_ip = true
tags = var.tags
type = var.type
region = var.region
authorized_keys = var.authorized_keys
backups_enabled = var.backups_enabled
booted = var.booted
label = "${var.host_name}.${var.domain_name}"
image = var.image
private_ip = var.private_ip
tags = var.tags
type = var.type
region = var.region
watchdog_enabled = var.watchdog_enabled
}

View File

@@ -1,4 +0,0 @@
resource "linode_rdns" "this_ipv4" {
address = linode_instance.this.ip_address
rdns = "${var.host_name}.${var.domain_name}"
}

View File

@@ -1,4 +0,0 @@
resource "linode_rdns" "this_ipv6" {
address = element(split("/", linode_instance.this.ipv6), 0)
rdns = "${var.host_name}.${var.domain_name}"
}

View File

@@ -2,8 +2,8 @@ terraform {
required_providers {
linode = {
source = "linode/linode"
version = ">= 1.27.1"
version = ">= 2.5.1"
}
}
required_version = ">= 1.1.9"
required_version = ">= 1.5.2"
}

View File

@@ -0,0 +1,4 @@
variable "backups_enabled" {
default = true
type = bool
}

4
variable.booted.tf Normal file
View File

@@ -0,0 +1,4 @@
variable "booted" {
default = true
type = bool
}

View File

@@ -1,4 +1,4 @@
variable "image" {
default = "linode/fedora35"
default = "linode/fedora36"
type = string
}

4
variable.private_ip.tf Normal file
View File

@@ -0,0 +1,4 @@
variable "private_ip" {
default = true
type = bool
}

View File

@@ -0,0 +1,4 @@
variable "watchdog_enabled" {
default = true
type = bool
}