CfnConfigurationRecorderProps Struct
Properties for defining a CfnConfigurationRecorder.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_config as config } from 'aws-cdk-lib';
const cfnConfigurationRecorderProps: config.CfnConfigurationRecorderProps = {
roleArn: 'roleArn',
// the properties below are optional
name: 'name',
recordingGroup: {
allSupported: false,
exclusionByResourceTypes: {
resourceTypes: ['resourceTypes'],
},
includeGlobalResourceTypes: false,
recordingStrategy: {
useOnly: 'useOnly',
},
resourceTypes: ['resourceTypes'],
},
recordingMode: {
recordingFrequency: 'recordingFrequency',
// the properties below are optional
recordingModeOverrides: [{
recordingFrequency: 'recordingFrequency',
resourceTypes: ['resourceTypes'],
// the properties below are optional
description: 'description',
}],
},
startedOnCreate: false,
};
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_config as config
cfn_configuration_recorder_props = config.CfnConfigurationRecorderProps(
role_arn="roleArn",
# the properties below are optional
name="name",
recording_group=config.CfnConfigurationRecorder.RecordingGroupProperty(
all_supported=False,
exclusion_by_resource_types=config.CfnConfigurationRecorder.ExclusionByResourceTypesProperty(
resource_types=["resourceTypes"]
),
include_global_resource_types=False,
recording_strategy=config.CfnConfigurationRecorder.RecordingStrategyProperty(
use_only="useOnly"
),
resource_types=["resourceTypes"]
),
recording_mode=config.CfnConfigurationRecorder.RecordingModeProperty(
recording_frequency="recordingFrequency",
# the properties below are optional
recording_mode_overrides=[config.CfnConfigurationRecorder.RecordingModeOverrideProperty(
recording_frequency="recordingFrequency",
resource_types=["resourceTypes"],
# the properties below are optional
description="description"
)]
),
started_on_create=False
)
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.config.*;
CfnConfigurationRecorderProps cfnConfigurationRecorderProps = CfnConfigurationRecorderProps.builder()
.roleArn("roleArn")
// the properties below are optional
.name("name")
.recordingGroup(RecordingGroupProperty.builder()
.allSupported(false)
.exclusionByResourceTypes(ExclusionByResourceTypesProperty.builder()
.resourceTypes(List.of("resourceTypes"))
.build())
.includeGlobalResourceTypes(false)
.recordingStrategy(RecordingStrategyProperty.builder()
.useOnly("useOnly")
.build())
.resourceTypes(List.of("resourceTypes"))
.build())
.recordingMode(RecordingModeProperty.builder()
.recordingFrequency("recordingFrequency")
// the properties below are optional
.recordingModeOverrides(List.of(RecordingModeOverrideProperty.builder()
.recordingFrequency("recordingFrequency")
.resourceTypes(List.of("resourceTypes"))
// the properties below are optional
.description("description")
.build()))
.build())
.startedOnCreate(false)
.build();
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Config;
var cfnConfigurationRecorderProps = new CfnConfigurationRecorderProps {
RoleArn = "roleArn",
// the properties below are optional
Name = "name",
RecordingGroup = new RecordingGroupProperty {
AllSupported = false,
ExclusionByResourceTypes = new ExclusionByResourceTypesProperty {
ResourceTypes = new [] { "resourceTypes" }
},
IncludeGlobalResourceTypes = false,
RecordingStrategy = new RecordingStrategyProperty {
UseOnly = "useOnly"
},
ResourceTypes = new [] { "resourceTypes" }
},
RecordingMode = new RecordingModeProperty {
RecordingFrequency = "recordingFrequency",
// the properties below are optional
RecordingModeOverrides = new [] { new RecordingModeOverrideProperty {
RecordingFrequency = "recordingFrequency",
ResourceTypes = new [] { "resourceTypes" },
// the properties below are optional
Description = "description"
} }
},
StartedOnCreate = false
};
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
cfnConfigurationRecorderProps := &CfnConfigurationRecorderProps{
RoleArn: jsii.String("roleArn"),
// the properties below are optional
Name: jsii.String("name"),
RecordingGroup: &RecordingGroupProperty{
AllSupported: jsii.Boolean(false),
ExclusionByResourceTypes: &ExclusionByResourceTypesProperty{
ResourceTypes: []*string{
jsii.String("resourceTypes"),
},
},
IncludeGlobalResourceTypes: jsii.Boolean(false),
RecordingStrategy: &RecordingStrategyProperty{
UseOnly: jsii.String("useOnly"),
},
ResourceTypes: []*string{
jsii.String("resourceTypes"),
},
},
RecordingMode: &RecordingModeProperty{
RecordingFrequency: jsii.String("recordingFrequency"),
// the properties below are optional
RecordingModeOverrides: []interface{}{
&RecordingModeOverrideProperty{
RecordingFrequency: jsii.String("recordingFrequency"),
ResourceTypes: []*string{
jsii.String("resourceTypes"),
},
// the properties below are optional
Description: jsii.String("description"),
},
},
},
StartedOnCreate: jsii.Boolean(false),
}
Properties
You cannot change the name of the configuration recorder after it has been created. To change the configuration recorder name, you must delete it and create a new configuration recorder with a new name.
recordingGroupoptionalIResolvable | CfnConfigurationRecorder.RecordingGroupPropertyrecording_groupoptionaltyping.Union[IResolvable, RecordingGroupProperty]recordingGroupoptionalIResolvableRecordingGroupoptionalIResolvableRecordingGroupoptionalinterface{}#notes
High Number of AWS Config Evaluations
You may notice increased activity in your account during your initial month recording with AWS Config when compared to subsequent months. During the initial bootstrapping process, AWS Config runs evaluations on all the resources in your account that you have selected for AWS Config to record.
If you are running ephemeral workloads, you may see increased activity from AWS Config as it records configuration changes associated with creating and deleting these temporary resources. An ephemeral workload is a temporary use of computing resources that are loaded and run when needed. Examples include Amazon Elastic Compute Cloud ( Amazon EC2 ) Spot Instances, Amazon EMR jobs, and AWS Auto Scaling . If you want to avoid the increased activity from running ephemeral workloads, you can run these types of workloads in a separate account with AWS Config turned off to avoid increased configuration recording and rule evaluations.
recordingModeoptionalIResolvable | CfnConfigurationRecorder.RecordingModePropertyrecording_modeoptionaltyping.Union[IResolvable, RecordingModeProperty]recordingModeoptionalIResolvableRecordingModeoptionalIResolvableRecordingModeoptionalinterface{}#notes
- Continuous recording allows you to record configuration changes continuously whenever a change occurs.
- Daily recording allows you to receive a configuration item (CI) representing the most recent state of your resources over the last 24-hour period, only if it’s different from the previous CI recorded.
Some resource types require continuous recording
AWS Firewall Manager depends on continuous recording to monitor your resources. If you are using Firewall Manager, it is recommended that you set the recording frequency to Continuous.
You can also override the recording frequency for specific resource types.
notes
For more information, see Permissions for the IAM Role Assigned to AWS Config in the AWS Config Developer Guide.
Pre-existing AWS Config role
If you have used an AWS service that uses AWS Config , such as AWS Security Hub CSPM or AWS Control Tower , and an AWS Config role has already been created, make sure that the IAM role that you use when setting up AWS Config keeps the same minimum permissions as the already created AWS Config role. You must do this so that the other AWS service continues to run as expected.
For example, if AWS Control Tower has an IAM role that allows AWS Config to read Amazon Simple Storage Service ( Amazon S3 ) objects, make sure that the same permissions are granted within the IAM role you use when setting up AWS Config . Otherwise, it may interfere with how AWS Control Tower operates. For more information about IAM roles for AWS Config , see Identity and Access Management for AWS Config in the AWS Config Developer Guide .
startedOnCreateoptionalboolean | IResolvablestarted_on_createoptionaltyping.Union[bool, IResolvable]startedOnCreateoptionalBooleanStartedOnCreateoptionalboolStartedOnCreateoptionalinterface{}= true#Controls whether the recorder starts recording after the create operation. Set this to 'false' for development and testing purposes.