From de8b643eb1ff7c056f4e5e9c920387ed2d2d2a11 Mon Sep 17 00:00:00 2001 From: Stig Thormodsrud Date: Tue, 26 Oct 2010 16:58:08 -0700 Subject: Create vyatta-config-mgmt repo. --- .../system/config-mgmt/commit-revisions/node.def | 12 +++++++++++ .../system/config-mgmt/commit-uri/node.def | 24 ++++++++++++++++++++++ templates-cfg/system/config-mgmt/node.def | 1 + 3 files changed, 37 insertions(+) create mode 100644 templates-cfg/system/config-mgmt/commit-revisions/node.def create mode 100644 templates-cfg/system/config-mgmt/commit-uri/node.def create mode 100644 templates-cfg/system/config-mgmt/node.def (limited to 'templates-cfg/system') diff --git a/templates-cfg/system/config-mgmt/commit-revisions/node.def b/templates-cfg/system/config-mgmt/commit-revisions/node.def new file mode 100644 index 0000000..e5da66a --- /dev/null +++ b/templates-cfg/system/config-mgmt/commit-revisions/node.def @@ -0,0 +1,12 @@ +type: u32 +priority: 400 +help: Commit revisions + +update: sudo ${vyatta_sbindir}/vyatta-config-mgmt.pl \ + --action=update-revs \ + --revs="$VAR(@)" + +val_help: u32:0-65535 ; Number of config backups to keep + +syntax:expression: $VAR(@) >= 0 && $VAR(@) <= 65535 ; \ + "Commit revisions must be in range 0 to 65535" diff --git a/templates-cfg/system/config-mgmt/commit-uri/node.def b/templates-cfg/system/config-mgmt/commit-uri/node.def new file mode 100644 index 0000000..7b483f9 --- /dev/null +++ b/templates-cfg/system/config-mgmt/commit-uri/node.def @@ -0,0 +1,24 @@ +multi: +priority: 400 +type: txt +help: Commit URI + +syntax:expression: exec "/opt/vyatta/sbin/vyatta-config-mgmt.pl \ + --action=valid-uri \ + --uri=\"$VAR(@)\" "; "Invalid URI" + +create: if [ "$COMMIT_SIBLING_POSITION" = "LAST" ] || \ + [ "$COMMIT_SIBLING_POSITION" = "FIRSTLAST" ] ; then + sudo ${vyatta_sbindir}/vyatta-config-mgmt.pl --action=add-uri + fi; + +delete: if [ "$COMMIT_SIBLING_POSITION" = "LAST" ] || \ + [ "$COMMIT_SIBLING_POSITION" = "FIRSTLAST" ] ; then + sudo ${vyatta_sbindir}/vyatta-config-mgmt.pl --action=del-uri + fi; + +val_help: ; Uniform Resource Identifier +comp_help: + "scp://:@/" + "ftp://:@/" + "tftp:///" \ No newline at end of file diff --git a/templates-cfg/system/config-mgmt/node.def b/templates-cfg/system/config-mgmt/node.def new file mode 100644 index 0000000..e260c27 --- /dev/null +++ b/templates-cfg/system/config-mgmt/node.def @@ -0,0 +1 @@ +help: Configuration management settings -- cgit v1.2.3