|
|
@@ -15,7 +15,7 @@
|
|
|
|
COMPOSE := {% if layout == 'part' %}cd .. && {% endif %}docker compose
|
|
|
|
COMPOSE := {% if layout == 'part' %}cd .. && {% endif %}docker compose
|
|
|
|
{% if svc_modules %}IMAGE := {{ project_slug }}/backend
|
|
|
|
{% if svc_modules %}IMAGE := {{ project_slug }}/backend
|
|
|
|
IMAGE_INPUTS := pyproject.toml uv.lock Dockerfile
|
|
|
|
IMAGE_INPUTS := pyproject.toml uv.lock Dockerfile
|
|
|
|
CODE := src{% if has_scripts %} scripts{% endif %}
|
|
|
|
CODE := src{% if has_scripts %} scripts{% endif %}{% if serve_spa %} ../frontend{% endif %}
|
|
|
|
SERVICES := {{ app_services | join(' ') }}
|
|
|
|
SERVICES := {{ app_services | join(' ') }}
|
|
|
|
changed = ! git diff --quiet $(1) -- $(2) 2>/dev/null
|
|
|
|
changed = ! git diff --quiet $(1) -- $(2) 2>/dev/null
|
|
|
|
stamp = { git update-ref $(1) HEAD 2>/dev/null || true; }
|
|
|
|
stamp = { git update-ref $(1) HEAD 2>/dev/null || true; }
|
|
|
@@ -72,14 +72,14 @@ deploy: pre-deploy
|
|
|
|
$(MAKE) post-deploy
|
|
|
|
$(MAKE) post-deploy
|
|
|
|
{% endif %}{% endif %}{% if database == 'postgres' %}
|
|
|
|
{% endif %}{% endif %}{% if database == 'postgres' %}
|
|
|
|
migrate:
|
|
|
|
migrate:
|
|
|
|
$(COMPOSE) run --rm migrator
|
|
|
|
$(COMPOSE) run --rm migrator $(or $(filter-out $@,$(MAKECMDGOALS)),upgrade head)
|
|
|
|
|
|
|
|
|
|
|
|
revision:
|
|
|
|
revision:
|
|
|
|
$(COMPOSE) run --rm migrator revision --autogenerate -m "$(m)"
|
|
|
|
$(COMPOSE) run --rm migrator revision --autogenerate -m "$(m)"
|
|
|
|
{% endif %}{% if has_script %}
|
|
|
|
{% endif %}{% if has_script %}
|
|
|
|
script:
|
|
|
|
script:
|
|
|
|
@$(COMPOSE) run --rm {{ svc_modules[0] }} scripts.$(word 2,$(MAKECMDGOALS)) $(wordlist 3,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
|
|
|
|
@$(COMPOSE) run --rm {{ svc_modules[0] }} scripts.$(word 2,$(MAKECMDGOALS)) $(wordlist 3,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
|
|
|
|
|
|
|
|
{% endif %}{% if database == 'postgres' or has_script %}
|
|
|
|
%:
|
|
|
|
%:
|
|
|
|
@:
|
|
|
|
@:
|
|
|
|
{% endif %}{% if 'kurigram_userbot' in backend_services %}
|
|
|
|
{% endif %}{% if 'kurigram_userbot' in backend_services %}
|
|
|
|