Skip to content
This repository was archived by the owner on Oct 22, 2019. It is now read-only.

Commit 3f2cbb0

Browse files
authored
Merge pull request #129 from tonicbupt/dev
allow underscores in hostname due to `docker link`
2 parents 8219a60 + c7af60e commit 3f2cbb0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

calico_containers/pycalico/util.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,7 @@ def verify_hostname(hostname):
423423

424424
# Hostname labels may consist of numbers, letters and hyphens, but may not
425425
# end or begin with a hyphen.
426-
allowed = re.compile(r"(?!-)[a-z\d-]{1,63}(?<!-)$", re.IGNORECASE)
426+
allowed = re.compile(r"(?!-)[_a-z\d-]{1,63}(?<!-)$", re.IGNORECASE)
427427
for part in hostname.split('.'):
428428
if not allowed.match(part):
429429
err_mess = ("Hostname labels (parts delimited by periods) may "

0 commit comments

Comments
 (0)