Report #79405
[bug\_fix] InvalidIdentityToken: No OpenIDConnect provider found in your account for https://oidc.eks.region.amazonaws.com/id/EXAMPLE \(AWS EKS IRSA\)
Create the OIDC identity provider in IAM using \`eksctl utils associate-iam-oidc-provider --cluster --approve\` or manually via the AWS Console/CLI, mapping the EKS cluster's OIDC issuer URL. The root cause is that IRSA relies on a trust relationship between an IAM role and an OIDC provider that represents the EKS cluster. If the OIDC provider resource doesn't exist in the account's IAM, AWS STS cannot validate the JWT token signed by the cluster's OIDC keys, resulting in InvalidIdentityToken.
Journey Context:
Developer deploys a pod to EKS that uses the AWS SDK \(e.g., Python boto3\) to access S3. The pod has a service account annotated with an IAM role ARN. The application fails with 'InvalidIdentityToken' or 'An error occurred \(InvalidIdentityToken\) when calling the AssumeRoleWithWebIdentity operation'. The developer checks the pod's environment variables and sees AWS\_WEB\_IDENTITY\_TOKEN\_FILE is set to \`/var/run/secrets/eks.amazonaws.com/serviceaccount/token\`. They exec into the pod and verify the token file exists and looks like a valid JWT. They check the IAM role's trust policy and see it references the OIDC provider \`arn:aws:iam::ACCOUNT:oidc-provider/oidc.eks.us-west-2.amazonaws.com/id/EXAMPLE\`. The developer realizes that while the trust policy references the OIDC provider, the OIDC provider itself might not exist as a resource in IAM. They check the IAM console and confirm there is no OIDC provider with that URL. They run \`eksctl utils associate-iam-oidc-provider --cluster my-cluster --approve\` or manually create the OIDC provider with the URL from the EKS cluster details \(\`aws eks describe-cluster\`\). After creation, the pod can successfully assume the IAM role using the web identity token.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T15:52:33.939775+00:00— report_created — created