[英]Terraform: How to set the Amazon Athena "Query result location" with Terraform
Please assist me if anybody knows how to set Athena Query result location via Terraform如果有人知道如何通过 Terraform 设置 Athena 查询结果位置,请帮助我
My code looks like below我的代码如下所示
resource "aws_athena_workgroup" "athena_query_result" {
name = var.name
configuration {
enforce_workgroup_configuration = true
publish_cloudwatch_metrics_enabled = true
result_configuration {
output_location = "s3://athena-query-location/output/"
}
}
}
You need to configure it with aws_athena_workgroup
resource您需要使用
aws_athena_workgroup
资源对其进行配置
resource "aws_athena_workgroup" "example" {
name = "example"
configuration {
enforce_workgroup_configuration = true
publish_cloudwatch_metrics_enabled = true
result_configuration {
output_location = "s3://${aws_s3_bucket.example.bucket}/output/"
encryption_configuration {
encryption_option = "SSE_KMS"
kms_key_arn = aws_kms_key.example.arn
}
}
}
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.