Skip to content

Instantly share code, notes, and snippets.

@mehd-io
Created November 22, 2021 11:11
Show Gist options
  • Save mehd-io/5685fc0856e7b7c5e53c4549308eaacb to your computer and use it in GitHub Desktop.
Save mehd-io/5685fc0856e7b7c5e53c4549308eaacb to your computer and use it in GitHub Desktop.
medium-python-api-boilerplate Make target get-img
get-img:
@echo 🐳 $@
@if [ "$$DOCKER_LAYER" != "base" ]; then\
echo 🔨 Pulling/Building base image first...; \
$(MAKE) pull-img DOCKER_LAYER=base || $(MAKE) _build-img DOCKER_LAYER=base;\
fi;\
$(MAKE) pull-img || $(MAKE) _build-img
@if [ "$$PUSH_IMAGE" = "true" ]; then\
echo ✨ Pushing the images to docker registry...; \
$(MAKE) push-img DOCKER_LAYER=base; \
$(MAKE) push-img ; \
fi;\
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment