I am trying to automate the creation and destruction of services in AWS. the destruction is tag-based, in order to use boto3.client('elasticache').list_tags_for_resource()
I need to supply its ARN of the cache-cluster and it's not part of the describing method boto3.client('elasticache').describe_cache_clusters()
like in other resources (DynamoDB or RDS for example) is there a different way to get the ARN (except of assembling it manually) or an alternate way to iterate over the existing cache-clusters and check the tags?
Based on AWS document , You can generate ARN with a format below.
arn:aws:elasticache:region:account-id:cluster:resource-name
Example:
arn:aws:elasticache:us-west-2:0123456789:cluster:myCluster
or
arn:aws:elasticache:us-west-2:0123456789:snapshot:mySnapshot
Refer links:
https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/IAM.Overview.html
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.