Created
July 4, 2019 18:18
-
-
Save jabelk/bd91249e4473951388ad02a7d8a2ee31 to your computer and use it in GitHub Desktop.
docker make
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DOCKER_IMG = testexplorer | |
DOCKER_TAG = latest | |
CONTAINER_NAME = testexplorer-container | |
.PHONY: build | |
build: | |
docker build -t $(DOCKER_IMG):$(DOCKER_TAG) . | |
.PHONY: run | |
run: | |
docker start -ai $(CONTAINER_NAME) | |
.PHONY: init | |
init: | |
docker run -it \ | |
--name $(CONTAINER_NAME) \ | |
$(DOCKER_IMG):$(DOCKER_TAG) | |
.PHONY: rebuild | |
rebuild: | |
docker stop $(CONTAINER_NAME); \ | |
docker rm $(CONTAINER_NAME); \ | |
docker rmi $(DOCKER_IMG):$(DOCKER_TAG); \ | |
make build-image; \ | |
make init-power |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment