diff options
Diffstat (limited to 'lib/container_registry/path.rb')
-rw-r--r-- | lib/container_registry/path.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/container_registry/path.rb b/lib/container_registry/path.rb index 27e0e7897ff..6e8d62b77c7 100644 --- a/lib/container_registry/path.rb +++ b/lib/container_registry/path.rb @@ -22,7 +22,9 @@ module ContainerRegistry end def valid? - @nodes.size > 1 && @nodes.size < Namespace::NUMBER_OF_ANCESTORS_ALLOWED + @path =~ Gitlab::Regex.container_repository_name_regex && + @nodes.size > 1 && + @nodes.size < Namespace::NUMBER_OF_ANCESTORS_ALLOWED end def components |