From f71e28512de5ac88ec54b21abc9fb78d302600f0 Mon Sep 17 00:00:00 2001 From: Paul Campbell Date: Thu, 23 Jan 2025 08:23:37 +0000 Subject: [PATCH] build(justfile): run-*-in-docker builds the image first --- justfile | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/justfile b/justfile index fdf5983..7568e21 100644 --- a/justfile +++ b/justfile @@ -17,11 +17,16 @@ test-in-docker: shell-in-docker: docker run --rm -u $(id -u):$(id -g) -it -v ${PWD}:/app/ git.kemitix.net/kemitix/rust:latest bash -run-in-docker: - docker run --rm -u $(id -u):$(id -g) -v ${PWD}:/app/ git.kemitix.net/kemitix/git-next:latest server start +docker-test-image := "git.kemitix.net/kemitix/git-next:test" -run-ui-in-docker: - docker run --rm -u $(id -u):$(id -g) -it -v ${PWD}:/app/ git.kemitix.net/kemitix/git-next:latest server start --ui +build-docker: + docker build . -t {{ docker-test-image }} + +run-in-docker: build-docker + docker run --rm -u $(id -u):$(id -g) -v ${PWD}:/app/ {{ docker-test-image }} server start + +run-ui-in-docker: build-docker + docker run --rm -u $(id -u):$(id -g) -it -v ${PWD}:/app/ {{ docker-test-image }} server start --ui install-hooks: @echo "Installing git hooks"