dcloud eks pod-identity-associations createLet pods of a service account act as an IAM role
IAM eks:CreatePodIdentityAssociationChanges state
Also needs iam:PassRole on the role. Pods created afterwards get AWS_ROLE_ARN, AWS_WEB_IDENTITY_TOKEN_FILE and AWS_ENDPOINT_URL_STS/S3, so AWS SDKs work unchanged. 409 when the service account already has one.
Synopsis
dcloud eks pod-identity-associations create cluster --namespace namespace --service-account serviceAccount --role roleArguments
<cluster>Requiredstring
Also accepted as
--cluster. Constraints: /^(ewk-[0-9a-f]{12}|[a-z]([a-z0-9-]{0,38}[a-z0-9])?)$/
Flags
--namespaceRequiredstring
Namespace of the service account
Constraints: /^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$/
--service-accountRequiredstring
Service account whose pods get the role
Constraints: max 253 chars, /^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$/
--roleRequiredstring
Name of the IAM role the pods act as; needs iam:PassRole on it
Constraints: 1-128 chars
Example
dcloud eks pod-identity-associations create cluster --namespace example --service-account example --role exampleGenerated from the API description, the same one the API checks requests against and the CLI is built from.