# =============================================================================
# CODEOWNERS - Code Review Requirements
# =============================================================================
# See: https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners
#
# Two review tiers:
# - Standard files: platform-team review (any developer)
# - Infrastructure/CI/deploy files: release-managers review (T5 / authorized)
#
# See docs/RELEASE_PROTOCOL.md for the full protocol.
# =============================================================================

# =============================================================================
# Default Ownership (All Files)
# =============================================================================
* @arqera/platform-team

# =============================================================================
# Infrastructure & CI/CD (Release Managers Only)
# =============================================================================
# These files affect ALL developers. Bad changes break everyone's workflow.
# Only release-managers can approve changes to these files.
/infrastructure/                    @arqera/release-managers
/.github/workflows/                 @arqera/release-managers
/.pre-commit-config.yaml            @arqera/release-managers
/scripts/hooks/                     @arqera/release-managers
/scripts/deploy-*.sh                @arqera/release-managers
/k8s/                               @arqera/release-managers
/Dockerfile*                        @arqera/release-managers
/docker-compose*.yml                @arqera/release-managers

# =============================================================================
# Core Platform Architecture
# =============================================================================
# Gravity Architecture core (structural changes need careful review)
/backend/app/core/config.py         @arqera/platform-team
/backend/app/services/*routing*.py  @arqera/platform-team
/backend/app/models/gravity*.py     @arqera/platform-team

# =============================================================================
# Security-Critical Paths
# =============================================================================
**/auth.py                          @arqera/platform-team
**/security*.py                     @arqera/platform-team
/backend/app/services/evidence*.py  @arqera/platform-team

# =============================================================================
# Data Layer (Structural Changes)
# =============================================================================
/backend/alembic/                   @arqera/platform-team
/backend/app/models/*.py            @arqera/platform-team
/backend/app/schemas/*.py           @arqera/platform-team

# =============================================================================
# Documentation & Standards
# =============================================================================
/docs/                              @arqera/platform-team
/CLAUDE.md                          @arqera/platform-team

# =============================================================================
# Sensitive Configuration (Flag on Any Change)
# =============================================================================
**/.env*                            @arqera/platform-team
**/secrets*.sh                      @arqera/platform-team
**/credential*                      @arqera/platform-team
