Files
archivmail/CLAUDE.md
T
sysops 1e677659b9 chore: replace AI Coding Starter Kit references with archivmail project info
- CLAUDE.md: vollständig auf archivmail-Kontext umgeschrieben (Go/Xapian Stack, On-Premise Deploy, keine Supabase/Vercel)
- package.json: name und description auf archivmail aktualisiert

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-17 09:58:41 +01:00

71 lines
2.2 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# archivmail
Selbst gehostetes Mail-Archiv-System. Go-Backend + Next.js-Frontend + PostgreSQL + Xapian.
## Tech Stack
- **Backend:** Go 1.23, CGO, Xapian (Volltext-Index)
- **Frontend:** Next.js 16 (App Router), TypeScript, Tailwind CSS, shadcn/ui
- **Datenbank:** PostgreSQL (pgx/v5)
- **Deployment:** On-Premise (192.168.1.131), Systemd
- **Auth:** JWT (httpOnly Cookie), bcrypt Cost 12
## Projektstruktur
```
cmd/archivmail/ CLI-Einstiegspunkt + Subkommandos
config/ YAML-Konfiguration
internal/
api/ HTTP-API + Handler
audit/ Audit-Log (PostgreSQL + Flat-File)
auth/ JWT-Authentifizierung
imap/ IMAP-Import, Scheduler, Store
index/ Xapian-Wrapper (CGO), Async Worker
smtpd/ Eingebetteter SMTP-Daemon
storage/ AES-256-GCM Dateispeicher + PostgreSQL-Metadaten
userstore/ Benutzerverwaltung
pkg/mailparser/ RFC-2822 Parser, MBOX-Splitter
src/
app/ Next.js Seiten (/, /search, /mail/[id], /admin, /imap)
components/ UI-Komponenten (shadcn/ui)
hooks/ useAuth
lib/ api.ts, auth-cache.ts
```
## Build & Deploy
```bash
# Backend (CGO + Xapian zwingend erforderlich)
CGO_ENABLED=1 go build -tags xapian -buildvcs=false -o archivmail ./cmd/archivmail/
# Frontend
npm run build # .next/standalone/ für Produktion
# Auf Server deployen
bash update.sh # oder: curl ... | bash
```
## Konventionen
- **Commits:** `feat(PROJ-X): ...`, `fix(PROJ-X): ...`, `chore: ...`
- **Feature-IDs:** PROJ-1, PROJ-2, … (nächste freie: PROJ-20)
- **shadcn/ui:** Keine Custom-Versionen installierter Komponenten
- **Kein Supabase, kein Vercel** reines On-Premise-Deployment
## Wichtige Konfiguration (Server)
```
/etc/archivmail/config.yml Hauptkonfiguration
/etc/archivmail/keyfile AES-256 Schlüssel (32 Bytes, nie committen)
/var/archivmail/store/ Verschlüsselter E-Mail-Speicher
/var/archivmail/xapian/ Xapian-Index
```
## Dienste (Systemd)
```bash
systemctl status archivmail # Go-Backend (Port 8080 + 2525)
systemctl status archivmail-web # Next.js-Frontend (Port 3000)
journalctl -u archivmail -f
```