summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2021-08-23 15:18:12 +0200
committerChristian Poessinger <christian@poessinger.com>2021-08-23 15:18:12 +0200
commita663816d5add31ffea849839c7dccc2029d64201 (patch)
tree83006119812c9243ef1c4715305d80b6a332edfa
parent618f30225e8cd69fcbff475d2adff0785a621620 (diff)
downloadvyos-1x-a663816d5add31ffea849839c7dccc2029d64201.tar.gz
vyos-1x-a663816d5add31ffea849839c7dccc2029d64201.zip
container: T2216: name of container must be alphanumeric and can contain a hyphen
-rw-r--r--interface-definitions/containers.xml.in4
1 files changed, 4 insertions, 0 deletions
diff --git a/interface-definitions/containers.xml.in b/interface-definitions/containers.xml.in
index 419802866..39ef945a3 100644
--- a/interface-definitions/containers.xml.in
+++ b/interface-definitions/containers.xml.in
@@ -9,6 +9,10 @@
<tagNode name="name">
<properties>
<help>Container name</help>
+ <constraint>
+ <regex>^[-a-zA-Z0-9]+$</regex>
+ </constraint>
+ <constraintErrorMessage>Container name must be alphanumeric and can contain hyphens</constraintErrorMessage>
</properties>
<children>
<leafNode name="allow-host-networks">