Allow any number of DNS nameservers #19

Merged
Dreaded_X merged 2 commits from feature/dns into main 2026-04-17 19:43:08 +00:00
3 changed files with 6 additions and 7 deletions
+2 -3
View File
@@ -140,12 +140,11 @@
"array", "array",
"null" "null"
], ],
"default": null,
"items": { "items": {
"type": "string", "type": "string",
"format": "ipv4" "format": "ipv4"
}, }
"maxItems": 2,
"minItems": 2
}, },
"gateway": { "gateway": {
"type": [ "type": [
+2 -3
View File
@@ -136,12 +136,11 @@
"array", "array",
"null" "null"
], ],
"default": null,
"items": { "items": {
"type": "string", "type": "string",
"format": "ipv4" "format": "ipv4"
}, }
"maxItems": 2,
"minItems": 2
}, },
"gateway": { "gateway": {
"type": [ "type": [
+2 -1
View File
@@ -53,7 +53,8 @@ struct Network {
ip: Ipv4Addr, ip: Ipv4Addr,
netmask: Ipv4Addr, netmask: Ipv4Addr,
gateway: Ipv4Addr, gateway: Ipv4Addr,
dns: [Ipv4Addr; 2], #[serde(default)]
dns: Option<Vec<Ipv4Addr>>,
#[optional_rename(OptionalTailscale)] #[optional_rename(OptionalTailscale)]
#[optional_wrap] #[optional_wrap]
tailscale: Tailscale, tailscale: Tailscale,