Compare commits

...

2 Commits

Author SHA1 Message Date
John Lancaster 6c5fda9c3a styling 2026-06-18 22:04:23 -05:00
John Lancaster 99e741f2de docker implementation 2026-06-18 21:57:20 -05:00
5 changed files with 84 additions and 5 deletions
+10
View File
@@ -0,0 +1,10 @@
.git
.github
.venv
__pycache__
.cache*
.mypy_cache
.pytest_cache
.ruff_cache
site/
.env
+44
View File
@@ -0,0 +1,44 @@
# syntax=docker/dockerfile:1
FROM python:3.12-slim AS builder
COPY --from=ghcr.io/astral-sh/uv:0.8.4 /uv /uvx /bin/
ENV PYTHONDONTWRITEBYTECODE=1 \
PYTHONUNBUFFERED=1 \
UV_COMPILE_BYTECODE=1 \
UV_LINK_MODE=copy
WORKDIR /app
COPY pyproject.toml uv.lock ./
COPY src ./src
RUN uv sync --frozen --no-dev
COPY docs ./docs
COPY skills ./skills
COPY zensical.toml ./
RUN uv run zensical build
FROM python:3.12-slim AS runtime
ENV PYTHONDONTWRITEBYTECODE=1 \
PYTHONUNBUFFERED=1 \
PATH="/app/.venv/bin:$PATH" \
PERSONAL_MCP_HOST=0.0.0.0 \
PERSONAL_MCP_PORT=8765
WORKDIR /app
RUN groupadd --system --gid 1001 appuser \
&& useradd --system --uid 1001 --gid appuser --create-home --home-dir /home/appuser appuser
COPY --from=builder --chown=appuser:appuser /app /app
EXPOSE 8765
USER appuser
CMD ["uvicorn", "personal_mcp.main:app", "--host", "0.0.0.0", "--port", "8765"]
+1 -1
View File
@@ -2,7 +2,7 @@
icon: lucide/library
---
# Resource-First Pattern Module Architecture
# Architecture
## Overview
+22
View File
@@ -4,6 +4,28 @@ icon: lucide/rocket
# Get started
## Quick start
Install dependencies first:
```bash
uv sync
```
Run the app locally with the static docs rebuilt first:
```bash
uv run zensical build && uv run uvicorn personal_mcp.main:app --host 127.0.0.1 --port 8765
```
Build and run the Docker image with the same exposed port:
```bash
docker build -t personal-mcp . && docker run --rm -p 8765:8765 personal-mcp
```
When the server is running, the health check is available at `/healthz` and the generated docs are available at `/docs/`.
## Architecture
- [Resource-First Pattern Module Architecture](./architecture.md)
+7 -4
View File
@@ -13,10 +13,13 @@ It also treats Markdown as the single source of truth for both MCP resources and
```mermaid
---
config:
themeVariables:
treeView:
labelColor: '#FFFFFF'
lineColor: '#FFFFFF'
treeView:
rowIndent: 40
lineThickness: 2
themeVariables:
treeView:
labelColor: '#FFFFFF'
lineColor: '#FFFFFF'
---
treeView-beta
"project-root"