PhotoPrism Docs CODEMAP
Last Updated: November 15, 2025
Purpose
- Provide a fast orientation for contributors touching docs.photoprism.app so they can locate Markdown sources, assets, templates, and build tooling without guesswork.
- Complement
AGENTS.mdby showing how MkDocs configuration, content folders, and deployment helpers relate to one another.
Quick Start
- Local workflow: run
make deps(Debian/Ubuntu) ormake installto createvenv/, refresh withmake upgradewhen you need the latest dependencies, thenmake watchto serve http://localhost:8000/ with live reload. Usemake buildfor a production render andmake deployonly when explicitly asked to push viamkdocs gh-deploy. - Branch flow: work in
develop, review via pull requests, then merge intodeploy(or runmake merge) so the GitHub Actions pipeline rebuilds and publishes docs.photoprism.app. Keepmkdocs.ymlandmkdocs.deploy.ymlin sync before opening a PR. - Container option: a
Dockerfileexists (FROMsquidfunk/mkdocs-material:latest), but it is currently unsupported because it previously broke; default to the Python virtualenv workflow unless the team revives container builds.
Tooling & Configuration
README.md— contributor entry point with MkDocs overview, deployment expectations, and CLA reminder.Makefile— canonical command surface: environment setup (deps,install,upgrade), MkDocs lifecycle (serve,build,deploy), cleanup (remove-venv), Git helpers (pull,push,merge), and utilities such asimg-resize(ImageMagick) for screenshot normalization.requirements.txt— Python dependencies (MkDocs ≥1.5, Material extensions, pymdown-extensions, social plugin requirements). Keep it aligned with the version installed bymake install..env(local) — optional environment overrides (proxies, custom paths, etc.); MkDocs Material Insiders now installs via PyPI so no token is needed.Dockerfile— legacy container definition not referenced by the Makefile; keep it in sync only if the team decides to reintroduce containerized builds.mkdocs.yml— main site configuration: navigation tree, metadata (site_name,extra.social), theme options (Material + custom palette), edit links (edit_uri), plugin set (redirects), and Markdown extensions (pymdownx suite, tooltips, task lists, mermaid, etc.).mkdocs.deploy.yml— inherits the base config and appendssearch,privacy, and the production redirect map plus asset mirrors. Use this when building or deploying the published site.overrides/— Material template overrides:main.htmlmanages social/OG tags, favicon set, analytics (a.photoprism.app), and the banner, whilepartials/copyright.htmlreplaces the footer.- Generated output lives in
site/(ignored). Runningmkdocs buildrefreshes it; never edit the files manually. venv/contains the Python virtual environment; recreate it withmake installif dependencies drift.
Content Map (docs/)
- Root landing pages:
index.md(homepage content),known-issues.md,release-notes.md, andcredits.mdsurface product-wide updates; update them whenever app releases ship or contributor acknowledgments change. - Licenses:
docs/license/agpl.md,docs/license/apache.md, anddocs/license/docs.mdprovide legal text for software, libraries, and documentation terms. - Shared media:
docs/img/holds global hero images and badges, while section-specificimg/folders (e.g.,docs/user-guide/img/,docs/developer-guide/img/, and nestedimg/directories) store contextual screenshots.docs/icons/bundles favicons plus SVG/PNG logo variants alongsidedocs/icons/LICENSE. - Styling:
docs/css/custom.csscontains site-wide overrides (typography tweaks, custom callouts, responsive helpers). Keep selectors scoped to avoid clashing with Material defaults.
Getting Started Section (docs/getting-started/)
- Entry page:
index.mdintroduces installation paths;config-options.mdand theconfig-files/folder documentoptions.yml,defaults.yml, andsettings.yml. - Deployment guides:
docker-compose.md,docker.md, and subdirectories forcloud/(PikaPods, DigitalOcean),nas/(Asustor, Synology, QNAP, Unraid, OpenMediaVault),ports/(FreeBSD), andraspberry-pi/(requirements + microSD image). - Operations:
advanced/covers OIDC, transcoding, Kubernetes, volumes, backups, DB migrations, caching, proxying, and scaling.proxies/details Traefik, Caddy, NGINX, Apache, SWAG, HAProxy.vpn/contains Tailscale guidance. - Troubleshooting:
troubleshooting/hosts logs, Docker, MariaDB, SQLite, Windows, browser, metadata, performance, firewall, and Raspberry Pi checklists.faq.md,using-https.md,using-a-cdn.md, andupdates.mdround out the setup flow.
User Guide Section (docs/user-guide/)
- Core navigation:
index.md,first-steps.md, andnavigate.mdexplain the UI and onboarding experience. - Feature deep dives live under
organize/(albums, people, stacks, labels, archive, download, etc.),search/(index, filters, result views),library/(originals, imports, duplicates, metadata, upload, WebDAV, files), andsettings/(general, library, advanced, services, account). - Specialized areas:
sync/(WebDAV, mobile, Dropbox integrations),backups/(create, restore, external storage, directory overview),share/,users/(admin UI, CLI, roles, guests, multi-library, 2FA, client credentials),use-cases/(Google, Apple, Flickr migrations),pwa.md, andnative-apps/describe remote clients.
Developer Guide Section (docs/developer-guide/)
- Orientation:
index.md,setup.md,directories.md,issues.md,pull-requests.md,reviewing-pull-requests.md,code-quality.md,tests.md,configuration.md,documentation.md, andfaq.mdestablish workflow norms. - Localization:
translations.mdandtranslations-weblate.mddocument string workflows. - Media stack:
media/(formats, raw, HEIC, video, live photos, thumbnails, storage),metadata/(XMP, EXIF extraction/editing, geocoding, orientation, perceptual hashes, color detection, camera models). - Vision & AI:
vision/(face recognition, label/caption generation, model comparison, CLI, TensorFlow adapters,vision/service/playground + setup). - API & integrations:
api/(intro, docs, auth, OIDC, OAuth2, search, thumbnails, Go client),native-apps/(platform guides + device resolutions),ui/(introduction, screenshots, components, design/colors, browsers, maps, infinite scrolling, focus management). - Data layer:
database/(index, migrations, ER diagram) andtechnologies/(YAML, Go, TensorFlow, Docker, Broadway, external APIs) describe dependencies;security/covers testing, Go secure coding, and policy.
About & Miscellaneous
docs/credits.mdthanks contributors and sponsors.docs/license/feeds the Licenses navigation tab configured under "About" inmkdocs.yml.todo/stores drafts not yet linked (currentlydeveloper-guide/setup-fedora.md). Move completed drafts intodocs/and delete the placeholder.
Assets & Overrides
docs/icons/contains favicon sizes referenced fromoverrides/main.html; ensure new icons follow the same naming scheme before linking them in the template.docs/img/and nested folders includeLICENSEfiles for creative assets. Keep alt text synchronized with filenames to aid accessibility.overrides/main.htmladjusts<head>metadata, Open Graph/Twitter cards, favicon declarations, and injects the membership CTA banner plus outbound link analytics script. When editing, verify both light/dark themes and ensure new domains are approved.overrides/partials/copyright.htmlrenders the footer. Update it when legal wording or attribution changes.
Drafting & Maintenance Tips
- Every new page must be registered in
mkdocs.yml; if you relocate or rename a file, add redirect entries to bothmkdocs.ymlandmkdocs.deploy.yml. - Keep filenames lowercase with hyphens (
snake-case.md) to match existing URLs; directories mirror navigation labels. - Before committing images, run
make img-resizewhere applicable and store assets alongside their Markdown. - Use admonitions, tabs, and tooltips from the configured Markdown extensions instead of custom shortcodes; this keeps the content portable to Read the Docs and GitHub previews.