summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorViacheslav Hletenko <v.gletenko@vyos.io>2022-10-13 09:29:51 +0000
committerViacheslav Hletenko <v.gletenko@vyos.io>2022-10-13 10:14:05 +0000
commitb52a1255360107672b7bcec769b3bc8fbf60eb81 (patch)
tree238e996ee5f404b99d3408d7c228788d40c0809e
parent74c39157c732605dea6fbe09fd5fc9d3b9229d7e (diff)
downloadvyos-1x-b52a1255360107672b7bcec769b3bc8fbf60eb81.tar.gz
vyos-1x-b52a1255360107672b7bcec769b3bc8fbf60eb81.zip
monitoring: T4312: Ability to set IP address in the URL
Use common "url.xml" which allow URL as domain name or IP entrie
-rw-r--r--interface-definitions/include/monitoring/url.xml.i15
-rw-r--r--interface-definitions/service-monitoring-telegraf.xml.in6
2 files changed, 3 insertions, 18 deletions
diff --git a/interface-definitions/include/monitoring/url.xml.i b/interface-definitions/include/monitoring/url.xml.i
deleted file mode 100644
index fd61c38ea..000000000
--- a/interface-definitions/include/monitoring/url.xml.i
+++ /dev/null
@@ -1,15 +0,0 @@
-<!-- include start from monitoring/url.xml.i -->
-<leafNode name="url">
- <properties>
- <help>Remote URL</help>
- <valueHelp>
- <format>url</format>
- <description>Remote URL</description>
- </valueHelp>
- <constraint>
- <regex>(http:\/\/www\.|https:\/\/www\.|http:\/\/|https:\/\/)?[a-z0-9]+([\-\.]{1}[a-z0-9]+)*\.[a-z]{2,5}?(\/.*)?</regex>
- </constraint>
- <constraintErrorMessage>Incorrect URL format</constraintErrorMessage>
- </properties>
-</leafNode>
-<!-- include end -->
diff --git a/interface-definitions/service-monitoring-telegraf.xml.in b/interface-definitions/service-monitoring-telegraf.xml.in
index 47f943d83..f50e5e334 100644
--- a/interface-definitions/service-monitoring-telegraf.xml.in
+++ b/interface-definitions/service-monitoring-telegraf.xml.in
@@ -53,7 +53,7 @@
</properties>
<defaultValue>main</defaultValue>
</leafNode>
- #include <include/monitoring/url.xml.i>
+ #include <include/url.xml.i>
#include <include/port-number.xml.i>
<leafNode name="port">
<defaultValue>8086</defaultValue>
@@ -145,7 +145,7 @@
<constraintErrorMessage>Table is limited to alphanumerical characters and can contain hyphen and underscores</constraintErrorMessage>
</properties>
</leafNode>
- #include <include/monitoring/url.xml.i>
+ #include <include/url.xml.i>
</children>
</node>
<leafNode name="source">
@@ -271,7 +271,7 @@
</leafNode>
</children>
</node>
- #include <include/monitoring/url.xml.i>
+ #include <include/url.xml.i>
</children>
</node>
#include <include/interface/vrf.xml.i>