Marcel 9fcd0553bd
Some checks failed
CI / Unit & Component Tests (pull_request) Failing after 2m51s
CI / OCR Service Tests (pull_request) Successful in 21s
CI / Backend Unit Tests (pull_request) Successful in 3m43s
CI / fail2ban Regex (pull_request) Failing after 42s
CI / Semgrep Security Scan (pull_request) Successful in 20s
CI / Compose Bucket Idempotency (pull_request) Successful in 1m1s
test(mocks): switch $app/navigation factory mocks to shared __mocks__ stub
Migrates 36 of the remaining 37 vi.mock('$app/navigation', factory) call
sites in frontend/src/**/*.svelte.{spec,test}.ts to
vi.mock('$app/navigation') (no factory), so they all resolve to the
shared src/__mocks__/$app/navigation.ts stub introduced in commit
aea37250.

Special handling:
- DropZone.svelte.spec.ts: removed vi.hoisted invalidateAllMock; test
  body now imports invalidateAll from $app/navigation and uses
  vi.mocked(invalidateAll) for assertions.
- documents/bulk-edit/page.svelte.test.ts: removed the module-scope
  const gotoSpy = vi.fn() that was injected into the factory; test
  body now imports goto from $app/navigation and uses
  vi.mocked(goto) for assertions and mockClear().

Deferred: src/lib/shared/hooks/useUnsavedWarning.svelte.test.ts uses a
non-trivial beforeNavigate wrapper that captures the callback into
module-scope state (registeredBeforeNavigate) so tests can simulate
navigation events. That hybrid factory cannot be replaced with the
plain-vi.fn() shared stub without redesigning the test; it is left in
place and will be addressed separately.

Per ADR-012: eliminating factory bodies removes 36 birpc teardown-race
surface points. The shared mock keeps every nav export as a vi.fn().

Refs #560.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-21 18:42:52 +02:00

Familienarchiv

Familienarchiv is a private web application for digitising, organising, and searching a family document collection — letters, postcards, and photographs from 1899 to 1950. Family members upload scans, transcribe handwritten text (Kurrent/Sütterlin), and read the archive from any device.


Subsystems

  • frontend/ — SvelteKit 2 / Svelte 5 / TypeScript / Tailwind 4 web app (server-side rendered)
  • backend/ — Spring Boot 4 (Java 21) REST API; handles documents, persons, search, and user management
  • ocr-service/ — Python FastAPI microservice for OCR and handwritten text recognition (HTR); single-node by design — see ADR-001. Not part of the default dev stack (see Quick start below)
  • infra/ — Gitea Actions CI/CD config; future home for infrastructure-as-code
  • scripts/ — operational and data-pipeline helpers (reset-db.sh, clean-e2e-data.sh, import scripts)

Quick start

Prerequisites: Java 21, Node 24, Docker with the docker compose plugin (V2).

1. Configure environment

cp .env.example .env
# The defaults in .env.example work for local development without changes.

2. Start infrastructure

# Starts PostgreSQL, MinIO (object storage), and Mailpit (dev mail catcher)
docker compose up -d db minio mailpit

3. Start the backend

cd backend
./mvnw spring-boot:run
# Starts on http://localhost:8080
# API docs (dev profile, auto-enabled): http://localhost:8080/v3/api-docs

4. Start the frontend

cd frontend
npm install
npm run dev
# Starts on http://localhost:5173

Open http://localhost:5173 — you should see the Familienarchiv login screen.

Default development credentials:

# local dev only — change before any network-exposed deployment
Email:    admin@familyarchive.local
Password: admin123

Development setup only. The default docker compose config exposes the database port and uses root MinIO credentials. Do not connect this to a network without first reading docs/DEPLOYMENT.md (coming: DOC-5, #399).

Running the full stack via Docker (optional)

To run everything including the backend and frontend in containers:

docker compose up -d

Note: the OCR service (ocr-service/) builds its Docker image locally and downloads ~6 GB of ML models on first start. Expect 3060 minutes on a first run. The rest of the stack starts independently; OCR can be excluded with --scale ocr-service=0 on memory-constrained machines (requires ≥ 12 GB RAM).


Where to go next

Resource Purpose
docs/architecture/c4-diagrams.md C4 container and component diagrams (current system view)
docs/ARCHITECTURE.md (coming: DOC-2, #396) Full architecture guide with domain list
docs/GLOSSARY.md Overloaded terms: Person vs AppUser, Chronik vs Aktivität, etc.
CONTRIBUTING.md (coming: DOC-4, #398) How to add a domain, endpoint, or SvelteKit route
docs/DEPLOYMENT.md (coming: DOC-5, #399) Production deployment checklist and secrets guide
docs/adr/ Architecture Decision Records — the "why" behind key choices
Gitea issue tracker (internal — home network only) Bug reports, feature requests, and project planning

License

Private project — all rights reserved. Not licensed for redistribution.

Description
No description provided
Readme 43 MiB
Languages
Python 72.2%
TypeScript 11.9%
Java 11.3%
Svelte 4.3%
Shell 0.1%