You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- vlan_id is now list(number); each entry creates a harvester_network
via for_each so networks can be added/removed independently
- Auto-route path (no vyos_endpoint) supports multiple VLANs; VyOS
path still requires exactly one VLAN (precondition enforced)
- network_namespace_name override lets callers import brownfield
namespaces whose names differ from the <project>-net default
- vlan_network_names map override lets callers import brownfield
harvester_network resources with non-default names
- network_name output replaced by network_names map keyed by VLAN ID
Closes#67
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
error_message="Quota variables (memory_limit, storage_limit, namespace_*_limit) are only applied when cpu_limit is set. Either set cpu_limit or remove the other quota variables."
description="Map of VLAN ID (string) → full harvester_network reference (<namespace>/<name>) for attaching tenant VMs. Empty map when vlan_id is null or empty."
description="VLAN ID for this tenant's network (>= 1000). When set, always creates the network namespace and a harvester_network. Routing mode depends on vyos_endpoint: if set, route_mode=manual with a deterministic /23 from 10.0.0.0/8 plus full VyOS vif/DHCP/NAT config; if null, route_mode=auto (upstream router / DigiOps-issued VLAN handles routing). When vlan_id is null, no network resources are created."
113
+
type=list(number)
114
+
description="List of VLAN IDs for this tenant's networks. Each entry creates a harvester_network in the network namespace. When non-empty, the network namespace is always created. VyOS path (vyos_endpoint set) requires exactly one VLAN ID — a deterministic /23 from 10.0.0.0/8 is computed and full VyOS vif/DHCP/NAT config is provisioned. Auto-route path (vyos_endpoint null) supports multiple VLANs — the upstream router handles routing. When null or empty, no network resources are created."
error_message="vlan_id must be a valid 802.1Q VLAN ID (1–4094)."
117
+
condition=var.vlan_id==null|| (
118
+
length(var.vlan_id) >0&&
119
+
alltrue([foridinvar.vlan_id:id>=1&&id<=4094])
120
+
)
121
+
error_message="vlan_id must be null or a non-empty list of valid 802.1Q VLAN IDs (1–4094)."
119
122
}
120
123
}
121
124
125
+
variable"network_namespace_name" {
126
+
type=string
127
+
description="Override the name of the network namespace. Defaults to <project_name>-net. Use this when importing a brownfield namespace whose name differs from the default."
128
+
default=null
129
+
}
130
+
131
+
variable"vlan_network_names" {
132
+
type=map(string)
133
+
description="Map of VLAN ID (as string) to harvester_network resource name override. Use when importing brownfield networks whose names differ from the default <project_name>-vlan<id> pattern. Example: { \"608\" = \"vm-subnet-008\" }."
134
+
default={}
135
+
}
136
+
122
137
variable"cluster_network_name" {
123
138
type=string
124
139
description="Harvester cluster network carrying tenant VLANs. Defaults to 'vm-network' — override only if your datacenter uses a different cluster network name."
0 commit comments