Commits (1)
......@@ -43,6 +43,13 @@ resource "hcloud_server" "generic-hcloud" {
}
}
resource "hcloud_server_network" "network" {
count = network_enabled ? 1 : 0
server_id = hcloud_server.generic-hcloud.id
network_id = var.network_id
ip = var.network_ip
}
resource "hcloud_rdns" "ipv4" {
server_id = "${hcloud_server.generic-hcloud.id}"
ip_address = "${hcloud_server.generic-hcloud.ipv4_address}"
......
......@@ -31,3 +31,15 @@ variable "wireguard_address" {
variable "dns_zone" {
default = "darkdna"
}
variable "network_id" {
}
variable "network_ip" {
}
variable "network_enabled" {
default = false
}
\ No newline at end of file