summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile3
-rw-r--r--data/templates/salt-minion/minion.tmpl4
-rw-r--r--interface-definitions/base/base.xml23
-rw-r--r--op-mode-definitions/ipv6-route.xml.in38
-rw-r--r--op-mode-definitions/show-ipv6-route.xml.in30
-rwxr-xr-xscripts/build-command-op-templates1
-rwxr-xr-xscripts/build-command-templates15
-rw-r--r--vyos-configtest0
8 files changed, 37 insertions, 77 deletions
diff --git a/Makefile b/Makefile
index 0fd23f713..00d7b5e21 100644
--- a/Makefile
+++ b/Makefile
@@ -33,9 +33,6 @@ op_xml_obj = $(op_xml_src:.xml.in=.xml)
interface_definitions: $(config_xml_obj)
mkdir -p $(TMPL_DIR)
- # Build "base" templates (service, interfaces, other high-level nodes)
- $(CURDIR)/scripts/build-command-templates $(CURDIR)/interface-definitions/base/base.xml $(CURDIR)/schema/interface_definition.rng $(TMPL_DIR)
-
find $(BUILD_DIR)/interface-definitions -type f -name "*.xml" | xargs -I {} $(CURDIR)/scripts/build-command-templates {} $(CURDIR)/schema/interface_definition.rng $(TMPL_DIR) || exit 1
# XXX: delete top level node.def's that now live in other packages
diff --git a/data/templates/salt-minion/minion.tmpl b/data/templates/salt-minion/minion.tmpl
index 405fb9131..99749b57a 100644
--- a/data/templates/salt-minion/minion.tmpl
+++ b/data/templates/salt-minion/minion.tmpl
@@ -21,7 +21,9 @@ hash_type: {{ hash }}
# location. Remote logging works best when configured to use rsyslogd(8) (e.g.:
# ``file:///dev/log``), with rsyslogd(8) configured for network logging. The URI
# format is: <file|udp|tcp>://<host|socketpath>:<port-if-required>/<log-facility>
-log_file: file:///dev/log
+# log_file: file:///dev/log
+#
+log_file: /var/log/salt/minion
# The level of messages to send to the console.
# One of 'garbage', 'trace', 'debug', info', 'warning', 'error', 'critical'.
diff --git a/interface-definitions/base/base.xml b/interface-definitions/base/base.xml
deleted file mode 100644
index 919478d45..000000000
--- a/interface-definitions/base/base.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0"?>
-<interfaceDefinition>
- <node name="interfaces">
- <properties>
- <help>Network interfaces</help>
- </properties>
- </node>
- <node name="high-availability">
- <properties>
- <help>High availability mechanisms</help>
- </properties>
- </node>
- <node name="nat">
- <properties>
- <help>Network address translation</help>
- </properties>
- </node>
- <node name="service">
- <properties>
- <help>Network and system services</help>
- </properties>
- </node>
-</interfaceDefinition>
diff --git a/op-mode-definitions/ipv6-route.xml.in b/op-mode-definitions/ipv6-route.xml.in
index fbf6489ba..28f5b1aad 100644
--- a/op-mode-definitions/ipv6-route.xml.in
+++ b/op-mode-definitions/ipv6-route.xml.in
@@ -24,44 +24,6 @@
<command>ip -f inet6 neigh list</command>
</leafNode>
- <node name="route">
- <properties>
- <help>Show IPv6 routes</help>
- </properties>
- <children>
- <node name="cache">
- <properties>
- <help>Show kernel IPv6 route cache</help>
- </properties>
- <command>ip -s -f inet6 route list cache</command>
- </node>
- <tagNode name="cache">
- <properties>
- <help>Show kernel IPv6 route cache for a given route</help>
- <completionHelp>
- <list>&lt;h:h:h:h:h:h:h:h&gt; &lt;h:h:h:h:h:h:h:h/x&gt;</list>
- </completionHelp>
- </properties>
- <command>ip -s -f inet6 route list cache $5</command>
- </tagNode>
- <node name="forward">
- <properties>
- <help>Show kernel IPv6 route table</help>
- </properties>
- <command>ip -f inet6 route list</command>
- </node>
- <tagNode name="forward">
- <properties>
- <help>Show kernel IPv6 route table for a given route</help>
- <completionHelp>
- <list>&lt;h:h:h:h:h:h:h:h&gt; &lt;h:h:h:h:h:h:h:h/x&gt;</list>
- </completionHelp>
- </properties>
- <command>ip -s -f inet6 route list $5</command>
- </tagNode>
- </children>
- </node>
-
</children>
</node>
</children>
diff --git a/op-mode-definitions/show-ipv6-route.xml.in b/op-mode-definitions/show-ipv6-route.xml.in
index 9ac8687ab..065ea6f1f 100644
--- a/op-mode-definitions/show-ipv6-route.xml.in
+++ b/op-mode-definitions/show-ipv6-route.xml.in
@@ -19,12 +19,42 @@
</properties>
<command>vtysh -c "show ipv6 route bgp"</command>
</node>
+ <node name="cache">
+ <properties>
+ <help>Show kernel IPv6 route cache</help>
+ </properties>
+ <command>ip -s -f inet6 route list cache</command>
+ </node>
+ <tagNode name="cache">
+ <properties>
+ <help>Show kernel IPv6 route cache for a given route</help>
+ <completionHelp>
+ <list>&lt;h:h:h:h:h:h:h:h&gt; &lt;h:h:h:h:h:h:h:h/x&gt;</list>
+ </completionHelp>
+ </properties>
+ <command>ip -s -f inet6 route list cache $5</command>
+ </tagNode>
<node name="connected">
<properties>
<help>Show IPv6 connected routes</help>
</properties>
<command>vtysh -c "show ipv6 route connected"</command>
</node>
+ <node name="forward">
+ <properties>
+ <help>Show kernel IPv6 route table</help>
+ </properties>
+ <command>ip -f inet6 route list</command>
+ </node>
+ <tagNode name="forward">
+ <properties>
+ <help>Show kernel IPv6 route table for a given route</help>
+ <completionHelp>
+ <list>&lt;h:h:h:h:h:h:h:h&gt; &lt;h:h:h:h:h:h:h:h/x&gt;</list>
+ </completionHelp>
+ </properties>
+ <command>ip -s -f inet6 route list $5</command>
+ </tagNode>
<node name="isis">
<properties>
<help>Show IPv6 IS-IS routes</help>
diff --git a/scripts/build-command-op-templates b/scripts/build-command-op-templates
index 54cc07794..c60b32a1e 100755
--- a/scripts/build-command-op-templates
+++ b/scripts/build-command-op-templates
@@ -193,7 +193,6 @@ def process_node(n, tmpl_dir):
f.write('help: {0}\n'.format(props['help']))
else:
# Something has already generated this file
- print("Warning: refusing to overwrite already existing file {}".format(nodedef_path))
pass
# Create the inner node.tag part
diff --git a/scripts/build-command-templates b/scripts/build-command-templates
index f09941e68..d6585b0cc 100755
--- a/scripts/build-command-templates
+++ b/scripts/build-command-templates
@@ -3,7 +3,7 @@
# build-command-template: converts new style command definitions in XML
# to the old style (bunch of dirs and node.def's) command templates
#
-# Copyright (C) 2017,2021 VyOS maintainers <maintainers@vyos.net>
+# Copyright (C) 2017 VyOS maintainers <maintainers@vyos.net>
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
@@ -279,26 +279,19 @@ def process_node(n, tmpl_dir):
f.write(make_node_def(props))
else:
# Something has already generated that file
- print("Warning: refusing to overwrite already existing file {}".format(nodedef_path))
pass
- if (node_type == "node") and (children is None):
- print("Warning: non-leaf, non-tag <node> without children may be incomplete ({})".format(nodedef_path))
- pass
- elif node_type == "node":
+ if node_type == "node":
inner_nodes = children.iterfind("*")
for inner_n in inner_nodes:
process_node(inner_n, my_tmpl_dir)
- elif node_type == "tagNode":
- if children is None:
- raise ValueError("A <tagNode> without children is not allowed")
-
- inner_nodes = children.iterfind("*")
+ if node_type == "tagNode":
my_tmpl_dir.append("node.tag")
if debug:
print("Created path for the tagNode:", end="")
os.makedirs(make_path(my_tmpl_dir), exist_ok=True)
+ inner_nodes = children.iterfind("*")
for inner_n in inner_nodes:
process_node(inner_n, my_tmpl_dir)
else:
diff --git a/vyos-configtest b/vyos-configtest
deleted file mode 100644
index e69de29bb..000000000
--- a/vyos-configtest
+++ /dev/null