Skip to content

Commit

Permalink
Fix registry URL regexp
Browse files Browse the repository at this point in the history
Sanity checking was a little too strict. This is better and should allow
for default config of gitlab.com, which doesn't include port numbers.
  • Loading branch information
plajjan committed Sep 15, 2019
1 parent 837afb4 commit 5d97c29
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions makefile-sanity.include
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ifdef DOCKER_REGISTRY
ifneq ($(DOCKER_REGISTRY), $(shell echo $(DOCKER_REGISTRY) | sed -ne '/^[A-Za-z0-9.\/\-]\+:[0-9]\+\([A-Za-z0-9.\/-]\+\)\?$$/p'))
$(error Bad docker registry URL. Should follow format registry.example.com:1234 or registry.example.com:1234/foo)
ifneq ($(DOCKER_REGISTRY), $(shell echo $(DOCKER_REGISTRY) | sed -ne '/^[A-Za-z0-9.\/\-]\+\(:[0-9]\+\)\?\([A-Za-z0-9.\/-]\+\)\?$$/p'))
$(error Bad docker registry URL. Should follow format registry.example.com/foo, registry.example.com:1234 or registry.example.com:1234/foo)
endif
REGISTRY=$(DOCKER_REGISTRY)/
else
Expand Down

0 comments on commit 5d97c29

Please sign in to comment.