Skip to main content

access_entries

Creates, updates, deletes or gets an access_entry resource or lists access_entries in a region

Overview

Nameaccess_entries
TypeResource
DescriptionAn object representing an Amazon EKS AccessEntry.
Idawscc.eks.access_entries

Fields

NameDatatypeDescription
cluster_namestringThe cluster that the access entry is created for.
principal_arnstringThe principal ARN that the access entry is created for.
usernamestringThe Kubernetes user that the access entry is associated with.
tagsarrayAn array of key-value pairs to apply to this resource.
access_entry_arnstringThe ARN of the access entry.
kubernetes_groupsarrayThe Kubernetes groups that the access entry is associated with.
access_policiesarrayAn array of access policies that are associated with the access entry.
typestringThe node type to associate with the access entry.
regionstringAWS region.

For more information, see AWS::EKS::AccessEntry.

Methods

NameResourceAccessible byRequired Params
create_resourceaccess_entriesINSERTPrincipalArn, ClusterName, region
delete_resourceaccess_entriesDELETEIdentifier, region
update_resourceaccess_entriesUPDATEIdentifier, PatchDocument, region
list_resourcesaccess_entries_list_onlySELECTregion
get_resourceaccess_entriesSELECTIdentifier, region

SELECT examples

Gets all properties from an individual access_entry.

SELECT
region,
cluster_name,
principal_arn,
username,
tags,
access_entry_arn,
kubernetes_groups,
access_policies,
type
FROM awscc.eks.access_entries
WHERE
region = '{{ region }}' AND
Identifier = '{{ principal_arn }}|{{ cluster_name }}';

INSERT example

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

/*+ create */
INSERT INTO awscc.eks.access_entries (
ClusterName,
PrincipalArn,
region
)
SELECT
'{{ cluster_name }}',
'{{ principal_arn }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

UPDATE example

Use the following StackQL query and manifest file to update a access_entry resource, using stack-deploy.

/*+ update */
UPDATE awscc.eks.access_entries
SET PatchDocument = string('{{ {
"Username": username,
"Tags": tags,
"KubernetesGroups": kubernetes_groups,
"AccessPolicies": access_policies
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ principal_arn }}|{{ cluster_name }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

DELETE example

/*+ delete */
DELETE FROM awscc.eks.access_entries
WHERE
Identifier = '{{ principal_arn }}|{{ cluster_name }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

Additional Parameters

Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:

ParameterDescription
ClientToken
A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.
A client token is valid for 36 hours once used.
After that, a resource request with the same client token is treated as a new request.
If you do not specify a client token, one is generated for inclusion in the request.
RoleArn
The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.
If you do not specify a role, a temporary session is created using your AWS user credentials.
TypeVersionId
For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used.

Permissions

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

eks:CreateAccessEntry,
eks:DescribeAccessEntry,
eks:AssociateAccessPolicy,
eks:TagResource,
eks:ListAssociatedAccessPolicies