-
Notifications
You must be signed in to change notification settings - Fork 9.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a document for aws_cloudfront_monitoring_subscription resource
- Loading branch information
1 parent
d99391f
commit 4ef8063
Showing
1 changed file
with
54 additions
and
0 deletions.
There are no files selected for viewing
54 changes: 54 additions & 0 deletions
54
website/docs/r/cloudfront_monitoring_subscription.html.markdown
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
--- | ||
subcategory: "CloudFront" | ||
layout: "aws" | ||
page_title: "AWS: aws_cloudfront_monitoring_subscription" | ||
description: |- | ||
Provides a CloudFront monitoring subscription resource. | ||
--- | ||
|
||
# Resource: aws_cloudfront_monitoring_subscription | ||
|
||
Provides a CloudFront real-time log configuration resource. | ||
|
||
## Example Usage | ||
|
||
```hcl | ||
resource "aws_cloudfront_monitoring_subscription" "example" { | ||
distribution_id = aws_cloudfront_distribution.example.id | ||
monitoring_subscription { | ||
realtime_metrics_subscription_config { | ||
realtime_metrics_subscription_status = "Enabled" | ||
} | ||
} | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
The following arguments are supported: | ||
|
||
* `distribution_id` - (Required) The ID of the distribution that you are enabling metrics for. | ||
* `monitoring_subscription` - (Required) A monitoring subscription. This structure contains information about whether additional CloudWatch metrics are enabled for a given CloudFront distribution. | ||
|
||
The `monitoring_subscription` object supports the following argument: | ||
|
||
* `realtime_metrics_subscription_config` - (Required) A subscription configuration for additional CloudWatch metrics. | ||
|
||
The `realtime_metrics_subscription_config` object supports the following argument: | ||
|
||
* `realtime_metrics_subscription_status` - (Required) A flag that indicates whether additional CloudWatch metrics are enabled for a given CloudFront distribution. Valid values are `Enabled` and `Disabled`. | ||
|
||
## Attributes Reference | ||
|
||
In addition to all arguments above, the following attributes are exported: | ||
|
||
* `id` - The ID of the CloudFront monitoring subscription, which corresponds to the `distribution_id`. | ||
|
||
## Import | ||
|
||
CloudFront monitoring subscription can be imported using the id, e.g. | ||
|
||
``` | ||
$ terraform import aws_cloudfront_monitoring_subscription.example E3QYSUHO4VYRGB | ||
``` |