Skip to content

Commit

Permalink
Add make target to stop the database
Browse files Browse the repository at this point in the history
  • Loading branch information
samdoran committed Jan 15, 2025
1 parent 930a849 commit 3c9e083
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,13 @@ install-dev: venv
$(PIP) install -r requirements/requirements-dev-$(PYTHON_VERSION).txt

.PHONY: run-db
run-db:
run-db: stop-db
$(CONTAINER_RUNTIME) run --rm -d -p $(DB_PORT):5432 --name digital-roadmap-data $(DB_IMAGE)

.PHONY: stop-db
stop-db:
@$(CONTAINER_RUNTIME) stop digital-roadmap-data > /dev/null 2>&1 || true
@sleep 0.1
$(CONTAINER_RUNTIME) run --rm -d -p $(DB_PORT):5432 --name digital-roadmap-data $(DB_IMAGE)

.PHONY: run
run:
Expand Down

0 comments on commit 3c9e083

Please sign in to comment.