Skip to content

Commit 157a16c

Browse files
javbeltran_expediaclaude
andcommitted
fix: add lakeformation:GetDataAccess and iam:PassRole to lf_data_access role to fix Glue stats
The lf_data_access role was missing lakeformation:GetDataAccess and iam:PassRole policies, which are required for LakeFormation to vend temporary S3 credentials when Glue stats writes column statistics back to the catalog. These policies exist in the lakehouse module but were absent here, causing Glue stats to fail in EGDP. Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent b4eebfb commit 157a16c

2 files changed

Lines changed: 27 additions & 0 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ All notable changes to this project will be documented in this file.
33

44
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
55

6+
## [7.12.9] - 2026-04-15
7+
### Fixed
8+
- Added `lakeformation:GetDataAccess` and `iam:PassRole` (self) inline policy to `lf_data_access` role, required for LakeFormation credential vending when Glue stats writes column statistics back to the catalog.
9+
610
## [7.12.8] - 2026-04-15
711
### Added
812
- Added var `create_glue_stats_vendor_role_tbl_permissions` to create LakeFormation table permissions (`DESCRIBE`, `INSERT`, `DELETE`) for the Glue stats service role on all schemas.

lf.tf

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -444,3 +444,26 @@ resource "aws_iam_role_policy" "lf_data_access_cloudwatch" {
444444
}
445445
EOF
446446
}
447+
448+
resource "aws_iam_role_policy" "lf_data_access_pass_role" {
449+
count = var.create_lf_resource && var.create_lf_data_access_role ? 1 : 0
450+
name = "pass_role_and_lf_data_access"
451+
role = aws_iam_role.lf_data_access[0].id
452+
policy = jsonencode({
453+
Version = "2012-10-17"
454+
Statement = [
455+
{
456+
Sid = "LakeFormationDataAccess"
457+
Effect = "Allow"
458+
Action = "lakeformation:GetDataAccess"
459+
Resource = ["*"]
460+
},
461+
{
462+
Sid = "PassRole"
463+
Effect = "Allow"
464+
Action = "iam:PassRole"
465+
Resource = [aws_iam_role.lf_data_access[0].arn]
466+
}
467+
]
468+
})
469+
}

0 commit comments

Comments
 (0)