Track 5: Split deploy/ into target modules
Overview
deploy/ contains logic for deploying policies to multiple targets (Azure Policy,
Kubernetes OPA/Gatekeeper, etc.) in a single file. This makes it hard to add new
targets or test them in isolation.
Target Structure
deploy/
├── __init__.py (re-exports for backward compatibility)
├── azure.py (Azure Policy deployment logic)
└── kubernetes.py (Kubernetes OPA/Gatekeeper deployment logic)
Implementation Steps
- Create
src/itl_policy_builder/deploy/ as a package
- Move Azure deployment logic to
deploy/azure.py
- Move Kubernetes deployment logic to
deploy/kubernetes.py
- Update
deploy/__init__.py to re-export all public functions for backward compatibility
- Update any internal imports that reference the old module path
Acceptance Criteria
Track 5: Split deploy/ into target modules
Overview
deploy/contains logic for deploying policies to multiple targets (Azure Policy,Kubernetes OPA/Gatekeeper, etc.) in a single file. This makes it hard to add new
targets or test them in isolation.
Target Structure
Implementation Steps
src/itl_policy_builder/deploy/as a packagedeploy/azure.pydeploy/kubernetes.pydeploy/__init__.pyto re-export all public functions for backward compatibilityAcceptance Criteria
from itl_policy_builder.deploy import deploy_to_azure(and all others) still worksfrom itl_policy_builder.deploy.azure import deploy_to_azurealso worksdeploy/newplatform.pywithout touching other files