IRSA env vars are present in the pod, but one legacy service still uses the node role
IntermediateTroubleshootingCloud identity: IRSA, Workload Identity and CI OIDC
Answer
Likely causes → The service uses an old AWS SDK that predates web-identity support in the default credential chain, or the code builds credentials explicitly (for example InstanceProfileCredentialsProvider), or it runs as a user that cannot read the token file.
Diagnose →
kubectl exec deploy/legacy -- ls -l /var/run/secrets/eks.amazonaws.com/serviceaccount/token
kubectl exec deploy/legacy -- id
# check the SDK version in the dependency manifest
Fix → Upgrade the SDK and use the default provider chain. If the container runs as non-root, set securityContext.fsGroup so the token file is readable.
Prevent → Keep a minimum SDK version in your base images, and turn on IMDS blocking so fallback becomes an error.
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`BeginnerPods 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`aws-actions/configure-aws-credentials` fails with `Credentials could not be loaded, please check your action inputs: Could not load credentials from any providers`Beginner