Aktueller Stand
This commit is contained in:
39
README.md
39
README.md
@@ -95,8 +95,11 @@ Runs the full scan and logs what *would* happen, but **does not move/delete/unsu
|
||||
|
||||
**Unsubscribe aktiv**
|
||||
Enables `List‑Unsubscribe` handling.
|
||||
- HTTP links are called (one‑click POST when supported).
|
||||
- Mailto links are sent via SMTP (requires SMTP host + app password).
|
||||
- **Preference** is controlled by the admin setting **“Unsubscribe‑Methode bevorzugen”** (`UNSUBSCRIBE_METHOD_PREFERENCE`): `http` (default), `mailto`, or `auto`.
|
||||
- **HTTP** is tried first when preference is `http` or `auto` (one‑click POST when supported).
|
||||
- **Fallback:** if HTTP fails, the worker **automatically falls back to mailto** when available.
|
||||
- **MAILTO** sends an email via SMTP (requires SMTP host + app password).
|
||||
- If preference is `mailto`, mailto is tried first; HTTP is only attempted if no mailto target exists.
|
||||
|
||||
**Routing aktiv**
|
||||
Applies your configured rules (conditions → actions).
|
||||
@@ -172,6 +175,38 @@ Set these in `.env` before going public:
|
||||
## Environment
|
||||
All config lives in the repo root `.env` (see `.env.example`).
|
||||
|
||||
## Docker services (docker-compose)
|
||||
The stack is split into small, single-purpose services so each part can scale and restart independently:
|
||||
|
||||
- **web** (Frontend UI)
|
||||
- React + Vite single‑page app.
|
||||
- Serves the user/admin interface and talks to the API via `VITE_API_URL`.
|
||||
- In dev it runs the Vite server; in production it serves the built assets.
|
||||
|
||||
- **api** (Backend API)
|
||||
- Fastify server with auth, rules, mail account management, and job control.
|
||||
- Issues short‑lived SSE tokens and exposes the job/event endpoints.
|
||||
- Connects to Postgres for persistence and Redis for queues.
|
||||
|
||||
- **worker** (Background jobs)
|
||||
- BullMQ worker that executes cleanup jobs and export jobs.
|
||||
- Handles IMAP/Gmail processing, unsubscribe actions, and rule execution.
|
||||
- Writes progress events and updates job state in Postgres.
|
||||
|
||||
- **postgres** (Database)
|
||||
- Primary data store for users, tenants, mailboxes, rules, jobs, candidates, and settings.
|
||||
- Keeps all state so jobs can resume after restarts.
|
||||
|
||||
- **redis** (Queue & cache)
|
||||
- BullMQ queue backend for cleanup/export jobs.
|
||||
- Used for fast job coordination between API and worker.
|
||||
|
||||
How they interact:
|
||||
1. **web** calls **api** for login, rule management, and job start.
|
||||
2. **api** enqueues jobs in **redis** and persists state in **postgres**.
|
||||
3. **worker** consumes jobs from **redis**, processes mailboxes, and writes results to **postgres**.
|
||||
4. **web** streams job events from **api** (SSE) for live progress.
|
||||
|
||||
Export settings:
|
||||
- `EXPORT_DIR` (default `/tmp/mailcleaner-exports`)
|
||||
- `EXPORT_TTL_HOURS` (default `24`)
|
||||
|
||||
Reference in New Issue
Block a user