wahnsinn vibe

This commit is contained in:
Marek Lenczewski
2026-04-16 19:42:06 +02:00
parent 9c5da44f64
commit e3e88cc58e
127 changed files with 9456 additions and 3 deletions

65
Makefile Normal file
View File

@@ -0,0 +1,65 @@
.PHONY: help infra infra-down dev backend shop admin install migrate seed reindex reset logs
help:
@echo "Shopsystem dev commands:"
@echo " make install - install backend + frontend deps"
@echo " make infra - start docker infrastructure (postgres, redis, meili, ollama, mailhog)"
@echo " make infra-down - stop docker infrastructure"
@echo " make migrate - run alembic migrations"
@echo " make seed - seed initial data (admin, demo products, etc.)"
@echo " make reindex - rebuild AI embeddings for all content"
@echo " make dev - run backend + shop + admin in parallel (foreground)"
@echo " make backend - run backend only"
@echo " make shop - run shop frontend only"
@echo " make admin - run admin frontend only"
@echo " make reset - drop DB volume and reinit (destructive)"
@echo " make logs - docker logs for infra"
install:
cd backend && uv sync
cd frontend && pnpm install
infra:
docker compose up -d postgres redis meilisearch ollama mailhog
docker compose up -d ollama-init
@echo "Infrastructure started. Ollama model pull runs in background (can take minutes)."
infra-down:
docker compose down
migrate:
cd backend && uv run alembic upgrade head
seed:
cd backend && uv run python -m core.seed
reindex:
cd backend && uv run python -m apps.ai_core.reindex
dev:
@echo "Starting backend (8000), shop (5173), admin (5174)..."
@( cd backend && uv run uvicorn core.main:app --reload --port 8000 ) & \
( cd frontend/shop && pnpm dev --port 5173 ) & \
( cd frontend/admin && pnpm dev --port 5174 ) & \
wait
backend:
cd backend && uv run uvicorn core.main:app --reload --port 8000
shop:
cd frontend/shop && pnpm dev --port 5173
admin:
cd frontend/admin && pnpm dev --port 5174
reset:
docker compose down -v
rm -rf pgdata meili-data
$(MAKE) infra
sleep 5
$(MAKE) migrate
$(MAKE) seed
$(MAKE) reindex
logs:
docker compose logs -f --tail=100