s3-access-logs

dod-iac/s3-access-logs/aws

Terraform Module HCL AWS

Create resources to help in searching s3 access logs

Install
module "s3-access-logs" {
source = "dod-iac/s3-access-logs/aws"
version = "1.1.1"
}
plain text: /constructs/tfmod-dod-iac-s3-access-logs-aws/install.txt
⭐ Source on GitHub 📦 Registry page
README

Usage Creates athena and s3 resources to query s3 access logs S3 bucket for athena query results Athena workgroup, database, and named query to create table * Example queries for use against access logs ``hcl module "s3_access_locs" { source = "dod-iac/s3-access-logs/aws" target_bucket = "log-bucket-name" logging_bucket = "log-bucket-name" tags = { Application = var.application Environment = var.environment Automation = "Terraform" } } ` Setup After applying the resources there is one manual step. Run the create_table` named query to create the table to query against. Terraform Version Terraform 0.13. Pin module version to ~> 1.0.0 . Submit pull-requests to master branch. Terraform 0.11 and 0.12 are not supported. License This project constitutes a work of the United States Government and

Inputs (8)
NameTypeDescriptionDefault
logging_bucketstringThe S3 bucket to send logs for query results bucket required
target_bucketstringThe S3 bucket to target for s3 access logs. required
target_prefixstringThe S3 prefix to target for s3 access logs"s3"
bytes_scanned_cutoff_per_querynumberInteger for the upper data usage limit (cutoff) for the amount of bytes a single-1
database_namestringThe name of an existing database. If none exists then a new athena database will""
table_namestringThe name of an existing table. If none exists then a new athena database will be""
tagsmap(string)A mapping of tags to assign to the resources{ "Automation": "Terraform" }
projectstringUnique name for the set of logs being analyzed"s3-access-logs"
Resources (2)
aws_athena_databaseaws_athena_named_query
Details
FrameworkTerraform Module
LanguageHCL
Version1.1.1
Cloud AWS
★ Stars2
Forks3
Total downloads5.9k
Inputs8
Resources2
LicenseNOASSERTION
Namespacedod-iac
Updated