chore: add python docker-* targets
This allow testing in a similar context to the github CI.
This commit is contained in:
parent
e6945a0e45
commit
3ea085d351
|
@ -1,6 +1,7 @@
|
|||
## Custom .gitignore
|
||||
################################################################################
|
||||
|
||||
.docker/
|
||||
.DS_Store
|
||||
.idea/
|
||||
.vagrant/
|
||||
|
|
|
@ -2,6 +2,7 @@ all: lint
|
|||
|
||||
include ../tools/python.mk
|
||||
|
||||
APP := playout
|
||||
PIP_INSTALL := \
|
||||
--editable ../api-client \
|
||||
--editable ../shared \
|
||||
|
|
|
@ -74,3 +74,19 @@ install: $(VENV)
|
|||
.PHONY: .clean
|
||||
.clean:
|
||||
rm -Rf $(VENV)
|
||||
|
||||
DISTRO ?= bullseye
|
||||
DOCKER_RUN = docker run -it --rm \
|
||||
--user $$(id -u):$$(id -g) \
|
||||
--env HOME=/src/.docker/$(DISTRO) \
|
||||
--volume $$(pwd)/..:/src \
|
||||
--workdir /src/$(APP) \
|
||||
ghcr.io/libretime/libretime-dev:$(DISTRO)
|
||||
|
||||
docker-dev:
|
||||
$(MAKE) clean
|
||||
$(DOCKER_RUN) bash
|
||||
|
||||
docker-test:
|
||||
$(MAKE) clean
|
||||
$(DOCKER_RUN) make test
|
||||
|
|
Loading…
Reference in New Issue