further rework to the documentation

This commit is contained in:
Codex Agent
2025-11-20 12:31:21 +01:00
parent 6afa44d947
commit 9afcaa7836
90 changed files with 1721 additions and 29 deletions

48
docs/ops/releases.md Normal file
View File

@@ -0,0 +1,48 @@
---
title: Releases & Deployments
sidebar_label: Releases & Deployments
---
Dieses Dokument beschreibt, wie Releases vorbereitet und durchgeführt werden und welche Tests aus OpsSicht Pflicht sind.
## 1. Vor dem Release
- Changelog grob durchsehen (Feature/BugfixUmfang verstehen).
- DatenbankMigrations prüfen:
- Sind `up`/`down` sauber und idempotent?
- Gibt es lange laufende Migrations (IndexBuilds)?
- KonfigÄnderungen:
- Neue ENVVariablen in `dokploy`/Compose hinterlegt?
- Secrets über SecretStore / DokployUI konfiguriert?
## 2. PflichtTests vor ProdDeploy
- **PHPUnit**:
- `php artisan test` oder mindestens relevante Suites (z.B. „Checkout“, „Storage“).
- **FrontendBuild**:
- `npm run build` (bzw. CIJob).
- **E2ESmokeTests** (siehe `docs/testing/e2e.md`):
- GuestFlow: Event beitreten, Foto hochladen, Anzeige prüfen.
- TenantFlow: Login, Event anlegen, Medienübersicht öffnen.
## 3. DeploymentAblauf (Beispiel Dokploy)
- Neues Image wird gebaut und getaggt (z.B. `fotospiel-app:2025-11-20`).
- DokployStack aktualisieren:
- AppContainer.
- Queue/HorizonContainer.
- DocsContainer (falls betroffen).
- Nach dem Deploy:
- `php artisan migrate --force`.
- Queues prüfen (`horizon:status`, `queue:failed`).
- Schnelle SmokeTests in Prod (nur lesende Aktionen oder TestTenant).
## 4. RollbackStrategie
- Vor dem Deploy aktuellen DatenbankSnapshot sicherstellen.
- Vorheriges ImageTag notieren.
- Rollback:
- Dokploy/Compose auf vorheriges Image zurückdrehen.
- Falls Migrations rückwärtskompatibel: ggf. `migrate:rollback`.
- IncidentEintrag mit Ursache und Lessons Learned ergänzen.