aws.cfg.Recorder
Explore with Pulumi AI
Provides an AWS Config Configuration Recorder. Please note that this resource does not start the created recorder automatically.
Note: Starting the Configuration Recorder requires a delivery channel (while delivery channel creation requires Configuration Recorder). This is why
aws.cfg.RecorderStatus
is a separate resource.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const assumeRole = aws.iam.getPolicyDocument({
statements: [{
effect: "Allow",
principals: [{
type: "Service",
identifiers: ["config.amazonaws.com"],
}],
actions: ["sts:AssumeRole"],
}],
});
const r = new aws.iam.Role("r", {
name: "awsconfig-example",
assumeRolePolicy: assumeRole.then(assumeRole => assumeRole.json),
});
const foo = new aws.cfg.Recorder("foo", {
name: "example",
roleArn: r.arn,
});
import pulumi
import pulumi_aws as aws
assume_role = aws.iam.get_policy_document(statements=[{
"effect": "Allow",
"principals": [{
"type": "Service",
"identifiers": ["config.amazonaws.com"],
}],
"actions": ["sts:AssumeRole"],
}])
r = aws.iam.Role("r",
name="awsconfig-example",
assume_role_policy=assume_role.json)
foo = aws.cfg.Recorder("foo",
name="example",
role_arn=r.arn)
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/cfg"
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/iam"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
assumeRole, err := iam.GetPolicyDocument(ctx, &iam.GetPolicyDocumentArgs{
Statements: []iam.GetPolicyDocumentStatement{
{
Effect: pulumi.StringRef("Allow"),
Principals: []iam.GetPolicyDocumentStatementPrincipal{
{
Type: "Service",
Identifiers: []string{
"config.amazonaws.com",
},
},
},
Actions: []string{
"sts:AssumeRole",
},
},
},
}, nil)
if err != nil {
return err
}
r, err := iam.NewRole(ctx, "r", &iam.RoleArgs{
Name: pulumi.String("awsconfig-example"),
AssumeRolePolicy: pulumi.String(assumeRole.Json),
})
if err != nil {
return err
}
_, err = cfg.NewRecorder(ctx, "foo", &cfg.RecorderArgs{
Name: pulumi.String("example"),
RoleArn: r.Arn,
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var assumeRole = Aws.Iam.GetPolicyDocument.Invoke(new()
{
Statements = new[]
{
new Aws.Iam.Inputs.GetPolicyDocumentStatementInputArgs
{
Effect = "Allow",
Principals = new[]
{
new Aws.Iam.Inputs.GetPolicyDocumentStatementPrincipalInputArgs
{
Type = "Service",
Identifiers = new[]
{
"config.amazonaws.com",
},
},
},
Actions = new[]
{
"sts:AssumeRole",
},
},
},
});
var r = new Aws.Iam.Role("r", new()
{
Name = "awsconfig-example",
AssumeRolePolicy = assumeRole.Apply(getPolicyDocumentResult => getPolicyDocumentResult.Json),
});
var foo = new Aws.Cfg.Recorder("foo", new()
{
Name = "example",
RoleArn = r.Arn,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.iam.IamFunctions;
import com.pulumi.aws.iam.inputs.GetPolicyDocumentArgs;
import com.pulumi.aws.iam.Role;
import com.pulumi.aws.iam.RoleArgs;
import com.pulumi.aws.cfg.Recorder;
import com.pulumi.aws.cfg.RecorderArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var assumeRole = IamFunctions.getPolicyDocument(GetPolicyDocumentArgs.builder()
.statements(GetPolicyDocumentStatementArgs.builder()
.effect("Allow")
.principals(GetPolicyDocumentStatementPrincipalArgs.builder()
.type("Service")
.identifiers("config.amazonaws.com")
.build())
.actions("sts:AssumeRole")
.build())
.build());
var r = new Role("r", RoleArgs.builder()
.name("awsconfig-example")
.assumeRolePolicy(assumeRole.applyValue(getPolicyDocumentResult -> getPolicyDocumentResult.json()))
.build());
var foo = new Recorder("foo", RecorderArgs.builder()
.name("example")
.roleArn(r.arn())
.build());
}
}
resources:
foo:
type: aws:cfg:Recorder
properties:
name: example
roleArn: ${r.arn}
r:
type: aws:iam:Role
properties:
name: awsconfig-example
assumeRolePolicy: ${assumeRole.json}
variables:
assumeRole:
fn::invoke:
Function: aws:iam:getPolicyDocument
Arguments:
statements:
- effect: Allow
principals:
- type: Service
identifiers:
- config.amazonaws.com
actions:
- sts:AssumeRole
Exclude Resources Types Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const foo = new aws.cfg.Recorder("foo", {
name: "example",
roleArn: r.arn,
recordingGroup: {
allSupported: false,
exclusionByResourceTypes: [{
resourceTypes: ["AWS::EC2::Instance"],
}],
recordingStrategies: [{
useOnly: "EXCLUSION_BY_RESOURCE_TYPES",
}],
},
});
import pulumi
import pulumi_aws as aws
foo = aws.cfg.Recorder("foo",
name="example",
role_arn=r["arn"],
recording_group={
"all_supported": False,
"exclusion_by_resource_types": [{
"resource_types": ["AWS::EC2::Instance"],
}],
"recording_strategies": [{
"use_only": "EXCLUSION_BY_RESOURCE_TYPES",
}],
})
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/cfg"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := cfg.NewRecorder(ctx, "foo", &cfg.RecorderArgs{
Name: pulumi.String("example"),
RoleArn: pulumi.Any(r.Arn),
RecordingGroup: &cfg.RecorderRecordingGroupArgs{
AllSupported: pulumi.Bool(false),
ExclusionByResourceTypes: cfg.RecorderRecordingGroupExclusionByResourceTypeArray{
&cfg.RecorderRecordingGroupExclusionByResourceTypeArgs{
ResourceTypes: pulumi.StringArray{
pulumi.String("AWS::EC2::Instance"),
},
},
},
RecordingStrategies: cfg.RecorderRecordingGroupRecordingStrategyArray{
&cfg.RecorderRecordingGroupRecordingStrategyArgs{
UseOnly: pulumi.String("EXCLUSION_BY_RESOURCE_TYPES"),
},
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var foo = new Aws.Cfg.Recorder("foo", new()
{
Name = "example",
RoleArn = r.Arn,
RecordingGroup = new Aws.Cfg.Inputs.RecorderRecordingGroupArgs
{
AllSupported = false,
ExclusionByResourceTypes = new[]
{
new Aws.Cfg.Inputs.RecorderRecordingGroupExclusionByResourceTypeArgs
{
ResourceTypes = new[]
{
"AWS::EC2::Instance",
},
},
},
RecordingStrategies = new[]
{
new Aws.Cfg.Inputs.RecorderRecordingGroupRecordingStrategyArgs
{
UseOnly = "EXCLUSION_BY_RESOURCE_TYPES",
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.cfg.Recorder;
import com.pulumi.aws.cfg.RecorderArgs;
import com.pulumi.aws.cfg.inputs.RecorderRecordingGroupArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var foo = new Recorder("foo", RecorderArgs.builder()
.name("example")
.roleArn(r.arn())
.recordingGroup(RecorderRecordingGroupArgs.builder()
.allSupported(false)
.exclusionByResourceTypes(RecorderRecordingGroupExclusionByResourceTypeArgs.builder()
.resourceTypes("AWS::EC2::Instance")
.build())
.recordingStrategies(RecorderRecordingGroupRecordingStrategyArgs.builder()
.useOnly("EXCLUSION_BY_RESOURCE_TYPES")
.build())
.build())
.build());
}
}
resources:
foo:
type: aws:cfg:Recorder
properties:
name: example
roleArn: ${r.arn}
recordingGroup:
allSupported: false
exclusionByResourceTypes:
- resourceTypes:
- AWS::EC2::Instance
recordingStrategies:
- useOnly: EXCLUSION_BY_RESOURCE_TYPES
Periodic Recording
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const foo = new aws.cfg.Recorder("foo", {
name: "example",
roleArn: r.arn,
recordingGroup: {
allSupported: false,
includeGlobalResourceTypes: false,
resourceTypes: [
"AWS::EC2::Instance",
"AWS::EC2::NetworkInterface",
],
},
recordingMode: {
recordingFrequency: "CONTINUOUS",
recordingModeOverride: {
description: "Only record EC2 network interfaces daily",
resourceTypes: ["AWS::EC2::NetworkInterface"],
recordingFrequency: "DAILY",
},
},
});
import pulumi
import pulumi_aws as aws
foo = aws.cfg.Recorder("foo",
name="example",
role_arn=r["arn"],
recording_group={
"all_supported": False,
"include_global_resource_types": False,
"resource_types": [
"AWS::EC2::Instance",
"AWS::EC2::NetworkInterface",
],
},
recording_mode={
"recording_frequency": "CONTINUOUS",
"recording_mode_override": {
"description": "Only record EC2 network interfaces daily",
"resource_types": ["AWS::EC2::NetworkInterface"],
"recording_frequency": "DAILY",
},
})
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/cfg"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := cfg.NewRecorder(ctx, "foo", &cfg.RecorderArgs{
Name: pulumi.String("example"),
RoleArn: pulumi.Any(r.Arn),
RecordingGroup: &cfg.RecorderRecordingGroupArgs{
AllSupported: pulumi.Bool(false),
IncludeGlobalResourceTypes: pulumi.Bool(false),
ResourceTypes: pulumi.StringArray{
pulumi.String("AWS::EC2::Instance"),
pulumi.String("AWS::EC2::NetworkInterface"),
},
},
RecordingMode: &cfg.RecorderRecordingModeArgs{
RecordingFrequency: pulumi.String("CONTINUOUS"),
RecordingModeOverride: &cfg.RecorderRecordingModeRecordingModeOverrideArgs{
Description: pulumi.String("Only record EC2 network interfaces daily"),
ResourceTypes: pulumi.StringArray{
pulumi.String("AWS::EC2::NetworkInterface"),
},
RecordingFrequency: pulumi.String("DAILY"),
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var foo = new Aws.Cfg.Recorder("foo", new()
{
Name = "example",
RoleArn = r.Arn,
RecordingGroup = new Aws.Cfg.Inputs.RecorderRecordingGroupArgs
{
AllSupported = false,
IncludeGlobalResourceTypes = false,
ResourceTypes = new[]
{
"AWS::EC2::Instance",
"AWS::EC2::NetworkInterface",
},
},
RecordingMode = new Aws.Cfg.Inputs.RecorderRecordingModeArgs
{
RecordingFrequency = "CONTINUOUS",
RecordingModeOverride = new Aws.Cfg.Inputs.RecorderRecordingModeRecordingModeOverrideArgs
{
Description = "Only record EC2 network interfaces daily",
ResourceTypes = new[]
{
"AWS::EC2::NetworkInterface",
},
RecordingFrequency = "DAILY",
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.cfg.Recorder;
import com.pulumi.aws.cfg.RecorderArgs;
import com.pulumi.aws.cfg.inputs.RecorderRecordingGroupArgs;
import com.pulumi.aws.cfg.inputs.RecorderRecordingModeArgs;
import com.pulumi.aws.cfg.inputs.RecorderRecordingModeRecordingModeOverrideArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var foo = new Recorder("foo", RecorderArgs.builder()
.name("example")
.roleArn(r.arn())
.recordingGroup(RecorderRecordingGroupArgs.builder()
.allSupported(false)
.includeGlobalResourceTypes(false)
.resourceTypes(
"AWS::EC2::Instance",
"AWS::EC2::NetworkInterface")
.build())
.recordingMode(RecorderRecordingModeArgs.builder()
.recordingFrequency("CONTINUOUS")
.recordingModeOverride(RecorderRecordingModeRecordingModeOverrideArgs.builder()
.description("Only record EC2 network interfaces daily")
.resourceTypes("AWS::EC2::NetworkInterface")
.recordingFrequency("DAILY")
.build())
.build())
.build());
}
}
resources:
foo:
type: aws:cfg:Recorder
properties:
name: example
roleArn: ${r.arn}
recordingGroup:
allSupported: false
includeGlobalResourceTypes: false
resourceTypes:
- AWS::EC2::Instance
- AWS::EC2::NetworkInterface
recordingMode:
recordingFrequency: CONTINUOUS
recordingModeOverride:
description: Only record EC2 network interfaces daily
resourceTypes:
- AWS::EC2::NetworkInterface
recordingFrequency: DAILY
Create Recorder Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Recorder(name: string, args: RecorderArgs, opts?: CustomResourceOptions);
@overload
def Recorder(resource_name: str,
args: RecorderArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Recorder(resource_name: str,
opts: Optional[ResourceOptions] = None,
role_arn: Optional[str] = None,
name: Optional[str] = None,
recording_group: Optional[RecorderRecordingGroupArgs] = None,
recording_mode: Optional[RecorderRecordingModeArgs] = None)
func NewRecorder(ctx *Context, name string, args RecorderArgs, opts ...ResourceOption) (*Recorder, error)
public Recorder(string name, RecorderArgs args, CustomResourceOptions? opts = null)
public Recorder(String name, RecorderArgs args)
public Recorder(String name, RecorderArgs args, CustomResourceOptions options)
type: aws:cfg:Recorder
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args RecorderArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args RecorderArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args RecorderArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args RecorderArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args RecorderArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var recorderResource = new Aws.Cfg.Recorder("recorderResource", new()
{
RoleArn = "string",
Name = "string",
RecordingGroup = new Aws.Cfg.Inputs.RecorderRecordingGroupArgs
{
AllSupported = false,
ExclusionByResourceTypes = new[]
{
new Aws.Cfg.Inputs.RecorderRecordingGroupExclusionByResourceTypeArgs
{
ResourceTypes = new[]
{
"string",
},
},
},
IncludeGlobalResourceTypes = false,
RecordingStrategies = new[]
{
new Aws.Cfg.Inputs.RecorderRecordingGroupRecordingStrategyArgs
{
UseOnly = "string",
},
},
ResourceTypes = new[]
{
"string",
},
},
RecordingMode = new Aws.Cfg.Inputs.RecorderRecordingModeArgs
{
RecordingFrequency = "string",
RecordingModeOverride = new Aws.Cfg.Inputs.RecorderRecordingModeRecordingModeOverrideArgs
{
RecordingFrequency = "string",
ResourceTypes = new[]
{
"string",
},
Description = "string",
},
},
});
example, err := cfg.NewRecorder(ctx, "recorderResource", &cfg.RecorderArgs{
RoleArn: pulumi.String("string"),
Name: pulumi.String("string"),
RecordingGroup: &cfg.RecorderRecordingGroupArgs{
AllSupported: pulumi.Bool(false),
ExclusionByResourceTypes: cfg.RecorderRecordingGroupExclusionByResourceTypeArray{
&cfg.RecorderRecordingGroupExclusionByResourceTypeArgs{
ResourceTypes: pulumi.StringArray{
pulumi.String("string"),
},
},
},
IncludeGlobalResourceTypes: pulumi.Bool(false),
RecordingStrategies: cfg.RecorderRecordingGroupRecordingStrategyArray{
&cfg.RecorderRecordingGroupRecordingStrategyArgs{
UseOnly: pulumi.String("string"),
},
},
ResourceTypes: pulumi.StringArray{
pulumi.String("string"),
},
},
RecordingMode: &cfg.RecorderRecordingModeArgs{
RecordingFrequency: pulumi.String("string"),
RecordingModeOverride: &cfg.RecorderRecordingModeRecordingModeOverrideArgs{
RecordingFrequency: pulumi.String("string"),
ResourceTypes: pulumi.StringArray{
pulumi.String("string"),
},
Description: pulumi.String("string"),
},
},
})
var recorderResource = new Recorder("recorderResource", RecorderArgs.builder()
.roleArn("string")
.name("string")
.recordingGroup(RecorderRecordingGroupArgs.builder()
.allSupported(false)
.exclusionByResourceTypes(RecorderRecordingGroupExclusionByResourceTypeArgs.builder()
.resourceTypes("string")
.build())
.includeGlobalResourceTypes(false)
.recordingStrategies(RecorderRecordingGroupRecordingStrategyArgs.builder()
.useOnly("string")
.build())
.resourceTypes("string")
.build())
.recordingMode(RecorderRecordingModeArgs.builder()
.recordingFrequency("string")
.recordingModeOverride(RecorderRecordingModeRecordingModeOverrideArgs.builder()
.recordingFrequency("string")
.resourceTypes("string")
.description("string")
.build())
.build())
.build());
recorder_resource = aws.cfg.Recorder("recorderResource",
role_arn="string",
name="string",
recording_group={
"all_supported": False,
"exclusion_by_resource_types": [{
"resource_types": ["string"],
}],
"include_global_resource_types": False,
"recording_strategies": [{
"use_only": "string",
}],
"resource_types": ["string"],
},
recording_mode={
"recording_frequency": "string",
"recording_mode_override": {
"recording_frequency": "string",
"resource_types": ["string"],
"description": "string",
},
})
const recorderResource = new aws.cfg.Recorder("recorderResource", {
roleArn: "string",
name: "string",
recordingGroup: {
allSupported: false,
exclusionByResourceTypes: [{
resourceTypes: ["string"],
}],
includeGlobalResourceTypes: false,
recordingStrategies: [{
useOnly: "string",
}],
resourceTypes: ["string"],
},
recordingMode: {
recordingFrequency: "string",
recordingModeOverride: {
recordingFrequency: "string",
resourceTypes: ["string"],
description: "string",
},
},
});
type: aws:cfg:Recorder
properties:
name: string
recordingGroup:
allSupported: false
exclusionByResourceTypes:
- resourceTypes:
- string
includeGlobalResourceTypes: false
recordingStrategies:
- useOnly: string
resourceTypes:
- string
recordingMode:
recordingFrequency: string
recordingModeOverride:
description: string
recordingFrequency: string
resourceTypes:
- string
roleArn: string
Recorder Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Recorder resource accepts the following input properties:
- Role
Arn string - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- Name string
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - Recording
Group RecorderRecording Group - Recording group - see below.
- Recording
Mode RecorderRecording Mode - Recording mode - see below.
- Role
Arn string - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- Name string
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - Recording
Group RecorderRecording Group Args - Recording group - see below.
- Recording
Mode RecorderRecording Mode Args - Recording mode - see below.
- role
Arn String - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- name String
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - recording
Group RecorderRecording Group - Recording group - see below.
- recording
Mode RecorderRecording Mode - Recording mode - see below.
- role
Arn string - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- name string
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - recording
Group RecorderRecording Group - Recording group - see below.
- recording
Mode RecorderRecording Mode - Recording mode - see below.
- role_
arn str - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- name str
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - recording_
group RecorderRecording Group Args - Recording group - see below.
- recording_
mode RecorderRecording Mode Args - Recording mode - see below.
- role
Arn String - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- name String
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - recording
Group Property Map - Recording group - see below.
- recording
Mode Property Map - Recording mode - see below.
Outputs
All input properties are implicitly available as output properties. Additionally, the Recorder resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing Recorder Resource
Get an existing Recorder resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: RecorderState, opts?: CustomResourceOptions): Recorder
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
name: Optional[str] = None,
recording_group: Optional[RecorderRecordingGroupArgs] = None,
recording_mode: Optional[RecorderRecordingModeArgs] = None,
role_arn: Optional[str] = None) -> Recorder
func GetRecorder(ctx *Context, name string, id IDInput, state *RecorderState, opts ...ResourceOption) (*Recorder, error)
public static Recorder Get(string name, Input<string> id, RecorderState? state, CustomResourceOptions? opts = null)
public static Recorder get(String name, Output<String> id, RecorderState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Name string
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - Recording
Group RecorderRecording Group - Recording group - see below.
- Recording
Mode RecorderRecording Mode - Recording mode - see below.
- Role
Arn string - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- Name string
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - Recording
Group RecorderRecording Group Args - Recording group - see below.
- Recording
Mode RecorderRecording Mode Args - Recording mode - see below.
- Role
Arn string - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- name String
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - recording
Group RecorderRecording Group - Recording group - see below.
- recording
Mode RecorderRecording Mode - Recording mode - see below.
- role
Arn String - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- name string
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - recording
Group RecorderRecording Group - Recording group - see below.
- recording
Mode RecorderRecording Mode - Recording mode - see below.
- role
Arn string - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- name str
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - recording_
group RecorderRecording Group Args - Recording group - see below.
- recording_
mode RecorderRecording Mode Args - Recording mode - see below.
- role_
arn str - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
- name String
- The name of the recorder. Defaults to
default
. Changing it recreates the resource. - recording
Group Property Map - Recording group - see below.
- recording
Mode Property Map - Recording mode - see below.
- role
Arn String - Amazon Resource Name (ARN) of the IAM role. Used to make read or write requests to the delivery channel and to describe the AWS resources associated with the account. See AWS Docs for more details.
Supporting Types
RecorderRecordingGroup, RecorderRecordingGroupArgs
- All
Supported bool - Specifies whether AWS Config records configuration changes for every supported type of regional resource (which includes any new type that will become supported in the future). Conflicts with
resource_types
. Defaults totrue
. - Exclusion
By List<RecorderResource Types Recording Group Exclusion By Resource Type> - An object that specifies how AWS Config excludes resource types from being recorded by the configuration recorder.To use this option, you must set the useOnly field of RecordingStrategy to
EXCLUSION_BY_RESOURCE_TYPES
Requiresall_supported = false
. Conflicts withresource_types
. - Include
Global boolResource Types - Specifies whether AWS Config includes all supported types of global resources with the resources that it records. Requires
all_supported = true
. Conflicts withresource_types
. - Recording
Strategies List<RecorderRecording Group Recording Strategy> - Recording Strategy. Detailed below.
- Resource
Types List<string> - A list that specifies the types of AWS resources for which AWS Config records configuration changes (for example,
AWS::EC2::Instance
orAWS::CloudTrail::Trail
). See relevant part of AWS Docs for available types. In order to use this attribute,all_supported
must be set to false.
- All
Supported bool - Specifies whether AWS Config records configuration changes for every supported type of regional resource (which includes any new type that will become supported in the future). Conflicts with
resource_types
. Defaults totrue
. - Exclusion
By []RecorderResource Types Recording Group Exclusion By Resource Type - An object that specifies how AWS Config excludes resource types from being recorded by the configuration recorder.To use this option, you must set the useOnly field of RecordingStrategy to
EXCLUSION_BY_RESOURCE_TYPES
Requiresall_supported = false
. Conflicts withresource_types
. - Include
Global boolResource Types - Specifies whether AWS Config includes all supported types of global resources with the resources that it records. Requires
all_supported = true
. Conflicts withresource_types
. - Recording
Strategies []RecorderRecording Group Recording Strategy - Recording Strategy. Detailed below.
- Resource
Types []string - A list that specifies the types of AWS resources for which AWS Config records configuration changes (for example,
AWS::EC2::Instance
orAWS::CloudTrail::Trail
). See relevant part of AWS Docs for available types. In order to use this attribute,all_supported
must be set to false.
- all
Supported Boolean - Specifies whether AWS Config records configuration changes for every supported type of regional resource (which includes any new type that will become supported in the future). Conflicts with
resource_types
. Defaults totrue
. - exclusion
By List<RecorderResource Types Recording Group Exclusion By Resource Type> - An object that specifies how AWS Config excludes resource types from being recorded by the configuration recorder.To use this option, you must set the useOnly field of RecordingStrategy to
EXCLUSION_BY_RESOURCE_TYPES
Requiresall_supported = false
. Conflicts withresource_types
. - include
Global BooleanResource Types - Specifies whether AWS Config includes all supported types of global resources with the resources that it records. Requires
all_supported = true
. Conflicts withresource_types
. - recording
Strategies List<RecorderRecording Group Recording Strategy> - Recording Strategy. Detailed below.
- resource
Types List<String> - A list that specifies the types of AWS resources for which AWS Config records configuration changes (for example,
AWS::EC2::Instance
orAWS::CloudTrail::Trail
). See relevant part of AWS Docs for available types. In order to use this attribute,all_supported
must be set to false.
- all
Supported boolean - Specifies whether AWS Config records configuration changes for every supported type of regional resource (which includes any new type that will become supported in the future). Conflicts with
resource_types
. Defaults totrue
. - exclusion
By RecorderResource Types Recording Group Exclusion By Resource Type[] - An object that specifies how AWS Config excludes resource types from being recorded by the configuration recorder.To use this option, you must set the useOnly field of RecordingStrategy to
EXCLUSION_BY_RESOURCE_TYPES
Requiresall_supported = false
. Conflicts withresource_types
. - include
Global booleanResource Types - Specifies whether AWS Config includes all supported types of global resources with the resources that it records. Requires
all_supported = true
. Conflicts withresource_types
. - recording
Strategies RecorderRecording Group Recording Strategy[] - Recording Strategy. Detailed below.
- resource
Types string[] - A list that specifies the types of AWS resources for which AWS Config records configuration changes (for example,
AWS::EC2::Instance
orAWS::CloudTrail::Trail
). See relevant part of AWS Docs for available types. In order to use this attribute,all_supported
must be set to false.
- all_
supported bool - Specifies whether AWS Config records configuration changes for every supported type of regional resource (which includes any new type that will become supported in the future). Conflicts with
resource_types
. Defaults totrue
. - exclusion_
by_ Sequence[Recorderresource_ types Recording Group Exclusion By Resource Type] - An object that specifies how AWS Config excludes resource types from being recorded by the configuration recorder.To use this option, you must set the useOnly field of RecordingStrategy to
EXCLUSION_BY_RESOURCE_TYPES
Requiresall_supported = false
. Conflicts withresource_types
. - include_
global_ boolresource_ types - Specifies whether AWS Config includes all supported types of global resources with the resources that it records. Requires
all_supported = true
. Conflicts withresource_types
. - recording_
strategies Sequence[RecorderRecording Group Recording Strategy] - Recording Strategy. Detailed below.
- resource_
types Sequence[str] - A list that specifies the types of AWS resources for which AWS Config records configuration changes (for example,
AWS::EC2::Instance
orAWS::CloudTrail::Trail
). See relevant part of AWS Docs for available types. In order to use this attribute,all_supported
must be set to false.
- all
Supported Boolean - Specifies whether AWS Config records configuration changes for every supported type of regional resource (which includes any new type that will become supported in the future). Conflicts with
resource_types
. Defaults totrue
. - exclusion
By List<Property Map>Resource Types - An object that specifies how AWS Config excludes resource types from being recorded by the configuration recorder.To use this option, you must set the useOnly field of RecordingStrategy to
EXCLUSION_BY_RESOURCE_TYPES
Requiresall_supported = false
. Conflicts withresource_types
. - include
Global BooleanResource Types - Specifies whether AWS Config includes all supported types of global resources with the resources that it records. Requires
all_supported = true
. Conflicts withresource_types
. - recording
Strategies List<Property Map> - Recording Strategy. Detailed below.
- resource
Types List<String> - A list that specifies the types of AWS resources for which AWS Config records configuration changes (for example,
AWS::EC2::Instance
orAWS::CloudTrail::Trail
). See relevant part of AWS Docs for available types. In order to use this attribute,all_supported
must be set to false.
RecorderRecordingGroupExclusionByResourceType, RecorderRecordingGroupExclusionByResourceTypeArgs
- Resource
Types List<string> - A list that specifies the types of AWS resources for which AWS Config excludes records configuration changes. See relevant part of AWS Docs for available types.
- Resource
Types []string - A list that specifies the types of AWS resources for which AWS Config excludes records configuration changes. See relevant part of AWS Docs for available types.
- resource
Types List<String> - A list that specifies the types of AWS resources for which AWS Config excludes records configuration changes. See relevant part of AWS Docs for available types.
- resource
Types string[] - A list that specifies the types of AWS resources for which AWS Config excludes records configuration changes. See relevant part of AWS Docs for available types.
- resource_
types Sequence[str] - A list that specifies the types of AWS resources for which AWS Config excludes records configuration changes. See relevant part of AWS Docs for available types.
- resource
Types List<String> - A list that specifies the types of AWS resources for which AWS Config excludes records configuration changes. See relevant part of AWS Docs for available types.
RecorderRecordingGroupRecordingStrategy, RecorderRecordingGroupRecordingStrategyArgs
- Use
Only string
- Use
Only string
- use
Only String
- use
Only string
- use_
only str
- use
Only String
RecorderRecordingMode, RecorderRecordingModeArgs
- Recording
Frequency string - Default reecording frequency.
CONTINUOUS
orDAILY
. - Recording
Mode RecorderOverride Recording Mode Recording Mode Override - Recording mode overrides. Detailed below.
- Recording
Frequency string - Default reecording frequency.
CONTINUOUS
orDAILY
. - Recording
Mode RecorderOverride Recording Mode Recording Mode Override - Recording mode overrides. Detailed below.
- recording
Frequency String - Default reecording frequency.
CONTINUOUS
orDAILY
. - recording
Mode RecorderOverride Recording Mode Recording Mode Override - Recording mode overrides. Detailed below.
- recording
Frequency string - Default reecording frequency.
CONTINUOUS
orDAILY
. - recording
Mode RecorderOverride Recording Mode Recording Mode Override - Recording mode overrides. Detailed below.
- recording_
frequency str - Default reecording frequency.
CONTINUOUS
orDAILY
. - recording_
mode_ Recorderoverride Recording Mode Recording Mode Override - Recording mode overrides. Detailed below.
- recording
Frequency String - Default reecording frequency.
CONTINUOUS
orDAILY
. - recording
Mode Property MapOverride - Recording mode overrides. Detailed below.
RecorderRecordingModeRecordingModeOverride, RecorderRecordingModeRecordingModeOverrideArgs
- Recording
Frequency string - The recording frequency for the resources in the override block.
CONTINUOUS
orDAILY
. - Resource
Types List<string> - A list that specifies the types of AWS resources for which the override applies to. See restrictions in the AWS Docs
- Description string
- A description you provide of the override.
- Recording
Frequency string - The recording frequency for the resources in the override block.
CONTINUOUS
orDAILY
. - Resource
Types []string - A list that specifies the types of AWS resources for which the override applies to. See restrictions in the AWS Docs
- Description string
- A description you provide of the override.
- recording
Frequency String - The recording frequency for the resources in the override block.
CONTINUOUS
orDAILY
. - resource
Types List<String> - A list that specifies the types of AWS resources for which the override applies to. See restrictions in the AWS Docs
- description String
- A description you provide of the override.
- recording
Frequency string - The recording frequency for the resources in the override block.
CONTINUOUS
orDAILY
. - resource
Types string[] - A list that specifies the types of AWS resources for which the override applies to. See restrictions in the AWS Docs
- description string
- A description you provide of the override.
- recording_
frequency str - The recording frequency for the resources in the override block.
CONTINUOUS
orDAILY
. - resource_
types Sequence[str] - A list that specifies the types of AWS resources for which the override applies to. See restrictions in the AWS Docs
- description str
- A description you provide of the override.
- recording
Frequency String - The recording frequency for the resources in the override block.
CONTINUOUS
orDAILY
. - resource
Types List<String> - A list that specifies the types of AWS resources for which the override applies to. See restrictions in the AWS Docs
- description String
- A description you provide of the override.
Import
Using pulumi import
, import Configuration Recorder using the name. For example:
$ pulumi import aws:cfg/recorder:Recorder foo example
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.