summaryrefslogtreecommitdiff
path: root/interface-definitions
diff options
context:
space:
mode:
Diffstat (limited to 'interface-definitions')
-rw-r--r--interface-definitions/bcast-relay.xml.in10
-rw-r--r--interface-definitions/dhcp-relay.xml.in10
-rw-r--r--interface-definitions/dhcp-server.xml.in4
-rw-r--r--interface-definitions/flow-accounting-conf.xml.in10
-rw-r--r--interface-definitions/include/generic-interface-broadcast.xml.i17
-rw-r--r--interface-definitions/include/generic-interface-multi-broadcast.xml.i18
-rw-r--r--interface-definitions/include/generic-interface-multi.xml.i18
-rw-r--r--interface-definitions/include/generic-interface.xml.i17
-rw-r--r--interface-definitions/interfaces-bonding.xml.in14
-rw-r--r--interface-definitions/policy.xml.in9
-rw-r--r--interface-definitions/protocols-bfd.xml.in9
-rw-r--r--interface-definitions/protocols-mpls.xml.in20
-rw-r--r--interface-definitions/protocols-ospfv3.xml.in17
-rw-r--r--interface-definitions/service_mdns-repeater.xml.in10
-rw-r--r--interface-definitions/vpn_ipsec.xml.in19
-rw-r--r--interface-definitions/vrrp.xml.in9
16 files changed, 98 insertions, 113 deletions
diff --git a/interface-definitions/bcast-relay.xml.in b/interface-definitions/bcast-relay.xml.in
index 3f781f07f..aeaa5ab37 100644
--- a/interface-definitions/bcast-relay.xml.in
+++ b/interface-definitions/bcast-relay.xml.in
@@ -39,15 +39,7 @@
<help>Description</help>
</properties>
</leafNode>
- <leafNode name="interface">
- <properties>
- <help>Interface to repeat UDP broadcasts to [REQUIRED]</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- <multi/>
- </properties>
- </leafNode>
+ #include <include/generic-interface-multi.xml.i>
#include <include/port-number.xml.i>
</children>
</tagNode>
diff --git a/interface-definitions/dhcp-relay.xml.in b/interface-definitions/dhcp-relay.xml.in
index 0d485ef80..483e776a7 100644
--- a/interface-definitions/dhcp-relay.xml.in
+++ b/interface-definitions/dhcp-relay.xml.in
@@ -9,15 +9,7 @@
<priority>910</priority>
</properties>
<children>
- <leafNode name="interface">
- <properties>
- <help>DHCP relay interface [REQUIRED]</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py -b</script>
- </completionHelp>
- <multi/>
- </properties>
- </leafNode>
+ #include <include/generic-interface-multi-broadcast.xml.i>
<node name="relay-options">
<properties>
<help>Relay options</help>
diff --git a/interface-definitions/dhcp-server.xml.in b/interface-definitions/dhcp-server.xml.in
index 47bdc4db1..45a629181 100644
--- a/interface-definitions/dhcp-server.xml.in
+++ b/interface-definitions/dhcp-server.xml.in
@@ -289,9 +289,9 @@
<properties>
<help>Name of static mapping</help>
<constraint>
- <regex>[-_a-zA-Z0-9.]+</regex>
+ <regex>^[-_a-zA-Z0-9]+$</regex>
</constraint>
- <constraintErrorMessage>Invalid static mapping name. May only contain letters, numbers and .-_</constraintErrorMessage>
+ <constraintErrorMessage>Invalid static mapping name. May only contain letters, numbers and a hyphen (-)!</constraintErrorMessage>
</properties>
<children>
#include <include/generic-disable-node.xml.i>
diff --git a/interface-definitions/flow-accounting-conf.xml.in b/interface-definitions/flow-accounting-conf.xml.in
index b0f308afd..113c1d849 100644
--- a/interface-definitions/flow-accounting-conf.xml.in
+++ b/interface-definitions/flow-accounting-conf.xml.in
@@ -136,15 +136,7 @@
</constraint>
</properties>
</leafNode>
- <leafNode name="interface">
- <properties>
- <help>Interface for flow-accounting [REQUIRED]</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- <multi/>
- </properties>
- </leafNode>
+ #include <include/generic-interface-multi.xml.i>
<node name="netflow">
<properties>
<help>NetFlow settings</help>
diff --git a/interface-definitions/include/generic-interface-broadcast.xml.i b/interface-definitions/include/generic-interface-broadcast.xml.i
new file mode 100644
index 000000000..6f76dde1a
--- /dev/null
+++ b/interface-definitions/include/generic-interface-broadcast.xml.i
@@ -0,0 +1,17 @@
+<!-- include start from generic-interface-broadcast.xml.i -->
+<leafNode name="interface">
+ <properties>
+ <help>Interface Name to use</help>
+ <completionHelp>
+ <script>${vyos_completion_dir}/list_interfaces.py --broadcast</script>
+ </completionHelp>
+ <valueHelp>
+ <format>txt</format>
+ <description>Interface name</description>
+ </valueHelp>
+ <constraint>
+ <validator name="interface-name"/>
+ </constraint>
+ </properties>
+</leafNode>
+<!-- include end -->
diff --git a/interface-definitions/include/generic-interface-multi-broadcast.xml.i b/interface-definitions/include/generic-interface-multi-broadcast.xml.i
new file mode 100644
index 000000000..00638f3b7
--- /dev/null
+++ b/interface-definitions/include/generic-interface-multi-broadcast.xml.i
@@ -0,0 +1,18 @@
+<!-- include start from generic-interface-multi-broadcast.xml.i -->
+<leafNode name="interface">
+ <properties>
+ <help>Interface Name to use</help>
+ <completionHelp>
+ <script>${vyos_completion_dir}/list_interfaces.py --broadcast</script>
+ </completionHelp>
+ <valueHelp>
+ <format>txt</format>
+ <description>Interface name</description>
+ </valueHelp>
+ <constraint>
+ <validator name="interface-name"/>
+ </constraint>
+ <multi/>
+ </properties>
+</leafNode>
+<!-- include end -->
diff --git a/interface-definitions/include/generic-interface-multi.xml.i b/interface-definitions/include/generic-interface-multi.xml.i
new file mode 100644
index 000000000..44e87775c
--- /dev/null
+++ b/interface-definitions/include/generic-interface-multi.xml.i
@@ -0,0 +1,18 @@
+<!-- include start from generic-interface-multi.xml.i -->
+<leafNode name="interface">
+ <properties>
+ <help>Interface Name to use</help>
+ <completionHelp>
+ <script>${vyos_completion_dir}/list_interfaces.py</script>
+ </completionHelp>
+ <valueHelp>
+ <format>txt</format>
+ <description>Interface name</description>
+ </valueHelp>
+ <constraint>
+ <validator name="interface-name"/>
+ </constraint>
+ <multi/>
+ </properties>
+</leafNode>
+<!-- include end -->
diff --git a/interface-definitions/include/generic-interface.xml.i b/interface-definitions/include/generic-interface.xml.i
new file mode 100644
index 000000000..50af718a5
--- /dev/null
+++ b/interface-definitions/include/generic-interface.xml.i
@@ -0,0 +1,17 @@
+<!-- include start from generic-interface.xml.i -->
+<leafNode name="interface">
+ <properties>
+ <help>Interface Name to use</help>
+ <completionHelp>
+ <script>${vyos_completion_dir}/list_interfaces.py</script>
+ </completionHelp>
+ <valueHelp>
+ <format>txt</format>
+ <description>Interface name</description>
+ </valueHelp>
+ <constraint>
+ <validator name="interface-name"/>
+ </constraint>
+ </properties>
+</leafNode>
+<!-- include end -->
diff --git a/interface-definitions/interfaces-bonding.xml.in b/interface-definitions/interfaces-bonding.xml.in
index 05e0d8461..17879cf1e 100644
--- a/interface-definitions/interfaces-bonding.xml.in
+++ b/interface-definitions/interfaces-bonding.xml.in
@@ -177,6 +177,13 @@
<completionHelp>
<script>${vyos_completion_dir}/list_interfaces.py --bondable</script>
</completionHelp>
+ <valueHelp>
+ <format>txt</format>
+ <description>Interface name</description>
+ </valueHelp>
+ <constraint>
+ <validator name="interface-name"/>
+ </constraint>
<multi/>
</properties>
</leafNode>
@@ -189,6 +196,13 @@
<completionHelp>
<script>${vyos_completion_dir}/list_interfaces.py --bondable</script>
</completionHelp>
+ <valueHelp>
+ <format>txt</format>
+ <description>Interface name</description>
+ </valueHelp>
+ <constraint>
+ <validator name="interface-name"/>
+ </constraint>
</properties>
</leafNode>
#include <include/interface/vif-s.xml.i>
diff --git a/interface-definitions/policy.xml.in b/interface-definitions/policy.xml.in
index cf65daf00..225f9a6f9 100644
--- a/interface-definitions/policy.xml.in
+++ b/interface-definitions/policy.xml.in
@@ -597,14 +597,7 @@
</completionHelp>
</properties>
</leafNode>
- <leafNode name="interface">
- <properties>
- <help>First hop interface of a route to match</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- </properties>
- </leafNode>
+ #include <include/generic-interface.xml.i>
<node name="ip">
<properties>
<help>IP prefix parameters to match</help>
diff --git a/interface-definitions/protocols-bfd.xml.in b/interface-definitions/protocols-bfd.xml.in
index cc3c3bf12..7b22b8125 100644
--- a/interface-definitions/protocols-bfd.xml.in
+++ b/interface-definitions/protocols-bfd.xml.in
@@ -43,14 +43,7 @@
<help>Bind listener to specified interface/address, mandatory for IPv6</help>
</properties>
<children>
- <leafNode name="interface">
- <properties>
- <help>Local interface to bind our peer listener to</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- </properties>
- </leafNode>
+ #include <include/generic-interface.xml.i>
<leafNode name="address">
<properties>
<help>Local address to bind our peer listener to</help>
diff --git a/interface-definitions/protocols-mpls.xml.in b/interface-definitions/protocols-mpls.xml.in
index e7646e625..be8e30c18 100644
--- a/interface-definitions/protocols-mpls.xml.in
+++ b/interface-definitions/protocols-mpls.xml.in
@@ -524,15 +524,7 @@
</node>
</children>
</node>
- <leafNode name="interface">
- <properties>
- <help>Enable LDP and neighbor discovery on interface</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- <multi/>
- </properties>
- </leafNode>
+ #include <include/generic-interface-multi.xml.i>
</children>
</node>
<node name="parameters">
@@ -560,15 +552,7 @@
</leafNode>
</children>
</node>
- <leafNode name="interface">
- <properties>
- <help>Enable MPLS packet processing on interface</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- <multi/>
- </properties>
- </leafNode>
+ #include <include/generic-interface-multi.xml.i>
</children>
</node>
</children>
diff --git a/interface-definitions/protocols-ospfv3.xml.in b/interface-definitions/protocols-ospfv3.xml.in
index 99cfec661..fffeeb9a5 100644
--- a/interface-definitions/protocols-ospfv3.xml.in
+++ b/interface-definitions/protocols-ospfv3.xml.in
@@ -61,22 +61,7 @@
</completionHelp>
</properties>
</leafNode>
- <leafNode name="interface">
- <properties>
- <help>Enable routing on an IPv6 interface</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- <valueHelp>
- <format>txt</format>
- <description>Interface used for routing information exchange</description>
- </valueHelp>
- <constraint>
- <validator name="interface-name"/>
- </constraint>
- <multi/>
- </properties>
- </leafNode>
+ #include <include/generic-interface-multi.xml.i>
<tagNode name="range">
<properties>
<help>Specify IPv6 prefix (border routers only)</help>
diff --git a/interface-definitions/service_mdns-repeater.xml.in b/interface-definitions/service_mdns-repeater.xml.in
index d02dac8a6..9a94f1488 100644
--- a/interface-definitions/service_mdns-repeater.xml.in
+++ b/interface-definitions/service_mdns-repeater.xml.in
@@ -14,15 +14,7 @@
</properties>
<children>
#include <include/generic-disable-node.xml.i>
- <leafNode name="interface">
- <properties>
- <help>Interface to repeat mDNS advertisements [REQUIRED]</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- <multi/>
- </properties>
- </leafNode>
+ #include <include/generic-interface-multi.xml.i>
<leafNode name="vrrp-disable">
<properties>
<help>Disables mDNS repeater on VRRP interfaces not in MASTER state</help>
diff --git a/interface-definitions/vpn_ipsec.xml.in b/interface-definitions/vpn_ipsec.xml.in
index 164ba6618..cfa456e42 100644
--- a/interface-definitions/vpn_ipsec.xml.in
+++ b/interface-definitions/vpn_ipsec.xml.in
@@ -498,15 +498,7 @@
<help>Sets to include an additional secrets file for strongSwan. Use an absolute path to specify the included file.</help>
</properties>
</leafNode>
- <leafNode name="interface">
- <properties>
- <help>Onterface used for IPsec communication</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- <multi/>
- </properties>
- </leafNode>
+ #include <include/generic-interface-multi.xml.i>
<node name="log">
<properties>
<help>IPsec logging</help>
@@ -822,14 +814,7 @@
<help>DHCP pool options for remote-access</help>
</properties>
<children>
- <leafNode name="interface">
- <properties>
- <help>Interface with DHCP server to use</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py</script>
- </completionHelp>
- </properties>
- </leafNode>
+ #include <include/generic-interface.xml.i>
<leafNode name="server">
<properties>
<help>DHCP server address</help>
diff --git a/interface-definitions/vrrp.xml.in b/interface-definitions/vrrp.xml.in
index 44a9a1f54..53d79caac 100644
--- a/interface-definitions/vrrp.xml.in
+++ b/interface-definitions/vrrp.xml.in
@@ -16,14 +16,7 @@
<help>VRRP group</help>
</properties>
<children>
- <leafNode name="interface">
- <properties>
- <help>Network interface</help>
- <completionHelp>
- <script>${vyos_completion_dir}/list_interfaces.py --broadcast</script>
- </completionHelp>
- </properties>
- </leafNode>
+ #include <include/generic-interface-broadcast.xml.i>
<leafNode name="advertise-interval">
<properties>
<help>Advertise interval</help>