Table: aws_wellarchitected_check_detail - Query AWS Well-Architected Tool Check Details using SQL
The AWS Well-Architected Tool is a service that helps you review the state of your workloads and compares them to the latest AWS architectural best practices. The tool generates a report detailing areas where your architecture aligns with AWS best practices, and suggests areas for improvement. The Check Details feature specifically provides more granular information about individual checks within your workload's review.
Table Usage Guide
The aws_wellarchitected_check_detail
table in Steampipe provides you with information about individual checks within a workload in AWS Well-Architected Tool. This table allows you, as a DevOps engineer, to query check-specific details, including check status, risk, reason for risk, and improvement plan. You can utilize this table to gather insights on risk management, workload optimization, and improvement planning. The schema outlines the various attributes of the check detail for you, including the workload ID, lens alias, check ID, and associated metadata.
Examples
Basic info
This query allows users to examine the details of their AWS Well-Architected Framework checks, which can provide insights into the status and configuration of their AWS workloads. This can be beneficial for maintaining best practices, identifying potential issues, and ensuring optimal performance of AWS services.
select workload_id, lens_arn, pillar_id, question_id, choice_id, id, name, description, statusfrom aws_wellarchitected_check_detail;
select workload_id, lens_arn, pillar_id, question_id, choice_id, id, name, description, statusfrom aws_wellarchitected_check_detail;
List total checks per associated status per workload
Discover the segments that contain different workloads, and understand how many checks are associated with each workload status. This can help in assessing the workload's overall health and status efficiently.
select workload_id, status, count(id) as checksfrom aws_wellarchitected_check_detailgroup by workload_id, status;
select workload_id, status, count(id) as checksfrom aws_wellarchitected_check_detailgroup by workload_id, status;
Get check details for security pillar
Explore the specifics of security checks within your AWS architecture. This can help identify areas that require improvements or adjustments to enhance overall security.
select workload_id, lens_arn, pillar_id, question_id, choice_id, id, name, description, statusfrom aws_wellarchitected_check_detailwhere pillar_id = 'security';
select workload_id, lens_arn, pillar_id, question_id, choice_id, id, name, description, statusfrom aws_wellarchitected_check_detailwhere pillar_id = 'security';
Get trusted advisor checks with errors
Identify instances where the AWS Trusted Advisor checks have resulted in errors. This can help in promptly addressing problematic areas within your AWS environment, thereby improving system performance and security.
select id, choice_id, name, pillar_id, question_id, flagged_resources, updated_atfrom aws_wellarchitected_check_detailwhere status = 'ERROR';
select id, choice_id, name, pillar_id, question_id, flagged_resources, updated_atfrom aws_wellarchitected_check_detailwhere status = 'ERROR';
Get workload details for trusted advisor checks with errors
Identify the workloads in your AWS Well-Architected Framework that have checks with errors. This can help you pinpoint areas that need attention to improve your system's reliability, performance efficiency, cost optimization, operational excellence, and security.
select w.workload_name, w.workload_id, w.environment, w.industry, w.owner, d.name as check_name, d.flagged_resources, d.pillar_idfrom aws_wellarchitected_check_detail d, aws_wellarchitected_workload wwhere d.workload_id = w.workload_id and d.status = 'ERROR';
select w.workload_name, w.workload_id, w.environment, w.industry, w.owner, d.name as check_name, d.flagged_resources, d.pillar_idfrom aws_wellarchitected_check_detail d, aws_wellarchitected_workload wwhere d.workload_id = w.workload_id and d.status = 'ERROR';
Get trusted advisor check details for well-architected lens in a particular workload
Explore the status and details of trusted advisor checks for a specific workload in the well-architected framework. This can help identify potential issues and areas for improvement in your AWS infrastructure.
select id, choice_id, name, pillar_id, question_id, flagged_resources, status, updated_atfrom aws_wellarchitected_check_detailwhere lens_arn = 'arn:aws:wellarchitected::aws:lens/wellarchitected' and workload_id = 'abcdc851ac1d8d9d5b9938615da016ce';
select id, choice_id, name, pillar_id, question_id, flagged_resources, status, updated_atfrom aws_wellarchitected_check_detailwhere lens_arn = 'arn:aws:wellarchitected::aws:lens/wellarchitected' and workload_id = 'abcdc851ac1d8d9d5b9938615da016ce';
Schema for aws_wellarchitected_check_detail
Name | Type | Operators | Description |
---|---|---|---|
_ctx | jsonb | Steampipe context in JSON form. | |
account_id | text | =, !=, ~~, ~~*, !~~, !~~* | The AWS Account ID in which the resource is located. |
choice_id | text | = | The ID of a choice. |
description | text | Trusted Advisor check description. | |
flagged_resources | bigint | Count of flagged resources associated to the check. | |
id | text | Trusted Advisor check ID. | |
lens_arn | text | = | Well-Architected Lens ARN associated to the check. |
name | text | Trusted Advisor check name. | |
owner_account_id | text | An Amazon Web Services account ID. | |
partition | text | The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov). | |
pillar_id | text | = | The ID used to identify a pillar, for example, security. A pillar is identified by its PillarReviewSummary$PillarId. |
provider | text | Provider of the check related to the best practice. | |
question_id | text | = | The ID of the question. |
reason | text | Reason associated to the check. | |
region | text | The AWS Region in which the resource is located. | |
sp_connection_name | text | =, !=, ~~, ~~*, !~~, !~~* | Steampipe connection name. |
sp_ctx | jsonb | Steampipe context in JSON form. | |
status | text | Status associated to the check. | |
title | text | Title of the resource. | |
updated_at | timestamp with time zone | The date and time recorded. | |
workload_id | text | = | The ID of the workload. |
Export
This table is available as a standalone Exporter CLI. Steampipe exporters are stand-alone binaries that allow you to extract data using Steampipe plugins without a database.
You can download the tarball for your platform from the Releases page, but it is simplest to install them with the steampipe_export_installer.sh
script:
/bin/sh -c "$(curl -fsSL https://steampipe.io/install/export.sh)" -- aws
You can pass the configuration to the command with the --config
argument:
steampipe_export_aws --config '<your_config>' aws_wellarchitected_check_detail