Assert temp output directory is not an empty string

Signed-off-by: voloder <110066198+voloder@users.noreply.github.com>
(cherry picked from commit c655b7dc78)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
voloder 2024-01-19 22:17:13 +01:00 committed by Sebastiaan van Stijn
parent 3e358447f5
commit 85f4e6151a
No known key found for this signature in database
GPG key ID: 76698F39D527CE8C

View file

@ -250,6 +250,9 @@ swagger-docs: ## preview the API documentation
.PHONY: generate-files
generate-files:
$(eval $@_TMP_OUT := $(shell mktemp -d -t moby-output.XXXXXXXXXX))
ifeq ($($@_TMP_OUT),)
$(error Could not create temp directory.)
endif
$(BUILD_CMD) --target "update" \
--output "type=local,dest=$($@_TMP_OUT)" \
--file "./hack/dockerfiles/generate-files.Dockerfile" .