A new Lambda deploy fails with "AccessDeniedException: User: arn:aws:sts::1234:assumed-role/deployer/ci is not authorized to perform: lambda:UpdateFunctionCode ... with an explicit deny in a service control policy".
IntermediateTroubleshootingCloud provider issues
Answer
Likely causes → An organization SCP denies the action, regardless of what the IAM role allows. Typical SCPs block regions outside an allow list, require specific tags, or deny changes unless done by an approved role. The message names "service control policy", so editing the role won't help.
Diagnose →
aws organizations list-policies-for-target --target-id $ACCOUNT_ID --filter SERVICE_CONTROL_POLICY
aws organizations describe-policy --policy-id p-abc123 --query 'Policy.Content' --output text | jq
Check the conditions against the request: region, role ARN pattern, tags, MFA.
Fix → Meet the policy's condition (deploy in an allowed region, use the approved role name, add required tags), or ask the platform team to adjust the SCP through their change process.
Prevent → Publish SCP guardrails and test new pipelines in a sandbox account under the same OU, so policy surprises show up before production.
More on Cloud provider issues
A deploy script and several services start failing with "An error occurred (ThrottlingException) when calling the DescribeInstances operation: Rate exceeded".BeginnerThe Auto Scaling group can't launch new instances during a traffic spike; activity history says "We currently do not have sufficient c6i.4xlarge capacity in the Availability Zone you requested."BeginnerScaling out fails with "You have requested more vCPU capacity than your current vCPU limit of 256 allows for the instance bucket that the specified instance type belongs to."BeginnerThe AWS Health Dashboard reports increased error rates in `use1-az4`, and your ALB targets in that AZ are timing out intermittently.IntermediateServices in private subnets randomly fail outbound calls to a partner API; CloudWatch shows `ErrorPortAllocation` rising on the NAT gateway.AdvancedA data pipeline writing millions of small objects to S3 starts failing with "503 Slow Down: Please reduce your request rate."Intermediate