An open API service indexing awesome lists of open source software.

https://github.com/dod-iac/terraform-aws-api-gateway-cloudwatch-role

IAM Role for use by AWS API Gateway to log to CloudWatch Logs.
https://github.com/dod-iac/terraform-aws-api-gateway-cloudwatch-role

aws cloudwatch terraform

Last synced: 9 months ago
JSON representation

IAM Role for use by AWS API Gateway to log to CloudWatch Logs.

Awesome Lists containing this project

README

          

## Usage

Creates an IAM Role for use by AWS API Gateway to log to CloudWatch Logs.

```hcl
module "api_gateway_cloudwatch_role" {
source = "dod-iac/api-gateway-cloudwatch-role/aws"

name = "api-gateway-cloudwatch-role"
tags = {
Automation = "Terraform"
}
}

resource "aws_api_gateway_account" "main" {
cloudwatch_role_arn = module.api_gateway_cloudwatch_role.arn
}
```

## Terraform Version

Terraform 0.12. Pin module version to ~> 1.0.0 . Submit pull-requests to master branch.

Terraform 0.11 is not supported.

## License

This project constitutes a work of the United States Government and is not subject to domestic copyright protection under 17 USC § 105. However, because the project utilizes code licensed from contributors and other third parties, it therefore is licensed under the MIT License. See LICENSE file for more information.

## Requirements

| Name | Version |
|------|---------|
| terraform | >= 0.13 |
| aws | ~> 3.0 |

## Providers

| Name | Version |
|------|---------|
| aws | ~> 3.0 |

## Modules

No Modules.

## Resources

| Name |
|------|
| [aws_caller_identity](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/caller_identity) |
| [aws_iam_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_policy) |
| [aws_iam_policy_document](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document) |
| [aws_iam_role](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role) |
| [aws_iam_role_policy_attachment](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role_policy_attachment) |
| [aws_partition](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/partition) |
| [aws_region](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/region) |

## Inputs

| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| name | Name of the AWS IAM Role. | `string` | `"api-gateway-cloudwatch-role"` | no |
| tags | Tags applied to the AWS IAM Role. | `map(string)` | `{}` | no |

## Outputs

| Name | Description |
|------|-------------|
| arn | The Amazon Resource Name (ARN) of the AWS IAM Role. |
| name | The name of the AWS IAM Role. |