Files
docker-builder/Makefile

23 lines
657 B
Makefile

define INC_DOCKER =
1
endef
$(info Defined INC_DOCKER)
include /devel/docker/docker_vars.sh
export
${docker_src}/built/%.sentinel: ${docker_src}/%.dockerfile
grep -e '^FROM' $< | awk '{print $$2}' \
| tr : _ | xargs -I{} $(MAKE) ${docker_src}/built/{}.sentinel;
cd ${docker_src}; docker build -f $< --tag $* .;
touch $@;
${docker_src}/built/debian_10.sentinel:
docker pull "debian:10" && touch $@;
${docker_src}/built/openwrt-builder-%.sentinel: \
${docker_src}/openwrt-builder-commit.dockerfile \
${docker_src}/built/openwrt-builder.sentinel
cd ${docker_src}; docker build -f $< --build-arg=commit=$* --tag openwrt-builder-$* .; \
touch $@;