-
Notifications
You must be signed in to change notification settings - Fork 50
Expand file tree
/
Copy pathMakefile
More file actions
57 lines (44 loc) · 1.12 KB
/
Makefile
File metadata and controls
57 lines (44 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#!make
APP_HOST ?= 0.0.0.0
APP_PORT ?= 8080
EXTERNAL_APP_PORT ?= ${APP_PORT}
LOG_LEVEL ?= warning
run = docker compose run --rm \
-p ${EXTERNAL_APP_PORT}:${APP_PORT} \
-e APP_HOST=${APP_HOST} \
-e APP_PORT=${APP_PORT} \
app
runtests = docker compose -f compose-tests.yml run --rm tests
.PHONY: image
image:
docker compose build
.PHONY: docker-run
docker-run: image
docker compose up
.PHONY: docker-run-nginx-proxy
docker-run-nginx-proxy:
docker compose -f compose.yml -f docker-compose.nginx.yml up
.PHONY: docker-shell
docker-shell:
$(run) /bin/bash
.PHONY: test
test:
$(runtests) /bin/bash -c 'export && python -m pytest /app/tests/ --log-cli-level $(LOG_LEVEL)'
.PHONY: test-catalogs
test-catalogs:
$(runtests) /bin/bash -c 'export && python -m pytest /app/tests/test_catalogs.py -v --log-cli-level $(LOG_LEVEL)'
.PHONY: run-database
run-database:
docker compose run --rm database
.PHONY: run-joplin
run-joplin:
docker compose run --rm loadjoplin
.PHONY: install
install:
uv sync --dev
.PHONY: pytest
pytest: install
uv run pytest
.PHONY: docs
docs:
uv run --group docs mkdocs build -f docs/mkdocs.yml