@@ -1009,7 +1009,8 @@ The order in which Drivers MUST search for credentials is:
1009
1009
2. Environment variables
1010
1010
3. A custom AWS credential provider if the driver supports it.
1011
1011
4. Using ` AssumeRoleWithWebIdentity` if ` AWS_WEB_IDENTITY_TOKEN_FILE` and ` AWS_ROLE_ARN` are set.
1012
- 5. The ECS endpoint if ` AWS_CONTAINER_CREDENTIALS_RELATIVE_URI` is set . Otherwise , the EC2 endpoint.
1012
+ 5. The EKS endpoint if ` AWS_CONTAINER_CREDENTIALS_FULL_URI` and ` AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE` are set.
1013
+ 6. The ECS endpoint if ` AWS_CONTAINER_CREDENTIALS_RELATIVE_URI` is set . Otherwise , the EC2 endpoint.
1013
1014
1014
1015
> [! NOTE ]
1015
1016
> See * Should drivers support accessing Amazon EC2 instance metadata in Amazon ECS * in [Q & A ](#q- and- a)
@@ -1099,6 +1100,33 @@ The JSON response from the STS endpoint will contain credentials in this format:
1099
1100
1100
1101
Note that the token is called ` SessionToken` and not ` Token` as it would be with other credential responses.
1101
1102
1103
+ ##### EKS endpoint
1104
+
1105
+ If a username and password are not provided and the aforementioned environment variables are not set and
1106
+ ` AWS_CONTAINER_CREDENTIALS_FULL_URI` and ` AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE` are set, then drivers MUST use the
1107
+ Amazon EKS Pod Identity endpoint to get the credentials . Drivers SHOULD enforce a 10 second read timeout while waiting
1108
+ for incoming content.
1109
+
1110
+ The " Authorization" header value for the request is obtained by reading the contents of the file given by
1111
+ ` AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE` .
1112
+
1113
+ Querying the URI will return the JSON response:
1114
+
1115
+ ` ` ` javascript
1116
+ {
1117
+ "AccessKeyId": <access_key>,
1118
+ "Expiration": <date>,
1119
+ "SecretAccessKey": <secret_access_key>,
1120
+ "Token": <security_token>
1121
+ "AccountId": <aws_account_id>
1122
+ }
1123
+ ` ` `
1124
+
1125
+ ` ` ` bash
1126
+ $ TOKEN=$(cat $AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE)
1127
+ $ curl -H Authorization:$TOKEN $AWS_CONTAINER_CREDENTIALS_FULL_URI
1128
+ ` ` `
1129
+
1102
1130
##### ECS endpoint
1103
1131
1104
1132
If a username and password are not provided and the aforementioned environment variables are not set, drivers MUST query
0 commit comments