AWS Resource Groups – the Dashboard

Background – Life without resource groups

To manage resources well and to keep cost in check, an organization needs to keep track of every piece of its infrastructure (Configuration Item in ITIL terminology) i.e., ec2 instances, Elastic Beanstalk, S3 buckets, Relational Databases, DynamoDB, lambda functions, API gateway, OS versions, installed softwares etc. Basic requirement in this direction is to list all the resources.

Do you know AWS provides a resources dashboard off the shelf?

Yes, AWS Resource Group

Let’s see what it takes to implement.

How to mark a resource – pre-requisite

First you need to mark the resources so that you may segregate the resources based on certain criteria. There are 2 ways to create resource groups

  1. Tag based
  2. CloudFormation stack based

1. Tag based

Do you remember those innocent looking tag fields that developers generally do not fill? Oh yes, they give dimensions to a resource.

Let us assume you are developing an application for a customer whose name is “Alpha Fake Inc” and application is in “development” stage. You can use below tags on all resources belonging to customer “Alpha Fake Inc” and in development stage as

  • billing:customer -> Alpha Fake Inc
  • environment:stage -> development

 

With tags in place, you may segregate resources based on your specific business needs. Please see below some of the dimensions that organizations implement:

  • Customer – good for organizations that service B2B customers
  • Environment – e.g. Production, Development, UAT
  • Department – For organizations where each department maintains its own resources and thus costing
  • Project – For organizations that work on different projects
  • Other criteria that you may need segregation on

2. CloudFormation stack based

You might be aware of CloudFormation for seamless provisioning of your AWS resources. If not, read about CloudFormation

Our Recommendation

We recommend using CloudFormation (as far as possible) for easy provisioning of resources and tag the resources appropriately.

Thereafter, create tag-based Resource Groups for multi-dimensional querying (macro-view).

It gives little value (micro-view) to query based on CloudFormation stack.

Creating Tag based resource groups

Objective: Group the resources having same tags as input in query criteria

Steps to create tag based groups

  1. Select group type as tag based.
  2. In grouping criteria you can select either resource types based on your choice or all supported resources. In tags input box just type billing:customer and value as “Alpha Fake Inc” (copied from our example above) then click on add. You can repeat the tag step for environment stage and add it.
  3. Click on View group resources which will show you all the resources having those tags. You can also download the resource details as CSV (comma separate values) fie.
  4. You can provide group name as cust1 and description about the group.
  5. Click on create group.
  6. You have successfully created a group of resources based on tags.

Creating Cloud Formation stack based resource groups

Objective: Group the resources created by input Cloud Formation stack.

Steps to create Cloud Formation stack based groups

  1. Select group type as Cloud Formation stack based.
  2. In grouping criteria you can select your CloudFormation stack. And then you can choose resource types or select all supported resource types.
  3. Click on View group resources which will show you all the resources of the selected stack. You can also download the resource details as CSV file.
  4. Now you can provide group name as cust1-stack and description about the group.
  5. Click on create group.
  6. You have successfully created a group of resources based on CloudFormation stack.

Back to you

Do you use some best practices or would you like us to implement Resource Groups for your organization? Start the conversation.

About VisionFirst Technologies Pvt. Ltd.

We are a group of researchers and practitioners of cutting edge technology. We are AWS Registered Partner. Our tech stack includes Machine Learning, offline/2G tolerant mobile apps, web applications, IOT and Analytics.

Add a Comment

Your email address will not be published.

Related Blogs