Commit Graph

28 Commits

Author SHA1 Message Date
Agent Zero e2b3cf081b Fix deploy.py: Worker-Deploy war kaputt
- Bug 1: WORKER_COMPOSE_YAML hatte PW Platzhalter statt echter Passwörter
- Bug 2: deploy_worker rief deploy_application auf Service-UUID auf (falsche API)
- Bug 3: verify_worker_service akzeptierte nicht running:healthy Status
- Fix: Echte Passwörter, update_service+restart statt deploy_application, Status-Check korrigiert
2026-08-02 23:57:16 +02:00
Agent Zero a922408e49 fix: add Origin header to login test in deploy.py 2026-08-01 21:23:52 +02:00
Agent Zero b3f40bacd2 fix: deploy.py rewrite — everything via Coolify API, no manual docker 2026-08-01 21:22:55 +02:00
Agent Zero 89b775b9ef fix: legacy app.tenant_id policies on _old tables + seed_admin.py rewrite
- Migration 0090: Drop legacy tenant_isolation policies on companies_old,
  company_contacts_old, contacts_old that used app.tenant_id variable.
  Create new policies using app.current_tenant_id for crm_api/crm_worker.
- seed_admin.py: Rewrite to use migration engine (crm_migration) for
  bootstrap, set tenant context, create Tenant + Role + User + UserTenant.
  No longer passes tenant_id as User parameter.

Fixes: 3 legacy app.tenant_id policies found in Gate 2 verification.
Fixes: seed_admin.py incompatible with current User model.
2026-07-31 22:23:38 +02:00
Agent Zero b3cf4474be fix: fast-deploy.sh also cleans sw.js, registerSW.js, workbox-*.js 2026-07-30 09:43:29 +02:00
Agent Zero 84aab20256 fix: fast-deploy.sh clears old assets before copying to prevent stale JS files 2026-07-30 09:38:31 +02:00
Agent Zero 8d5f272ba5 fix: deploy.py RLS exclude list reduced to 35 system tables only 2026-07-30 01:00:59 +02:00
Agent Zero 7f872b8bfc fix: deploy.py exclude system tables from RLS enforcement 2026-07-30 00:51:16 +02:00
Agent Zero 3eeeeb6173 phase10: CI erweitert (Ruff, Cross-Tenant Test, Dependency Scan, Container Smoke Test, npm ci strict) + 15 total gates 2026-07-29 23:20:03 +02:00
Agent Zero 5088b4a735 phase9: migration test script + .gitignore cleanup + CI alembic migration gate 2026-07-29 23:17:03 +02:00
Agent Zero 9bd6936d17 ci: CI/CD pipeline with 10 quality gates + Forgejo Actions workflow 2026-07-29 13:05:14 +02:00
Agent Zero 24690fb674 sprint20-23: tests + documentation + guest access + infrastructure + migrations 0059 2026-07-29 02:53:37 +02:00
Agent Zero 5378372aba security: remove hardcoded credentials from scripts and docs 2026-07-28 00:35:09 +02:00
Agent Zero 106f888cb9 feat: add fast-deploy.sh for quick frontend-only deploys (~20s) 2026-07-28 00:03:31 +02:00
Agent Zero 98eb1d0d89 feat: Plugin-System Umbau — 6 Phasen komplett abgeschlossen
Check Cross-Plugin Imports / check (push) Has been cancelled
Phase 1: Contracts konsequent nutzen
- 12 neue contracts.py erstellt (alle 19 Plugins haben jetzt contracts)
- 4 bestehende contracts.py an zentrale ContractRegistry angepasst
- Alle 19 Plugins haben on_deactivate mit Contract-Unregister
- 0 echte problematische INTER-Plugin Imports

Phase 2: Hooks/Filters-System
- app/core/hooks.py (HookRegistry mit actions + filters)
- 15 Hook-Punkte in Core-Services (contact, auth, mail, calendar, user, dms)
- BasePlugin.on_deactivate meldet alle Hooks ab

Phase 3: Plugin-Isolation
- scripts/check_cross_plugin_imports.py (Linting-Regel)
- .github/workflows/check-cross-plugin-imports.yml (CI/CD)
- .pre-commit-cross-plugin.yaml (Pre-commit Hook)
- 155 Dateien geprueft, 0 Verstoesse

Phase 4: Plugin-Versioning
- app/plugins/semver.py (SemVer mit Parse, Compare, Pre-release)
- migration_runner.py erweitert: run_migration_down, rollback_to_version
- manifest.py: min_app_version Feld
- registry.py: App-Version-Compatibility-Check bei Installation
- GET /api/v1/plugins/updates Endpoint

Phase 5: Marketplace-Vorbereitung
- app/plugins/signature.py (Ed25519 Signatur-Validierung)
- app/plugins/quarantine.py (Plugin-Quarantine mit Validierung)
- app/models/plugin_allowlist.py + Migration 0046
- manifest.py: author, license, homepage, icon, screenshots, changelog, marketplace_tags, price
- registry.py: discover_external(), discover_all()
- POST /api/v1/plugins/install-marketplace (deaktiviert)

Phase 6: Manifest-Anpassung
- manifest.py: 12 neue Felder + SemVer/Hook-Name Validierung
- MANIFEST_SCHEMA_DOC aktualisiert
- Alle 19 Plugin-Manifeste aktualisiert
- Frontend PluginUiManifest Typ erweitert

Zusaetzliche Bug-Fixes:
- test_sample-Modul erstellt
- conftest.py Deadlock-Prevention
- SESSION_COOKIE_SECURE=true
- dump.rdb aus Git entfernt + .gitignore
- backup.py datetime.utcnow -> func.now()
- system_settings.py JSONB-Import nach oben
- tax.py Mapped[float] -> Mapped[Decimal]
- notification.py type_key-Laengen vereinheitlicht

Tests: 91 neue Tests, alle bestanden
2026-07-26 23:15:34 +02:00
Agent Zero 744d595cae Fix: deploy.py DB verification accepts alembic version >= 0045 2026-07-26 22:14:47 +02:00
Agent Zero b067369651 Fix: deploy.py status check — accept finished as success 2026-07-26 00:59:10 +02:00
Agent Zero 12220cc640 Deploy: portable volume config via Coolify DB, works on any instance 2026-07-25 23:50:06 +02:00
Agent Zero 745b634e7c Deploy automation: 8-step pipeline with volume mounting, multi-container docker-compose 2026-07-25 22:48:38 +02:00
Agent Zero 20e6545aa1 Add automated deploy script with RLS, worker, health checks 2026-07-25 22:42:05 +02:00
Agent Zero 387fc9fbaa feat(7.9): add AI test runner script with unified JSON/CSV reporting 2026-07-24 01:34:34 +02:00
Agent Zero 9cfc6bf3b0 Phase 5.15: Automated backup system with pg_dump, file backup, retention, restore, notifications 2026-07-23 22:48:19 +02:00
Agent Zero 3c1b2f227b Phase 5.13: CI/CD deploy script with build/test/deploy/rollback 2026-07-23 22:39:14 +02:00
Agent Zero d9c9ba6630 Phase 5.12: API health check script for KI 2026-07-23 22:37:25 +02:00
leocrm-bot 02a0fde2e8 fix: use admin@media-on.de instead of .local (invalid TLD for email-validator) 2026-07-04 19:39:36 +02:00
leocrm-bot 5dc4d6d4c0 fix: activate plugins on startup + register routes + seed admin script
- lifespan: load active plugins from DB, call on_activate, register routes
- Fixes: Calendar/Mail/DMS/Tags/Permissions routes returning 404
- scripts/seed_admin.py: creates default tenant + admin user
2026-07-02 13:02:38 +02:00
leocrm-bot 4c7f09c518 chore: ruff lint auto-fix — 9 errors fixed (import sorting, unused imports)
- I001: import block sorting in main.py, routes/__init__.py, companies.py, conftest.py, check_indexes.py
- F401: unused imports removed (asyncio, UTC, datetime, AsyncSession)
- 6 ASYNC240/230 warnings remain (os.path.exists in async, open() in test) — minor, non-blocking
2026-07-02 00:20:15 +02:00
leocrm-bot 69e91fd5d0 T10: Monitoring, Performance, Documentation & Environment Config — 38 tests, ruff clean, docs OK
- Extended health endpoint: DB+Redis+Storage+Worker checks with degraded status
- Prometheus metrics endpoint: admin-only, text/plain format
- Metrics: http_requests_total, db_pool_connections, arq_jobs_total
- Structured JSON logging (structlog): timestamp, level, method, path, status, duration_ms, tenant_id
- Performance: page_size max 100 enforced (422), streaming CSV export (StreamingResponse)
- Scripts: seed_perf_data.py, check_indexes.py
- Docs: admin-guide.md (Deploy, Backup, Restore, Env-Vars, Troubleshooting), api-overview.md
- README updated: prod setup, API section, env profiles, admin-guide link
- .env.example: added SECRET_KEY, STORAGE_PATH, SMTP_* vars
- 38 new tests, full regression 564/564 pass (0 failures)
- Ruff: all checks passed
2026-07-01 23:15:35 +02:00