diff --git a/ipynbsrv/core/models.py b/ipynbsrv/core/models.py index bd959b3..ade260d 100644 --- a/ipynbsrv/core/models.py +++ b/ipynbsrv/core/models.py @@ -776,7 +776,7 @@ class ContainerImage(models.Model): max_length=75, validators=[ RegexValidator( - regex='^[A-z][\w\/]*$', + regex='^[A-z][\w\/-]*$', message='Invalid container snapshot name.' ) ] diff --git a/ipynbsrv/web/templates/web/container_snapshots/modal_create.html b/ipynbsrv/web/templates/web/container_snapshots/modal_create.html index b87aa5e..d6647b2 100644 --- a/ipynbsrv/web/templates/web/container_snapshots/modal_create.html +++ b/ipynbsrv/web/templates/web/container_snapshots/modal_create.html @@ -13,8 +13,8 @@
- -

Allowed pattern: ^[A-z]\w*$

+ +

Allowed pattern: ^[A-z]\w*$

diff --git a/ipynbsrv/web/templates/web/containers/modal_create.html b/ipynbsrv/web/templates/web/containers/modal_create.html index 0eb0299..73940bc 100644 --- a/ipynbsrv/web/templates/web/containers/modal_create.html +++ b/ipynbsrv/web/templates/web/containers/modal_create.html @@ -12,7 +12,8 @@