CfnDeliveryDestinationProps

class aws_cdk.aws_logs.CfnDeliveryDestinationProps(*, name, delivery_destination_policy=None, delivery_destination_type=None, destination_resource_arn=None, output_format=None, tags=None)

Bases: object

Properties for defining a CfnDeliveryDestination.

Parameters:
  • name (str) – The name of this delivery destination.

  • delivery_destination_policy (Union[IResolvable, DestinationPolicyProperty, Dict[str, Any], None]) – An IAM policy that grants permissions to CloudWatch Logs to deliver logs cross-account to a specified destination in this account. For examples of this policy, see Examples in the CloudWatch Logs API Reference.

  • delivery_destination_type (Optional[str]) – Displays whether this delivery destination is CloudWatch Logs, Amazon S3, Firehose, or X-Ray.

  • destination_resource_arn (Optional[str]) – The ARN of the AWS destination that this delivery destination represents. That AWS destination can be a log group in CloudWatch Logs , an Amazon S3 bucket, or a Firehose stream.

  • output_format (Optional[str]) – The format of the logs that are sent to this delivery destination.

  • tags (Optional[Sequence[Union[CfnTag, Dict[str, Any]]]]) – An array of key-value pairs to apply to the delivery destination. For more information, see Tag .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-logs-deliverydestination.html

ExampleMetadata:

infused

Example:

import aws_cdk.mixins_preview.aws_cloudfront.mixins as cloudfront_mixins

# Create CloudFront distribution
# origin: s3.IBucket

distribution = cloudfront.Distribution(scope, "Distribution",
    default_behavior=cloudfront.BehaviorOptions(
        origin=origins.S3BucketOrigin.with_origin_access_control(origin)
    )
)

# Create destination bucket
dest_bucket = s3.Bucket(scope, "DeliveryBucket")
# Add permissions to bucket to facilitate log delivery
bucket_policy = s3.BucketPolicy(scope, "DeliveryBucketPolicy",
    bucket=dest_bucket,
    document=iam.PolicyDocument()
)
# Create S3 delivery destination for logs
destination = logs.CfnDeliveryDestination(scope, "Destination",
    destination_resource_arn=dest_bucket.bucket_arn,
    name="unique-destination-name",
    delivery_destination_type="S3"
)

distribution.with(cloudfront_mixins.CfnDistributionLogsMixin.CONNECTION_LOGS.to_destination(destination))

Attributes

delivery_destination_policy

An IAM policy that grants permissions to CloudWatch Logs to deliver logs cross-account to a specified destination in this account.

For examples of this policy, see Examples in the CloudWatch Logs API Reference.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-logs-deliverydestination.html#cfn-logs-deliverydestination-deliverydestinationpolicy

delivery_destination_type

Displays whether this delivery destination is CloudWatch Logs, Amazon S3, Firehose, or X-Ray.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-logs-deliverydestination.html#cfn-logs-deliverydestination-deliverydestinationtype

destination_resource_arn

The ARN of the AWS destination that this delivery destination represents.

That AWS destination can be a log group in CloudWatch Logs , an Amazon S3 bucket, or a Firehose stream.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-logs-deliverydestination.html#cfn-logs-deliverydestination-destinationresourcearn

name

The name of this delivery destination.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-logs-deliverydestination.html#cfn-logs-deliverydestination-name

output_format

The format of the logs that are sent to this delivery destination.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-logs-deliverydestination.html#cfn-logs-deliverydestination-outputformat

tags

An array of key-value pairs to apply to the delivery destination.

For more information, see Tag .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-logs-deliverydestination.html#cfn-logs-deliverydestination-tags