pulls out container.mk

This commit is contained in:
2026-07-01 16:55:29 +01:00
parent 9867d4f232
commit 7c4c5a6f50
2 changed files with 58 additions and 26 deletions
+25
View File
@@ -0,0 +1,25 @@
define build_module_rule =
.PHONY: build_$(module)
build_$(module): make_$(module) $(module).Dockerfile
podman-compose build $(module)
endef
define push_module_rule =
.PHONY: push_$(module)
push_$(module): login_registry build_$(module)
podman push $(container_image_name)
endef
define make_module_rule =
.PHONY: make_$(module)
make_$(module): $(module)/.env
$(MAKE) --directory=$(module)
endef
$(foreach module,$(COMPOSE_SERVICES),$(eval $(call build_module_rule)))
$(foreach module,$(COMPOSE_SERVICES),$(eval $(call push_module_rule)))
$(foreach module,$(MAKE_MODULES),$(eval $(call make_module_rule)))
.PHONY: login_registry
login_registry:
podman login $(REGISTRY_DOMAIN)