https://github.com/babbel/terraform-aws-athena
Terraform module creating a Glue table, an Athena workgroup and an S3 bucket for the workgroup
https://github.com/babbel/terraform-aws-athena
aws terraform terraform-module
Last synced: 11 months ago
JSON representation
Terraform module creating a Glue table, an Athena workgroup and an S3 bucket for the workgroup
- Host: GitHub
- URL: https://github.com/babbel/terraform-aws-athena
- Owner: babbel
- License: mit
- Created: 2021-03-05T15:58:51.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2024-07-11T09:59:39.000Z (almost 2 years ago)
- Last Synced: 2024-07-11T11:28:28.738Z (almost 2 years ago)
- Topics: aws, terraform, terraform-module
- Language: HCL
- Homepage: https://registry.terraform.io/modules/babbel/athena/aws
- Size: 63.5 KB
- Stars: 5
- Watchers: 42
- Forks: 6
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Athena
This module creates resources for querying with Athena.
The resources are: an Athena workgroup and an S3 bucket to keep
the workgroup's data. No table schema is created. This has to be done manually
by AWS console (cd. https://docs.aws.amazon.com/athena/latest/ug/creating-tables.html).
The bucket uses [default server-side encryption](https://docs.aws.amazon.com/AmazonS3/latest/userguide/bucket-encryption.html) with [Amazon S3-Managed Keys](https://docs.aws.amazon.com/AmazonS3/latest/userguide/serv-side-encryption.html).
For example a DML query creating a table supporting the ALB log format is
provided by [this documentation](https://docs.aws.amazon.com/athena/latest/ug/application-load-balancer-logs.html).
## Example
```tf
module "alb-athena-example" {
source = "babbel/athena/aws"
version = "~> 3.0"
name = "alb-logs-example-production"
workgroup_bucket = "athena-workgroup-alb-logs-example-production"
resource_specific_tags = {
s3_bucket = {
owner = "athena"
}
}
}
```