chore(makefile): add docker run targets (#32)

* chore(makefile): add docker run targets

Signed-off-by: archasek <2247211+archasek@users.noreply.github.com>

* chore(makefile): modify run tasks

Signed-off-by: archasek <2247211+archasek@users.noreply.github.com>

* chore(makefile): modify run tasks

Signed-off-by: archasek <2247211+archasek@users.noreply.github.com>

---------

Signed-off-by: archasek <2247211+archasek@users.noreply.github.com>
This commit is contained in:
archas
2025-02-11 09:52:07 +01:00
committed by GitHub
parent 4da28565a7
commit de42baf8dc

View File

@@ -62,7 +62,6 @@ md-lint: .md-lint ## Lint markdown files
$(CMD_PREFIX) docker run --rm -v $$(pwd):/workdir davidanson/markdownlint-cli2:v0.14.0 "**/*.md"
$(CMD_PREFIX) touch $@
.PHONY: py-Lint
py-lint: ## Lint Python files
$(ECHO_PREFIX) printf " %-12s ./...\n" "[PY LINT]"
@@ -73,3 +72,17 @@ py-lint: ## Lint Python files
fi
$(CMD_PREFIX) poetry install --all-extras
$(CMD_PREFIX) poetry run pre-commit run --all-files
.PHONY: run-docling-cpu
run-docling-cpu: ## Run the docling-serve container with CPU support and assign a container name
$(ECHO_PREFIX) printf " %-12s Removing existing container if it exists...\n" "[CLEANUP]"
$(CMD_PREFIX) docker rm -f docling-serve-cpu 2>/dev/null || true
$(ECHO_PREFIX) printf " %-12s Running docling-serve container with CPU support on port 5001...\n" "[RUN CPU]"
$(CMD_PREFIX) docker run -it --name docling-serve-cpu -p 5001:5001 ghcr.io/ds4sd/docling-serve-cpu:main
.PHONY: run-docling-gpu
run-docling-gpu: ## Run the docling-serve container with GPU support and assign a container name
$(ECHO_PREFIX) printf " %-12s Removing existing container if it exists...\n" "[CLEANUP]"
$(CMD_PREFIX) docker rm -f docling-serve-gpu 2>/dev/null || true
$(ECHO_PREFIX) printf " %-12s Running docling-serve container with GPU support on port 5001...\n" "[RUN GPU]"
$(CMD_PREFIX) docker run -it --name docling-serve-gpu -p 5001:5001 ghcr.io/ds4sd/docling-serve:main