Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Indicates whether the specified Amazon Web Services resources are compliant. If a resource is noncompliant, this action returns the number of Config rules that the resource does not comply with.
A resource is compliant if it complies with all the Config rules that evaluate it. It is noncompliant if it does not comply with one or more of these rules.
If Config has no current evaluation results for the resource, it returns
INSUFFICIENT_DATA
. This result might indicate one of the following
conditions about the rules that evaluate the resource:
- Config has never invoked an evaluation for the rule. To check
whether it has, use the
DescribeConfigRuleEvaluationStatus
action to get theLastSuccessfulInvocationTime
andLastFailedInvocationTime
. - The rule's Lambda function is failing to send evaluation results to
Config. Verify that the role that you assigned to your configuration
recorder includes the
config:PutEvaluations
permission. If the rule is a custom rule, verify that the Lambda execution role includes theconfig:PutEvaluations
permission. - The rule's Lambda function has returned
NOT_APPLICABLE
for all evaluation results. This can occur if the resources were deleted or removed from the rule's scope.
This operation returns paginated results.
Synopsis
- data DescribeComplianceByResource = DescribeComplianceByResource' {}
- newDescribeComplianceByResource :: DescribeComplianceByResource
- describeComplianceByResource_resourceId :: Lens' DescribeComplianceByResource (Maybe Text)
- describeComplianceByResource_resourceType :: Lens' DescribeComplianceByResource (Maybe Text)
- describeComplianceByResource_complianceTypes :: Lens' DescribeComplianceByResource (Maybe [ComplianceType])
- describeComplianceByResource_nextToken :: Lens' DescribeComplianceByResource (Maybe Text)
- describeComplianceByResource_limit :: Lens' DescribeComplianceByResource (Maybe Natural)
- data DescribeComplianceByResourceResponse = DescribeComplianceByResourceResponse' {}
- newDescribeComplianceByResourceResponse :: Int -> DescribeComplianceByResourceResponse
- describeComplianceByResourceResponse_complianceByResources :: Lens' DescribeComplianceByResourceResponse (Maybe [ComplianceByResource])
- describeComplianceByResourceResponse_nextToken :: Lens' DescribeComplianceByResourceResponse (Maybe Text)
- describeComplianceByResourceResponse_httpStatus :: Lens' DescribeComplianceByResourceResponse Int
Creating a Request
data DescribeComplianceByResource Source #
See: newDescribeComplianceByResource
smart constructor.
DescribeComplianceByResource' | |
|
Instances
newDescribeComplianceByResource :: DescribeComplianceByResource Source #
Create a value of DescribeComplianceByResource
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:resourceId:DescribeComplianceByResource'
, describeComplianceByResource_resourceId
- The ID of the Amazon Web Services resource for which you want compliance
information. You can specify only one resource ID. If you specify a
resource ID, you must also specify a type for ResourceType
.
$sel:resourceType:DescribeComplianceByResource'
, describeComplianceByResource_resourceType
- The types of Amazon Web Services resources for which you want compliance
information (for example, AWS::EC2::Instance
). For this action, you
can specify that the resource type is an Amazon Web Services account by
specifying AWS::::Account
.
$sel:complianceTypes:DescribeComplianceByResource'
, describeComplianceByResource_complianceTypes
- Filters the results by compliance.
The allowed values are COMPLIANT
, NON_COMPLIANT
, and
INSUFFICIENT_DATA
.
$sel:nextToken:DescribeComplianceByResource'
, describeComplianceByResource_nextToken
- The nextToken
string returned on a previous page that you use to get
the next page of results in a paginated response.
$sel:limit:DescribeComplianceByResource'
, describeComplianceByResource_limit
- The maximum number of evaluation results returned on each page. The
default is 10. You cannot specify a number greater than 100. If you
specify 0, Config uses the default.
Request Lenses
describeComplianceByResource_resourceId :: Lens' DescribeComplianceByResource (Maybe Text) Source #
The ID of the Amazon Web Services resource for which you want compliance
information. You can specify only one resource ID. If you specify a
resource ID, you must also specify a type for ResourceType
.
describeComplianceByResource_resourceType :: Lens' DescribeComplianceByResource (Maybe Text) Source #
The types of Amazon Web Services resources for which you want compliance
information (for example, AWS::EC2::Instance
). For this action, you
can specify that the resource type is an Amazon Web Services account by
specifying AWS::::Account
.
describeComplianceByResource_complianceTypes :: Lens' DescribeComplianceByResource (Maybe [ComplianceType]) Source #
Filters the results by compliance.
The allowed values are COMPLIANT
, NON_COMPLIANT
, and
INSUFFICIENT_DATA
.
describeComplianceByResource_nextToken :: Lens' DescribeComplianceByResource (Maybe Text) Source #
The nextToken
string returned on a previous page that you use to get
the next page of results in a paginated response.
describeComplianceByResource_limit :: Lens' DescribeComplianceByResource (Maybe Natural) Source #
The maximum number of evaluation results returned on each page. The default is 10. You cannot specify a number greater than 100. If you specify 0, Config uses the default.
Destructuring the Response
data DescribeComplianceByResourceResponse Source #
See: newDescribeComplianceByResourceResponse
smart constructor.
DescribeComplianceByResourceResponse' | |
|
Instances
newDescribeComplianceByResourceResponse Source #
Create a value of DescribeComplianceByResourceResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:complianceByResources:DescribeComplianceByResourceResponse'
, describeComplianceByResourceResponse_complianceByResources
- Indicates whether the specified Amazon Web Services resource complies
with all of the Config rules that evaluate it.
$sel:nextToken:DescribeComplianceByResource'
, describeComplianceByResourceResponse_nextToken
- The string that you use in a subsequent request to get the next page of
results in a paginated response.
$sel:httpStatus:DescribeComplianceByResourceResponse'
, describeComplianceByResourceResponse_httpStatus
- The response's http status code.
Response Lenses
describeComplianceByResourceResponse_complianceByResources :: Lens' DescribeComplianceByResourceResponse (Maybe [ComplianceByResource]) Source #
Indicates whether the specified Amazon Web Services resource complies with all of the Config rules that evaluate it.
describeComplianceByResourceResponse_nextToken :: Lens' DescribeComplianceByResourceResponse (Maybe Text) Source #
The string that you use in a subsequent request to get the next page of results in a paginated response.
describeComplianceByResourceResponse_httpStatus :: Lens' DescribeComplianceByResourceResponse Int Source #
The response's http status code.