Skip to content

Commit

Permalink
Athena (#269)
Browse files Browse the repository at this point in the history
  • Loading branch information
sekka1 authored Mar 10, 2022
1 parent aae69c7 commit 85dcf97
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 0 deletions.
9 changes: 9 additions & 0 deletions terraform-modules/aws/athena/main.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
resource "aws_athena_database" "this" {
name = var.name
bucket = var.s3_bucket_name

encryption_configuration {
encryption_option = var.encryption_option
kms_key = var.kms_key
}
}
3 changes: 3 additions & 0 deletions terraform-modules/aws/athena/outputs.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
output "id" {
value = aws_athena_database.this.id
}
23 changes: 23 additions & 0 deletions terraform-modules/aws/athena/variables.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
variable "name" {
type = string
default = ""
description = "The instance name"
}

variable "s3_bucket_name" {
type = string
default = ""
description = "The S3 bucket to point Athena to"
}

variable encryption_option {
type = string
default = "SSE_S3"
description = "Encryption option"
}

variable "kms_key" {
type = string
default = null
description = "The kms key"
}

0 comments on commit 85dcf97

Please sign in to comment.