text_list attributes could be empty

The issue is that sometimes users want
to be able to have emtpy lists for
some attributes like for example upstream
dns.

Change-Id: Ib96b0cb051892e50f26a46ce33eeb477ef2a36f1
Related-Bug: #1613614
This commit is contained in:
Vladimir Kozhukalov 2016-10-21 14:11:47 +03:00
parent 5062cdb7e8
commit 4f307da771
2 changed files with 4 additions and 3 deletions

View File

@ -282,16 +282,16 @@ ALLOWED_VALUES_SCHEMA = {
MULTIPLE_TEXT_FIELDS_SCHEMA = {
'value': {
'type': 'array',
'minItems': 1,
'minItems': 0,
'items': {'type': 'string'},
},
'min': {
'type': 'integer',
'minimum': 1,
'minimum': 0,
},
'max': {
'type': 'integer',
'minimum': 1,
'minimum': 0,
}
}

View File

@ -1321,6 +1321,7 @@
description: "List of upstream DNS servers"
weight: 10
type: "text_list"
min: 0
max: 3
regex:
source: &ipv4_regex '^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$'