feat(ai): enforce single-writer automation router
All checks were successful
CD Pipeline / workflow-shape (push) Successful in 1s
CD Pipeline / cancel-stale-cd (push) Has been skipped
CD Pipeline / tests (push) Successful in 2m21s
CD Pipeline / build-and-deploy (push) Successful in 6m53s
CD Pipeline / post-deploy-checks (push) Successful in 1m55s
AWOOOI Harbor 110 Local Repair / workflow-shape (push) Successful in 0s
AWOOOI Harbor 110 Local Repair / harbor-110-local-repair (push) Successful in 49s
All checks were successful
CD Pipeline / workflow-shape (push) Successful in 1s
CD Pipeline / cancel-stale-cd (push) Has been skipped
CD Pipeline / tests (push) Successful in 2m21s
CD Pipeline / build-and-deploy (push) Successful in 6m53s
CD Pipeline / post-deploy-checks (push) Successful in 1m55s
AWOOOI Harbor 110 Local Repair / workflow-shape (push) Successful in 0s
AWOOOI Harbor 110 Local Repair / harbor-110-local-repair (push) Successful in 49s
This commit is contained in:
@@ -193,6 +193,18 @@ class ApprovalExecutionService:
|
||||
"""
|
||||
from src.services.notifications import ExecutionStatus
|
||||
|
||||
if self._is_auto_approved_request(approval):
|
||||
logger.error(
|
||||
"auto_approved_direct_execution_blocked",
|
||||
approval_id=str(getattr(approval, "id", "")),
|
||||
incident_id=getattr(approval, "incident_id", None),
|
||||
requested_by=getattr(approval, "requested_by", None),
|
||||
required_executor="awoooi-ansible-executor-broker",
|
||||
)
|
||||
raise RuntimeError(
|
||||
"auto_approved_direct_execution_disabled_use_single_writer_broker"
|
||||
)
|
||||
|
||||
logger.info(
|
||||
"background_execution_start",
|
||||
approval_id=str(approval.id),
|
||||
|
||||
Reference in New Issue
Block a user