diff options
| author | John Estabrook <jestabro@vyos.io> | 2026-10-09 08:02:37 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-10-09 08:02:37 -0500 |
| commit | 998fe8286fea7c2a0492fcf77ee87ae41597f0e8 (patch) | |
| tree | db79d21e0b6f89e115077cd1581837678f08f1a9 /interface-definitions | |
| parent | 4b022646b7657416b3429202784ffb280eac9c80 (diff) | |
| parent | 575f265daf973428ed1b910f91fb124615fbebd4 (diff) | |
| download | vyos-1x-998fe8286fea7c2a0492fcf77ee87ae41597f0e8.tar.gz vyos-1x-998fe8286fea7c2a0492fcf77ee87ae41597f0e8.zip | |
Merge pull request #5502 from natali-rs1985/T6304
config-management: T6304: Rewrite commit-archive location into a structured CLI
Diffstat (limited to 'interface-definitions')
4 files changed, 152 insertions, 34 deletions
diff --git a/interface-definitions/include/config-management/remote-auth.xml.i b/interface-definitions/include/config-management/remote-auth.xml.i new file mode 100644 index 000000000..c7b4bd81c --- /dev/null +++ b/interface-definitions/include/config-management/remote-auth.xml.i @@ -0,0 +1,12 @@ +<!-- include start from config-management/remote-auth.xml.i --> +<node name="authentication"> + <properties> + <help>Authentication settings for remote server</help> + </properties> + <children> + #include <include/generic-username.xml.i> + #include <include/generic-password.xml.i> + </children> +</node> +#include <include/config-management/remote.xml.i> +<!-- include end --> diff --git a/interface-definitions/include/config-management/remote.xml.i b/interface-definitions/include/config-management/remote.xml.i new file mode 100644 index 000000000..9f85ec9e1 --- /dev/null +++ b/interface-definitions/include/config-management/remote.xml.i @@ -0,0 +1,34 @@ +<!-- include start from config-management/remote.xml.i --> +<leafNode name="server"> + <properties> + <help>Remote server to connect to</help> + <valueHelp> + <format>ipv4</format> + <description>Server IPv4 address</description> + </valueHelp> + <valueHelp> + <format>ipv6</format> + <description>Server IPv6 address</description> + </valueHelp> + <valueHelp> + <format>hostname</format> + <description>Server hostname/FQDN</description> + </valueHelp> + <constraint> + <validator name="ip-address"/> + <validator name="fqdn"/> + </constraint> + <constraintErrorMessage>Server must be an IPv4/IPv6 address or a hostname</constraintErrorMessage> + </properties> +</leafNode> +#include <include/port-number.xml.i> +<leafNode name="path"> + <properties> + <help>Remote path used to store the archived configuration</help> + <valueHelp> + <format>txt</format> + <description>Remote path</description> + </valueHelp> + </properties> +</leafNode> +<!-- include end --> diff --git a/interface-definitions/include/version/config-management-version.xml.i b/interface-definitions/include/version/config-management-version.xml.i index 695ba09ab..d5664790c 100644 --- a/interface-definitions/include/version/config-management-version.xml.i +++ b/interface-definitions/include/version/config-management-version.xml.i @@ -1,3 +1,3 @@ <!-- include start from include/version/config-management-version.xml.i --> -<syntaxVersion component='config-management' version='1'></syntaxVersion> +<syntaxVersion component='config-management' version='2'></syntaxVersion> <!-- include end --> diff --git a/interface-definitions/system_config-management.xml.in b/interface-definitions/system_config-management.xml.in index 319611266..bbbcd9c6a 100644 --- a/interface-definitions/system_config-management.xml.in +++ b/interface-definitions/system_config-management.xml.in @@ -13,44 +13,116 @@ <help>Commit archive settings</help> </properties> <children> - <leafNode name="location"> + <tagNode name="location"> <properties> <help>Commit archive location</help> <valueHelp> - <format>http://<user>:<passwd>@<host>/<path></format> - <description/> + <format>txt</format> + <description>Name of the commit archive location</description> </valueHelp> - <valueHelp> - <format>https://<user>:<passwd>@<host>/<path></format> - <description/> - </valueHelp> - <valueHelp> - <format>ftp://<user>:<passwd>@<host>/<path></format> - <description/> - </valueHelp> - <valueHelp> - <format>sftp://<user>:<passwd>@<host>/<path></format> - <description/> - </valueHelp> - <valueHelp> - <format>scp://<user>:<passwd>@<host>/<path></format> - <description/> - </valueHelp> - <valueHelp> - <format>tftp://<host>/<path></format> - <description/> - </valueHelp> - <valueHelp> - <format>git+https://<user>:<passwd>@<host>/<path></format> - <description/> - </valueHelp> - <constraint> - <validator name="url --file-transport"/> - <regex>(ssh|git|git\+(\w+)):\/\/.*</regex> - </constraint> - <multi/> </properties> - </leafNode> + <children> + <node name="scp"> + <properties> + <help>Archive configuration using SCP</help> + </properties> + <children> + #include <include/config-management/remote-auth.xml.i> + </children> + </node> + <node name="sftp"> + <properties> + <help>Archive configuration using SFTP</help> + </properties> + <children> + #include <include/config-management/remote-auth.xml.i> + </children> + </node> + <node name="ssh"> + <properties> + <help>Archive configuration using SSH</help> + </properties> + <children> + #include <include/config-management/remote-auth.xml.i> + </children> + </node> + <node name="ftp"> + <properties> + <help>Archive configuration using FTP</help> + </properties> + <children> + #include <include/config-management/remote-auth.xml.i> + </children> + </node> + <node name="ftps"> + <properties> + <help>Archive configuration using FTP over TLS</help> + </properties> + <children> + #include <include/config-management/remote-auth.xml.i> + </children> + </node> + <node name="http"> + <properties> + <help>Archive configuration using HTTP</help> + </properties> + <children> + #include <include/config-management/remote-auth.xml.i> + </children> + </node> + <node name="https"> + <properties> + <help>Archive configuration using HTTPS</help> + </properties> + <children> + #include <include/config-management/remote-auth.xml.i> + </children> + </node> + <node name="git"> + <properties> + <help>Archive configuration using git</help> + </properties> + <children> + <leafNode name="transport"> + <properties> + <help>Transport used to reach the git remote</help> + <completionHelp> + <list>https http ssh file</list> + </completionHelp> + <valueHelp> + <format>https</format> + <description>Push over HTTPS</description> + </valueHelp> + <valueHelp> + <format>http</format> + <description>Push over plain HTTP</description> + </valueHelp> + <valueHelp> + <format>ssh</format> + <description>Push over SSH</description> + </valueHelp> + <valueHelp> + <format>file</format> + <description>Push to a local repository (set path, no server)</description> + </valueHelp> + <constraint> + <regex>(https|http|ssh|file)</regex> + </constraint> + </properties> + </leafNode> + #include <include/config-management/remote-auth.xml.i> + </children> + </node> + <node name="tftp"> + <properties> + <help>Archive configuration using TFTP</help> + </properties> + <children> + #include <include/config-management/remote.xml.i> + </children> + </node> + </children> + </tagNode> #include <include/source-address-ipv4-ipv6.xml.i> #include <include/interface/vrf.xml.i> </children> |
