AwsCloudwatchLogGroupArgs

interface AwsCloudwatchLogGroupArgs extends Omit<aws.cloudwatch.LogGroupArgs, 'kmsKeyId' | 'name'> { deletionProtectionEnabled?: Input<boolean | undefined>; kmsKey?: AwsKmsKeyInput; logGroupClass?: Input<string | undefined>; name: string; namePrefix?: Input<string | undefined>; region?: Input<string | undefined>; retentionInDays?: Input<number | undefined>; skipDestroy?: Input<boolean | undefined>; tags?: Input<{ [key: string]: Input<string> } | undefined>; }

Input arguments for the CloudWatch log-group capability.

Remarks

tags are merged with default runtime tags (<namespace>:project and <namespace>:env). Caller-provided values override defaults when keys collide. When retentionInDays is omitted, it defaults to 90.

CloudWatch Logs data is encrypted at rest by AWS by default. Provide kmsKey to use a customer-managed KMS key for log-group encryption.

Example

CODE
const logGroup: AwsCloudwatchLogGroupArgs = {
  name: 'ordersApplicationLogs',
  retentionInDays: 30,
};

Hierarchy

  • LogGroupArgs, "kmsKeyId" | "name">
  • AwsCloudwatchLogGroupArgs

Properties

deletionProtectionEnabled: Input<boolean | undefined>

Inherited from deletionProtectionEnabled

Boolean to indicate whether deletion protection is enabled. Defaults to false. Once set, switching to false requires explicitly specifying false rather than removing this argument.

kmsKey: AwsKmsKeyInput

Optional customer-managed KMS key used for log-group encryption.

logGroupClass: Input<string | undefined>

Inherited from logGroupClass

Specified the log class of the log group. Possible values are: STANDARD, INFREQUENT_ACCESS, or DELIVERY.

name: string

Required log-group purpose name used as the Pulumi logical identity source.

Remarks

Must be a synchronous plain string available at preview time. The AWS provider log-group name is derived separately from this value using the AWS naming style.

namePrefix: Input<string | undefined>

Inherited from namePrefix

Creates a unique name beginning with the specified prefix. Conflicts with name.

region: Input<string | undefined>

Inherited from region

Region where this resource will be managed. Defaults to the Region set in the provider configuration.

retentionInDays: Input<number | undefined>

Inherited from retentionInDays

Specifies the number of days you want to retain log events in the specified log group. Possible values are: 1, 3, 5, 7, 14, 30, 60, 90, 120, 150, 180, 365, 400, 545, 731, 1096, 1827, 2192, 2557, 2922, 3288, 3653, and 0. If you select 0, the events in the log group are always retained and never expire. If logGroupClass is set to DELIVERY, this argument is ignored and retentionInDays is forcibly set to 2.

skipDestroy: Input<boolean | undefined>

Inherited from skipDestroy

Set to true if you do not wish the log group (and any logs it may contain) to be deleted at destroy time, and instead just remove the log group from the state.

tags: Input<{ [key: string]: Input<string> } | undefined>

Inherited from tags

A map of tags to assign to the resource. .If configured with a provider defaultTags configuration block present, tags with matching keys will overwrite those defined at the provider-level.