amazon-eks-pod-identity-webhook icon indicating copy to clipboard operation
amazon-eks-pod-identity-webhook copied to clipboard

AWS EKS WebIdentityTokenCredentialsProvider with Fargate with Java SDK

Open ibexa-yuna opened this issue 4 years ago • 1 comments

What happened: I have created a Fargate profile for new namespace. I moved application from one (non-fargated) namespace to a new one (fargated).

When application was starting it failed with an exception: com.amazonaws.SdkClientException: Unable to load AWS credentials from any provider in the chain: [EnvironmentVariableCredentialsProvider: Unable to load AWS credentials from environment variables (AWS_ACCESS_KEY_ID (or AWS_ACCESS_KEY) and AWS_SECRET_KEY (or AWS_SECRET_ACCESS_KEY)), SystemPropertiesCredentialsProvider: Unable to load AWS credentials from Java system properties (aws.accessKeyId and aws.secretKey), **WebIdentityTokenCredentialsProvider: Unable to find a region via the region provider chain. Must provide an explicit region in the builder or setup environment to supply a region.**, com.amazonaws.auth.profile.ProfileCredentialsProvider@b1e8328: profile file cannot be null, com.amazonaws.auth.EC2ContainerCredentialsProviderWrapper@c0e821f: Failed to connect to service endpoint: ]

What you expected to happen: Application starting and not failing to get a region. Probably, webhook should provide a Fargate region, when running Pods in Fargate.

How to reproduce it (as minimally and precisely as possible):

Anything else we need to know?: Java AWS SDK version: 1.11.724

Environment:

  • AWS Region: eu-west-1
  • EKS Platform version: 1.17
  • Webhook Version: IDK

ibexa-yuna avatar Sep 16 '20 08:09 ibexa-yuna

Hi. Anyone?

ibexa-yuna avatar Sep 28 '20 11:09 ibexa-yuna