Commit Graph

24 Commits

Author SHA1 Message Date
SysAdmin Agent
d5eb072a46 Fix GrampsWeb: recursive CSS find + auto-create admin on startup (STI-90)
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
- Use `find` instead of `*.css` glob to catch fonts/fonts.css in subdirs
- Add Python script to auto-create Admin user if no users exist yet

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-24 11:18:18 +00:00
SysAdmin Agent
700a6472b7 Fix GrampsWeb subpath: patch CSS font paths from ../fonts/ to fonts/ (STI-90)
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
CSS url() resolves relative to the stylesheet, not <base href>. With
the stylesheet at /ahnenforschung/style.css, url('../fonts/...') resolves
to /fonts/ (root) instead of /ahnenforschung/fonts/. Changed to relative
url('fonts/...') which correctly resolves under the subpath.

Also fixes Material Icons font not loading (menu icons broken).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-24 10:27:47 +00:00
SysAdmin Agent
905e5a7d6c Fix GrampsWeb subpath: patch location.href redirects to root (STI-90)
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
GrampsWeb JS has 6 instances of location.href="/" that redirect users
to the root domain (Django app) instead of /ahnenforschung/. These
are now patched at container startup alongside the API path rewrites.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-24 10:08:35 +00:00
SysAdmin Agent
3cdf49419e Fix GrampsWeb subpath: patch API/lang/font paths in JS at startup (STI-90)
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
GrampsWeb's frontend JS hardcodes absolute paths like "/api/...",
"/lang/...", "/fonts/..." which bypass <base href>. These now get
rewritten to "/ahnenforschung/api/..." etc. at container startup,
matching both double-quoted and template-literal (backtick) patterns.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-24 09:57:29 +00:00
SysAdmin Agent
2a579c83c0 Improve GrampsWeb base href patching: find all index.html copies (STI-90)
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
The previous sed only patched two known paths. Now uses find to discover
and patch all index.html files containing <base href="/"> across the
entire container, with logging to show which files were patched.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-24 08:44:21 +00:00
SysAdmin Agent
55da366014 Fix GrampsWeb subpath: patch <base href> at container startup (STI-93)
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
The GrampsWeb SPA has <base href="/"> hardcoded at build time, causing
assets to load from / instead of /ahnenforschung/ when behind a reverse
proxy. Instead of relying on nginx sub_filter (which may not be available),
patch the HTML at container startup via GRAMPSWEB_SUBPATH env var.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-24 02:37:53 +00:00
SysAdmin Agent
951c434ef2 Fix GrampsWeb subpath: use nginx sub_filter for <base href> rewrite (STI-93)
Some checks failed
CI/CD Pipeline / deploy (push) Has been cancelled
CI/CD Pipeline / test (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
GrampsWeb's SPA has <base href="/"> hardcoded at build time. The
GRAMPSWEB_BASE_URL env var is a full URL for API/OIDC, not a path prefix.
This means assets always load from root, hitting Django instead of GrampsWeb.

Fix: nginx sub_filter rewrites <base href="/"> to <base href="/ahnenforschung/">
so the browser resolves all SPA assets under the correct subpath.

Also revert BASE_URL default to a proper URL (not a path).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 23:23:28 +00:00
SysAdmin Agent
fd626a9c66 Fix GrampsWeb: remove broken STATIC_PATH/STATIC_URL config (STI-90)
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
GRAMPSWEB_STATIC_PATH was set to /ahnenforschung/static (a URL path)
instead of a filesystem path, causing GrampsWeb to return 404 on all
routes. Removed STATIC_PATH and STATIC_URL (defaults work correctly)
and simplified BASE_URL to /.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-23 21:02:01 +00:00
SysAdmin Agent
5807bf85f1 GrampsWeb Phase 1: Production Compose, Reverse Proxy & Deployment (STI-91)
- Fix grampsweb port mapping: 8090:80 → 8090:5000 (gunicorn, not nginx)
- Add full subpath ENV vars: GRAMPSWEB_TREE, BASE_URL, STATIC_PATH, STATIC_URL
- Add Celery/Redis config: broker_url, result_backend, ratelimit storage
- Add GRAMPSWEB_NEW_DB_BACKEND=sqlite
- Add depends_on: redis and restart: unless-stopped
- Add GRAMPS_URL/USERNAME/PASSWORD/API_TOKEN to web service for Django integration
- Add nginx.conf with /ahnenforschung/ reverse proxy route (proxy to localhost:8090)
- Add GRAMPSWEB_STATIC_PATH and GRAMPSWEB_STATIC_URL to env-template.txt

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-21 23:47:52 +00:00
SysAdmin Agent
31bf348136 fix: Add media_files volume to worker service (STI-84)
Celery worker was missing the media_files:/app/media volume mount,
causing DMS files saved by background tasks (email attachments,
Bestätigungsschreiben PDFs) to land in ephemeral container storage
instead of the persistent named volume. After any container restart,
these files were lost while DB records remained → Http404.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-21 21:36:22 +00:00
SysAdmin Agent
28621d2774 feat: Veranstaltungsmodul + Serienbrief mit editierbaren Feldern (STI-35, STI-39)
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy (push) Has been cancelled
Code Quality / quality (push) Has been cancelled
Implementierung des Veranstaltungsmoduls inkl. Serienbrief-PDF-Generator
mit dynamischen, editierbaren Feldern für Betreff und Unterschriften.

### Veranstaltungsmodul (STI-35)
- Neues Veranstaltungs-Modell: Titel, Datum, Uhrzeit, Ort, Gasthaus-Adresse,
  Briefvorlage, Gästeliste (VerstaltungsGast mit freien/Destinatär-Feldern)
- Views: Veranstaltungsliste, -detail, Serienbrief-PDF-Generator
- Templates: list.html, detail.html, serienbrief_pdf.html (A4, einseitig)
- API: Serializer + Endpunkte für Veranstaltungen
- Admin: Inline-Bearbeitung der Gästeliste
- Migration: 0044_veranstaltungsmodul

### Serienbrief editierbare Felder + PDF-Fix (STI-39)
- Neue Felder an Veranstaltung: betreff, unterschrift_1_name/titel,
  unterschrift_2_name/titel (mit Defaults: Katrin Kleinpaß / Jan Remmer Siebels)
- PDF-CSS: Margins, Font-Sizes und Line-Heights reduziert für einseitigen Druck
- Migration: 0045_add_serienbrief_editable_fields

### Infrastruktur
- scripts/init-paperless-db.sh: Erstellt separate Paperless-DB beim DB-Init
- compose.yml: init-paperless-db.sh eingebunden, PAPERLESS_DBNAME-Fix
- .gitignore: .claude/ ausgeschlossen

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-10 22:36:58 +00:00
SysAdmin Agent
f8f9dc3319 feat: Memory-Konzept für Agents implementieren (STI-21)
- REST API: 9 Read-Only-Endpunkte unter /api/v1/ für alle Kernmodelle
  (Destinatäre, Ländereien, Pächter, Förderungen, Konten,
  Verpachtungen, Verwaltungskosten, Kalender, Transaktionen)
- Token-Authentifizierung via DRF TokenAuthentication
- Management-Command `create_agent_token` für Agent-Tokens
- Wissensbasis: knowledge/ mit Satzung, Richtlinien, Verfahren,
  Kontakte, Historie
- Agent-Instructions: Datenzugriff-Sektion in AGENTS.md dokumentiert

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-09 22:45:11 +00:00
Stiftung Development
7744a18657 Fix and enhance CSV import templates
- Update Destinataer template: added 8 missing fields (ist_abkoemmling, haushaltsgroesse, monatliche_bezuege, vermoegen, unterstuetzung_bestaetigt, vierteljaehrlicher_betrag, studiennachweis_erforderlich, letzter_studiennachweis)
- Update Laendereien template: added 20 missing fields including property details, tenant info, contract terms, financial data, and tax information
- Fix JavaScript template download functionality: correct block name from extra_js to javascript
- Add comprehensive debugging and error handling for download process
- Improve CSV formatting with proper quoting for text fields containing spaces
- Add fallback download methods for better browser compatibility

All CSV templates now include complete field sets matching current model definitions.
2025-09-19 12:36:17 +02:00
Stiftung Development
a6559daeb1 Clean up docker-compose configuration
- Archive deploy-production directory as deploy-production-archived (legacy)
- Add DOCKER_COMPOSE_README.md for documentation
- Main configuration now uses compose.yml with working Paperless integration
- Paperless API URL configured as https://vhtv-stiftung.de/paperless
2025-09-17 13:19:35 +02:00
Stiftung Development
8a4a494610 Fix production deployment: preserve .env file + add missing volume + simplified pipeline 2025-09-15 23:41:54 +02:00
Stiftung Development
5ff7b7a3ed Fix production deployment: use pre-built images instead of local builds + handle git conflicts 2025-09-15 23:21:05 +02:00
Stiftung Development
0d92fe3d32 fix: Correct production deployment to use pre-built Docker images
CRITICAL: This fixes the deployment issue where changes weren't appearing on production

Changes:
- Update docker-compose.prod.yml to use ghcr.io pre-built images instead of local builds
- Fix deployment script to pull latest images rather than building locally
- Add proper GitHub Container Registry authentication
- Remove --build flag that was causing deployment to use stale local code

This should resolve the issue where www.vhtv-stiftung.de wasn't showing the new Verpachtung features.
2025-09-15 22:08:13 +02:00
Stiftung Development
9075f68d16 Add gitignore for sensitive files and Docker Compose path fix script
- Add ACCOUNTS.txt and other sensitive files to .gitignore
- Add fix-paths.sh script for correcting Docker Compose volume paths
- Prevent accidental commit of passwords and API tokens
2025-09-10 23:07:32 +02:00
Stiftung Development
40fe13e9ad Fix Docker Compose paths - remove version warning and fix app context paths 2025-09-09 22:52:02 +02:00
Stiftung Development
950c513112 Fix Paperless setup script - remove Django dependency and simplify secret generation 2025-09-09 22:28:02 +02:00
Stiftung Development
fa6d1b64df Add Paperless-ngx to production deployment
- Add Paperless-ngx service to Docker Compose configuration
- Configure nginx routing for /paperless/ path with large file support
- Add production environment variables for Paperless
- Create automated setup script for initial Paperless configuration
- Add comprehensive production setup documentation
- Configure Paperless with HTTPS and proper database setup
- Update Django app to use production Paperless instance
2025-09-09 22:00:32 +02:00
Stiftung Development
236e1d2ad2 Add HTTPS/SSL security configuration
- Update nginx config for HTTPS with Let's Encrypt certificates
- Add HTTP to HTTPS redirect
- Configure SSL security headers and HSTS
- Add Django HTTPS security settings for production
- Fix proxy_pass to use correct port 8081
- Enhance Content Security Policy for HTTPS
2025-09-09 21:46:19 +02:00
Stiftung Development
edfb233348 Fix environment variable handling for production deployment
- Update settings.py to support both ALLOWED_HOSTS and DJANGO_ALLOWED_HOSTS
- Add production CSRF_TRUSTED_ORIGINS for vhtv-stiftung.de
- Update env-template.txt with production variable examples
- Improve compatibility between development and production environments
2025-09-09 21:02:21 +02:00
Stiftung Development
ab23d7187e feat: add comprehensive GitHub workflow and development tools 2025-09-06 18:31:54 +02:00