Skip to content

ministryofjustice/terraform-aws-analytical-platform-lakeformation

Repository files navigation

Analytical Platform LakeFormation Terraform Module

repo standards badge

The purpose of this Terraform Module is to simplify the sharing of Lake Formation Tables

In the Analytical Platform we use this to manage resource access for DPR and AWS QuickSight.

Terminology

The module uses the terms 'source' and 'destination' when referring to AWS Accounts which resources are shared to and from.

Requirements

Name Version
terraform ~> 1.0
aws ~> 5.0

Providers

Name Version
aws.destination ~> 5.0
aws.source ~> 5.0

Modules

No modules.

Resources

Name Type
aws_glue_catalog_database.destination_account_database_resource_link resource
aws_glue_catalog_database.destination_database resource
aws_glue_catalog_table.destination_account_table_resource_link resource
aws_lakeformation_permissions.data_location_share resource
aws_lakeformation_permissions.database_share resource
aws_lakeformation_permissions.table_share_all resource
aws_lakeformation_permissions.table_share_selected resource
aws_lakeformation_resource.data_location resource
aws_caller_identity.destination data source
aws_caller_identity.source data source
aws_region.source data source

Inputs

Name Description Type Default Required
data_locations List of data locations (currently S3 buckets) to share with destination account
list(object({
data_location = string
hybrid_mode = optional(bool, null)
register = optional(bool, null)
share = optional(bool, true)
}))
[] no
databases_to_share List of databases to share with destination account
list(object({
name = string
permissions = optional(list(string), ["DESCRIBE"])
share_all_tables = optional(bool, true),
share_all_tables_permissions = optional(list(string), ["SELECT", "DESCRIBE"])
}))
[] no
tables_to_share List of tables to share with destination account.
If the user is NOT creating a new destination_database,
(i.e. providing an existing database),
the database must exist or execution will fail silently.
list(object({
source_database = string
resource_link_table_name = optional(string, null)
destination_database = object({
database_name = string
create_database = bool
})
source_table = string
permissions = optional(list(string), ["SELECT", "DESCRIBE"])
}))
[] no

Outputs

No outputs.

About

Analytical Platform Lake Formation • This repository is defined and managed in Terraform

Topics

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Packages

No packages published

Contributors 6

Languages