Skip to main content

user_groups

Creates, updates, deletes or gets an user_group resource or lists user_groups in a region

Overview

Nameuser_groups
TypeResource
DescriptionResource Type definition for AWS::ElastiCache::UserGroup
Idaws.elasticache.user_groups

Fields

NameDatatypeDescription
statusstringIndicates user group status. Can be "creating", "active", "modifying", "deleting".
user_group_idstringThe ID of the user group.
enginestringMust be redis.
user_idsarrayList of users associated to this user group.
arnstringThe Amazon Resource Name (ARN) of the user account.
tagsarrayAn array of key-value pairs to apply to this user.
regionstringAWS region.

Methods

NameAccessible byRequired Params
create_resourceINSERTUserGroupId, Engine, UserIds, region
delete_resourceDELETEdata__Identifier, region
update_resourceUPDATEdata__Identifier, data__PatchDocument, region
list_resourcesSELECTregion
get_resourceSELECTdata__Identifier, region

SELECT examples

Gets all user_groups in a region.

SELECT
region,
status,
user_group_id,
engine,
user_ids,
arn,
tags
FROM aws.elasticache.user_groups
WHERE region = 'us-east-1';

Gets all properties from an individual user_group.

SELECT
region,
status,
user_group_id,
engine,
user_ids,
arn,
tags
FROM aws.elasticache.user_groups
WHERE region = 'us-east-1' AND data__Identifier = '<UserGroupId>';

INSERT example

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

/*+ create */
INSERT INTO aws.elasticache.user_groups (
UserGroupId,
Engine,
UserIds,
region
)
SELECT
'{{ UserGroupId }}',
'{{ Engine }}',
'{{ UserIds }}',
'{{ region }}';

DELETE example

/*+ delete */
DELETE FROM aws.elasticache.user_groups
WHERE data__Identifier = '<UserGroupId>'
AND region = 'us-east-1';

Permissions

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

Create

elasticache:CreateUserGroup,
elasticache:DescribeUserGroups,
elasticache:ListTagsForResource,
elasticache:AddTagsToResource

Read

elasticache:DescribeUserGroups,
elasticache:ListTagsForResource

Update

elasticache:ModifyUserGroup,
elasticache:DescribeUserGroups,
elasticache:ListTagsForResource,
elasticache:AddTagsToResource,
elasticache:RemoveTagsFromResource

Delete

elasticache:ModifyReplicationGroup,
elasticache:DeleteUserGroup,
elasticache:DescribeUserGroups,
elasticache:ListTagsForResource

List

elasticache:DescribeUserGroups,
elasticache:ListTagsForResource