`azure/login` in GitHub Actions fails with `AADSTS700213: No matching federated identity record found for presented assertion subject 'repo:acme/api:environment:prod'`
BeginnerTroubleshootingCloud identity: IRSA, Workload Identity and CI OIDC
Answer
Likely causes → The federated credential on the app registration or managed identity was created for "Branch: main" (repo:acme/api:ref:refs/heads/main), but the job runs with environment: prod, which changes the subject.
Diagnose → Compare the error's subject with az ad app federated-credential list --id <app-id>.
Fix → Add a federated credential with subject repo:acme/api:environment:prod, and keep permissions: id-token: write on the job.
Prevent → Document the subject format per job type in your CI template and create the credentials from it.
More on Cloud identity: IRSA, Workload Identity and CI OIDC
A pod configured for IRSA runs `aws sts get-caller-identity` and gets the node role (`eks-node-group-role`) instead of its own roleBeginner`An error occurred (AccessDenied) when calling the AssumeRoleWithWebIdentity operation: Not authorized to perform sts:AssumeRoleWithWebIdentity` from an IRSA podIntermediate`InvalidIdentityToken: No OpenIDConnect provider found in your account for https://oidc.eks.ap-south-1.amazonaws.com/id/ABC123`BeginnerIRSA env vars are present in the pod, but one legacy service still uses the node roleIntermediatePods without IRSA can still call AWS with the node's permissions through `169.254.169.254`IntermediateWith EKS Pod Identity, the pod gets `Unable to locate credentials` even though a pod identity association existsIntermediate