Skip to content

Commit

Permalink
ci/cd: add docker recipes in Makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
oedokumaci committed Feb 21, 2024
1 parent 2fb01e1 commit 742e70a
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,27 @@ endif
run: ## Run project
pdm run python -m gale_shapley $(number_of_simulations)

docker-build: ## Build Docker image for the project
docker build -t gale-shapley .

docker-run: ## Run Docker container for the project
docker run --rm -it \
-v $(PWD)/config/example_config_custom_input.yaml:/usr/src/app/config/config.yaml \
-v $(PWD)/logs:/usr/src/app/logs \
-e number_of_simulations=$(number_of_simulations) \
gale-shapley

docker: docker-build docker-run ## Build and run project in Docker

docker-logs: ## Show Docker container logs
docker logs -f $(shell docker ps -q)

docker-stop: ## Stop Docker container
docker stop $(shell docker ps -q)

docker-kill: ## Kill Docker container
docker kill $(shell docker ps -q)

project-help: ## Show project help
pdm run python -m gale_shapley --help

Expand Down

0 comments on commit 742e70a

Please sign in to comment.