feat: it works

This commit is contained in:
2025-12-29 16:29:02 -05:00
parent 2427411452
commit dd96e842de
5 changed files with 62 additions and 39 deletions

View File

@@ -12,7 +12,14 @@ resource "hcloud_network_subnet" "subnet" {
type = "cloud"
network_id = hcloud_network.net.id
network_zone = "eu-central"
ip_range = "10.0.0.0/16"
ip_range = "10.0.0.0/24"
}
resource "hcloud_network_route" "routes" {
for_each = var.routing
network_id = hcloud_network.net.id
destination = each.value.from
gateway = each.value.to
}
resource "hcloud_server" "boxes" {

View File

@@ -12,4 +12,11 @@ variable "boxes" {
type = map(object({
private_ip = string
}))
}
variable "routing" {
type = map(object({
from = string
to = string
}))
}