Skip to main content

pod_identity_associations

Creates, updates, deletes or gets a pod_identity_association resource or lists pod_identity_associations in a region

Overview

Namepod_identity_associations
TypeResource
DescriptionAn object representing an Amazon EKS PodIdentityAssociation.
Idaws.eks.pod_identity_associations

Fields

NameDatatypeDescription
cluster_namestringThe cluster that the pod identity association is created for.
role_arnstringThe IAM role ARN that the pod identity association is created for.
namespacestringThe Kubernetes namespace that the pod identity association is created for.
service_accountstringThe Kubernetes service account that the pod identity association is created for.
association_arnstringThe ARN of the pod identity association.
association_idstringThe ID of the pod identity association.
tagsarrayAn array of key-value pairs to apply to this resource.
regionstringAWS region.

Methods

NameAccessible byRequired Params
create_resourceINSERTClusterName, RoleArn, Namespace, ServiceAccount, region
delete_resourceDELETEdata__Identifier, region
update_resourceUPDATEdata__Identifier, data__PatchDocument, region
list_resourcesSELECTregion
get_resourceSELECTdata__Identifier, region

SELECT examples

Gets all pod_identity_associations in a region.

SELECT
region,
cluster_name,
role_arn,
namespace,
service_account,
association_arn,
association_id,
tags
FROM aws.eks.pod_identity_associations
WHERE region = 'us-east-1';

Gets all properties from an individual pod_identity_association.

SELECT
region,
cluster_name,
role_arn,
namespace,
service_account,
association_arn,
association_id,
tags
FROM aws.eks.pod_identity_associations
WHERE region = 'us-east-1' AND data__Identifier = '<AssociationArn>';

INSERT example

Use the following StackQL query and manifest file to create a new pod_identity_association resource, using stack-deploy.

/*+ create */
INSERT INTO aws.eks.pod_identity_associations (
ClusterName,
RoleArn,
Namespace,
ServiceAccount,
region
)
SELECT
'{{ ClusterName }}',
'{{ RoleArn }}',
'{{ Namespace }}',
'{{ ServiceAccount }}',
'{{ region }}';

DELETE example

/*+ delete */
DELETE FROM aws.eks.pod_identity_associations
WHERE data__Identifier = '<AssociationArn>'
AND region = 'us-east-1';

Permissions

To operate on the pod_identity_associations resource, the following permissions are required:

Create

eks:CreatePodIdentityAssociation,
eks:DescribePodIdentityAssociation,
eks:TagResource,
iam:PassRole,
iam:GetRole

Read

eks:DescribePodIdentityAssociation

Update

eks:DescribePodIdentityAssociation,
eks:UpdatePodIdentityAssociation,
eks:TagResource,
eks:UntagResource,
iam:PassRole,
iam:GetRole

Delete

eks:DeletePodIdentityAssociation,
eks:DescribePodIdentityAssociation

List

eks:ListPodIdentityAssociations