This commit is contained in:
2026-03-04 19:33:47 +03:00
parent 42def69dcc
commit 2820e491d5
28 changed files with 972 additions and 365 deletions

View File

@@ -218,6 +218,39 @@
---
## 8) CleanReleaseConfig
**Purpose**: Декларативный конфиг `.clean-release.yaml` в корне репозитория — центральный source of truth для политики clean-валидации.
### Top-Level Fields
- `profile` (enum, required): `enterprise-clean`, `development`.
- `scan_mode` (enum, required): `repo`, `build`, `docker`.
- `prohibited_categories` (array[string], required): категории запрещённых артефактов.
- `prohibited_paths` (array[string], required): glob-паттерны запрещённых путей.
- `allowed_sources` (array[string], required): glob-паттерны допустимых endpoint'ов.
- `ignore_paths` (array[string], optional): пути, исключённые из сканирования.
- `database_cleanup` (DatabaseCleanupConfig, optional): правила очистки БД.
### DatabaseCleanupConfig (nested)
- `enabled` (boolean, required)
- `tables` (array[TableCleanupRule], required when enabled)
- `preserve` (array[string], optional): whitelist записей, защищённых от очистки.
### TableCleanupRule (nested)
- `name` (string, required): имя таблицы.
- `condition` (string, required): SQL WHERE-условие для идентификации тестовых записей.
### Validation Rules
- Для `profile=enterprise-clean` поля `prohibited_categories` и `allowed_sources` обязательны.
- При `database_cleanup.enabled=true` список `tables` не может быть пустым.
- `preserve` записи не могут пересекаться с `condition` в `tables`.
---
## Relationships
1. `ReleaseCandidate` 1—N `DistributionManifest`