RecorderArgs

data class RecorderArgs(val name: Output<String>? = null, val recordingGroup: Output<RecorderRecordingGroupArgs>? = null, val roleArn: Output<String>? = null) : ConvertibleToJava<RecorderArgs>

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

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 role = new Role("role", RoleArgs.builder()
.assumeRolePolicy(assumeRole.applyValue(getPolicyDocumentResult -> getPolicyDocumentResult.json()))
.build());
var foo = new Recorder("foo", RecorderArgs.builder()
.roleArn(role.arn())
.build());
}
}

Import

Configuration Recorder can be imported using the name, e.g.,

$ pulumi import aws:cfg/recorder:Recorder foo example

Constructors

Link copied to clipboard
constructor(name: Output<String>? = null, recordingGroup: Output<RecorderRecordingGroupArgs>? = null, roleArn: Output<String>? = null)

Properties

Link copied to clipboard
val name: Output<String>? = null

The name of the recorder. Defaults to default. Changing it recreates the resource.

Link copied to clipboard

Recording group - see below.

Link copied to clipboard
val roleArn: Output<String>? = null

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.

Functions

Link copied to clipboard
open override fun toJava(): RecorderArgs