Amazon EC2 또는 Amazon에 대한 EMR 스튜디오 사용자 권한 구성 EKS - 아마존 EMR

기계 번역으로 제공되는 번역입니다. 제공된 번역과 원본 영어의 내용이 상충하는 경우에는 영어 버전이 우선합니다.

Amazon EC2 또는 Amazon에 대한 EMR 스튜디오 사용자 권한 구성 EKS

세분화된 사용자 및 그룹 권한을 설정할 수 있도록 Amazon EMR Studio에 대한 사용자 권한 정책을 구성해야 합니다. EMRStudio에서 사용자 권한이 작동하는 방식에 대한 자세한 내용은 을 참조하십시오. 액세스 제어 Amazon EMR Studio 작동 방식

참고

이 섹션에서 다루는 권한은 데이터 액세스 제어를 적용하지 않습니다. 입력 데이터 세트에 대한 액세스를 관리하려면 Studio에서 사용하는 클러스터에 대한 권한을 구성해야 합니다. 자세한 내용은 아마존의 보안 EMR 단원을 참조하십시오.

IAMID 센터 인증 모드를 위한 EMR Studio 사용자 역할을 생성하십시오.

IAMID 센터 인증 모드를 사용할 때는 EMR Studio 사용자 역할을 생성해야 합니다.

EMRStudio의 사용자 역할을 만들려면
  1. 사용 설명서의 AWS 서비스에 권한을 위임할 역할 만들기의 지침에 따라AWS Identity and Access Management 사용자 역할을 생성하십시오.

    역할을 생성할 때 다음과 같은 신뢰 관계 정책을 사용합니다.

    { "Version": "2008-10-17", "Statement": [ { "Effect": "Allow", "Principal": { "Service": "elasticmapreduce.amazonaws.com" }, "Action": [ "sts:AssumeRole", "sts:SetContext" ] } ] }
  2. 기본 역할 권한 및 정책을 제거합니다.

  3. Studio에 사용자와 그룹을 할당하기 전에 EMR Studio 세션 정책을 사용자 역할에 연결하십시오. 세션 정책을 작성하는 방법에 대한 지침은 EMRStudio 사용자를 위한 권한 정책을 생성하십시오. 섹션을 참조하세요.

EMRStudio 사용자를 위한 권한 정책을 생성하십시오.

EMRStudio에 대한 권한 정책을 만들려면 다음 섹션을 참조하십시오.

참고

노트북 파일 저장을 위한 Amazon S3 액세스 권한을 설정하고 Workspaces를 Git 리포지토리에 연결할 때 암호 읽기에 대한 AWS Secrets Manager 액세스 권한을 설정하려면 Studio 서비스 역할을 사용하십시오EMR.

권한 정책 생성

Studio에서 사용자가 수행할 수 있는 작업을 지정하는 IAM 권한 정책을 하나 이상 생성하십시오. 예를 들어 이 페이지의 예제 정책을 사용하여 기본, 중급고급 Studio 사용자 유형을 위한 세 가지 개별 정책을 생성할 수 있습니다.

사용자가 수행할 수 있는 각 Studio 작업의 분류 및 각 IAM 작업을 수행하는 데 필요한 최소 작업은 을 참조하십시오AWS Identity and Access Management EMRStudio 사용자의 권한. 정책을 생성하는 단계는 IAM사용 설명서의 IAM정책 생성을 참조하십시오.

권한 정책에 다음 명령문이 포함되어야 합니다.

{ "Sid": "AllowAddingTagsOnSecretsWithEMRStudioPrefix", "Effect": "Allow", "Action": "secretsmanager:TagResource", "Resource": "arn:aws:secretsmanager:*:*:secret:emr-studio-*" }, { "Sid": "AllowPassingServiceRoleForWorkspaceCreation", "Action": "iam:PassRole", "Resource": [ "arn:aws:iam::*:role/your-emr-studio-service-role" ], "Effect": "Allow" }

Workspace 협업에 대한 소유권 설정

Workspace 협업을 사용하면 여러 사용자가 동일한 Workspace에서 동시에 작업할 수 있으며 Workspace UI의 협업 패널로 구성할 수 있습니다. 협업 패널을 보고 사용하려면 사용자에게 다음 권한이 있어야 합니다. 이 권한이 있는 모든 사용자는 협업 패널을 보고 사용할 수 있습니다.

"elasticmapreduce:UpdateEditor", "elasticmapreduce:PutWorkspaceAccess", "elasticmapreduce:DeleteWorkspaceAccess", "elasticmapreduce:ListWorkspaceAccessIdentities"

협업 패널에 대한 액세스를 제한하기 위해 태그 기반 액세스 제어를 사용할 수 있습니다. 사용자가 작업 영역을 만들면 EMR Studio는 작업 영역을 만드는 사용자의 ID가 creatorUserId 값인 키와 함께 기본 태그를 적용합니다.

참고

EMRStudio는 2021년 11월 16일 이후에 생성된 작업 영역에 creatorUserId 태그를 추가합니다. 이 날짜 이전에 생성한 작업 영역에 대해 협업을 구성할 수 있는 사용자를 제한하려면 Workspace에 creatorUserId 태그를 수동으로 추가한 다음, 사용자 권한 정책에서 태그 기반 액세스 제어를 사용하는 것이 좋습니다.

다음 예제 명령문을 사용하면 값이 사용자 ID(aws:userId 정책 변수로 표시됨)와 일치하는 creatorUserId 태그 키를 포함하는 모든 Workspace에 대해 협업을 구성할 수 있습니다. 즉, 이 명령문을 통해 사용자가 생성한 Workspace에 대해 협업을 구성할 수 있습니다. 정책 변수에 대해 자세히 알아보려면 IAM사용 설명서의 IAM 정책 요소: 변수 및 태그를 참조하십시오.

{ "Sid": "UserRolePermissionsForCollaboration", "Action": [ "elasticmapreduce:UpdateEditor", "elasticmapreduce:PutWorkspaceAccess", "elasticmapreduce:DeleteWorkspaceAccess", "elasticmapreduce:ListWorkspaceAccessIdentities" ], "Resource": "*", "Effect": "Allow", "Condition": { "StringEquals": { "elasticmapreduce:ResourceTag/creatorUserId": "${aws:userid}" } } }

사용자 수준 Git 암호 정책 생성

사용자 수준 권한을 사용하는 방법

EMRStudio는 Git 시크릿을 생성할 때 for-use-with-amazon-emr-managed-user-policies 태그를 자동으로 추가합니다. 사용자 수준에서 Git 암호에 대한 액세스를 제어하려면 아래 섹션과 secretsmanager:GetSecretValue 같이 EMR Studio 사용자 역할 정책에 태그 기반 권한을 추가하세요. 서비스 수준 권한에서 사용자 수준 권한으로 전환하는 방법

EMRStudio 서비스 역할 정책에 대한 기존 권한이 secretsmanager:GetSecretValue 있는 경우 해당 권한을 제거해야 합니다.

서비스 수준 권한에서 사용자 수준 권한으로 전환하는 방법

참고

for-use-with-amazon-emr-managed-user-policies 태그는 아래 1단계의 권한이 작업 영역 생성자에게 Git 암호에 대한 액세스 권한을 부여하도록 합니다. 하지만 2023년 9월 1일 이전에 Git 리포지토리를 연결했다면, 해당 Git 암호에 for-use-with-amazon-emr-managed-user-policies 태그가 적용되지 않아 이 암호의 액세스가 거부됩니다. 사용자 수준 권한을 적용하려면 적절한 Git 리포지토리에서 JupyterLab 이전 암호를 다시 만들고 해당 Git 리포지토리에 다시 연결해야 합니다.

정책 변수에 대한 자세한 내용은 사용 설명서의 IAM정책 요소: 변수 및 태그를 참조하십시오. IAM

  1. EMRStudio 사용자 역할 정책에 다음 권한을 추가하십시오. "${aws:userid}" 값이 있는 for-use-with-amazon-emr-managed-user-policies 키를 사용합니다.

    { "Sid": "AllowSecretsManagerReadOnlyActionsWithEMRTags", "Effect": "Allow", "Action": "secretsmanager:GetSecretValue", "Resource": "arn:aws:secretsmanager:*:*:secret:*", "Condition": { "StringEquals": { "secretsmanager:ResourceTag/for-use-with-amazon-emr-managed-user-policies": "${aws:userid}" } } }
  2. 있는 경우 EMRStudio 서비스 역할 정책에서 다음 권한을 제거하십시오. 서비스 역할 정책은 각 사용자가 정의한 모든 암호에 적용되기 때문에 이 작업은 한 번만 수행하면 됩니다.

    { "Sid": "AllowSecretsManagerReadOnlyActionsWithEMRTags", "Effect": "Allow", "Action": [ "secretsmanager:GetSecretValue" ], "Resource": "arn:aws:secretsmanager:*:*:secret:*", "Condition": { "StringEquals": { "aws:ResourceTag/for-use-with-amazon-emr-managed-policies": "true" } } }

서비스 수준 권한을 사용하는 방법

2023년 9월 1일부터 EMR Studio는 사용자 수준 액세스 제어를 위한 for-use-with-amazon-emr-managed-user-policies 태그를 자동으로 추가합니다. 이 기능은 추가되었으므로 EMRStudio 서비스 역할의 GetSecretValue 권한을 통해 제공되는 서비스 수준 액세스를 계속 사용할 수 있습니다.

2023년 9월 1일 이전에 생성된 비밀의 경우 EMR Studio는 태그를 추가하지 않았습니다. for-use-with-amazon-emr-managed-user-policies 서비스 수준 권한을 계속 사용하려면 기존 EMRStudio 서비스 역할 및 사용자 역할 권한을 유지하기만 하면 됩니다. 단, 개별 암호에 액세스할 수 있는 사용자를 제한하기 위해서는 사용자 수준 권한을 사용하는 방법의 단계에 따라 암호에 for-use-with-amazon-emr-managed-user-policies 태그를 수동으로 추가한 후, 해당 사용자 권한 정책의 태그 기반 액세스 제어를 사용할 것을 권장합니다.

정책 변수에 대한 자세한 내용은 IAM사용 설명서의 IAM 정책 요소: 변수 및 태그를 참조하십시오.

권한 정책을 IAM ID에 연결하십시오.

다음 표에는 EMR Studio 인증 모드에 따라 권한 정책을 연결하는 IAM ID가 요약되어 있습니다. 정책을 연결하는 방법에 대한 지침은 IAMID 권한 추가 및 제거를 참조하십시오.

사용하는 항목 정책을 연결하는 대상...
IAM인증 IAMID (사용자, 사용자 그룹 또는 역할) 예를 들어 AWS 계정의 사용자에게 권한 정책을 연결할 수 있습니다.
IAM외부 ID 공급자 (IdP) 와의 페더레이션

외부 IdP에 대해 생성한 IAM 역할 또는 역할. IAMSAML2.0용 페더레이션을 예로 들 수 있습니다.

EMRStudio는 Studio에 대한 페더레이션 액세스 권한을 가진 사용자의 IAM 역할에 연결하는 권한을 사용합니다.

IAM아이덴티티 센터 Amazon EMR 스튜디오 사용자 역할.

사용자 정책 예제

다음 기본 사용자 정책은 대부분의 EMR Studio 작업을 허용하지만 사용자가 새 Amazon EMR 클러스터를 생성할 수는 없습니다.

중요

예제 정책에는 IAM 인증 모드를 사용할 때 사용자에게 허용해야 하는 CreateStudioPresignedUrl 권한이 포함되어 있지 않습니다. 자세한 내용은 EMR스튜디오에 사용자 또는 그룹 배정 단원을 참조하십시오.

예제 정책에는 태그 기반 액세스 제어 (TBAC) 를 적용하는 Condition 요소가 포함되어 있으므로 Studio의 예제 서비스 역할과 함께 정책을 사용할 수 있습니다. EMR 자세한 내용은 EMRStudio 서비스 역할을 생성하십시오. 단원을 참조하십시오.

{ "Version":"2012-10-17", "Statement":[ { "Sid":"AllowDefaultEC2SecurityGroupsCreationInVPCWithEMRTags", "Effect":"Allow", "Action":[ "ec2:CreateSecurityGroup" ], "Resource":[ "arn:aws:ec2:*:*:vpc/*" ], "Condition":{ "StringEquals":{ "aws:ResourceTag/for-use-with-amazon-emr-managed-policies":"true" } } }, { "Sid":"AllowAddingEMRTagsDuringDefaultSecurityGroupCreation", "Effect":"Allow", "Action":[ "ec2:CreateTags" ], "Resource":"arn:aws:ec2:*:*:security-group/*", "Condition":{ "StringEquals":{ "aws:RequestTag/for-use-with-amazon-emr-managed-policies":"true", "ec2:CreateAction":"CreateSecurityGroup" } } }, { "Sid":"AllowSecretManagerListSecrets", "Action":[ "secretsmanager:ListSecrets" ], "Resource":"*", "Effect":"Allow" }, { "Sid":"AllowSecretCreationWithEMRTagsAndEMRStudioPrefix", "Effect":"Allow", "Action":"secretsmanager:CreateSecret", "Resource":"arn:aws:secretsmanager:*:*:secret:emr-studio-*", "Condition":{ "StringEquals":{ "aws:RequestTag/for-use-with-amazon-emr-managed-policies":"true" } } }, { "Sid":"AllowAddingTagsOnSecretsWithEMRStudioPrefix", "Effect":"Allow", "Action":"secretsmanager:TagResource", "Resource":"arn:aws:secretsmanager:*:*:secret:emr-studio-*" }, { "Sid":"AllowPassingServiceRoleForWorkspaceCreation", "Action":"iam:PassRole", "Resource":[ "arn:aws:iam::*:role/<your-emr-studio-service-role>" ], "Effect":"Allow" }, { "Sid":"AllowS3ListAndLocationPermissions", "Action":[ "s3:ListAllMyBuckets", "s3:ListBucket", "s3:GetBucketLocation" ], "Resource":"arn:aws:s3:::*", "Effect":"Allow" }, { "Sid":"AllowS3ReadOnlyAccessToLogs", "Action":[ "s3:GetObject" ], "Resource":[ "arn:aws:s3:::aws-logs-<aws-account-id>-<region>/elasticmapreduce/*" ], "Effect":"Allow" }, { "Sid":"AllowConfigurationForWorkspaceCollaboration", "Action":[ "elasticmapreduce:UpdateEditor", "elasticmapreduce:PutWorkspaceAccess", "elasticmapreduce:DeleteWorkspaceAccess", "elasticmapreduce:ListWorkspaceAccessIdentities" ], "Resource":"*", "Effect":"Allow", "Condition":{ "StringEquals":{ "elasticmapreduce:ResourceTag/creatorUserId":"${aws:userId}" } } }, { "Sid":"DescribeNetwork", "Effect":"Allow", "Action":[ "ec2:DescribeVpcs", "ec2:DescribeSubnets", "ec2:DescribeSecurityGroups" ], "Resource":"*" }, { "Sid":"ListIAMRoles", "Effect":"Allow", "Action":[ "iam:ListRoles" ], "Resource":"*" } ] }

다음 중간 사용자 정책은 대부분의 EMR Studio 작업을 허용하고 사용자가 클러스터 템플릿을 사용하여 새 Amazon EMR 클러스터를 생성할 수 있도록 합니다.

중요

예제 정책에는 IAM 인증 모드를 사용할 때 사용자에게 허용해야 하는 CreateStudioPresignedUrl 권한이 포함되어 있지 않습니다. 자세한 내용은 EMR스튜디오에 사용자 또는 그룹 배정 단원을 참조하십시오.

예제 정책에는 태그 기반 액세스 제어 (TBAC) 를 적용하는 Condition 요소가 포함되어 있으므로 Studio의 예제 서비스 역할과 함께 정책을 사용할 수 있습니다. EMR 자세한 내용은 EMRStudio 서비스 역할을 생성하십시오. 단원을 참조하십시오.

{ "Version":"2012-10-17", "Statement":[ { "Sid":"AllowEMRBasicActions", "Action":[ "elasticmapreduce:CreateEditor", "elasticmapreduce:DescribeEditor", "elasticmapreduce:ListEditors", "elasticmapreduce:StartEditor", "elasticmapreduce:StopEditor", "elasticmapreduce:DeleteEditor", "elasticmapreduce:OpenEditorInConsole", "elasticmapreduce:AttachEditor", "elasticmapreduce:DetachEditor", "elasticmapreduce:CreateRepository", "elasticmapreduce:DescribeRepository", "elasticmapreduce:DeleteRepository", "elasticmapreduce:ListRepositories", "elasticmapreduce:LinkRepository", "elasticmapreduce:UnlinkRepository", "elasticmapreduce:DescribeCluster", "elasticmapreduce:ListInstanceGroups", "elasticmapreduce:ListBootstrapActions", "elasticmapreduce:ListClusters", "elasticmapreduce:ListSteps", "elasticmapreduce:CreatePersistentAppUI", "elasticmapreduce:DescribePersistentAppUI", "elasticmapreduce:GetPersistentAppUIPresignedURL", "elasticmapreduce:GetOnClusterAppUIPresignedURL" ], "Resource":"*", "Effect":"Allow" }, { "Sid":"AllowEMRContainersBasicActions", "Action":[ "emr-containers:DescribeVirtualCluster", "emr-containers:ListVirtualClusters", "emr-containers:DescribeManagedEndpoint", "emr-containers:ListManagedEndpoints", "emr-containers:DescribeJobRun", "emr-containers:ListJobRuns" ], "Resource":"*", "Effect":"Allow" }, { "Sid": "AllowRetrievingManagedEndpointCredentials", "Effect": "Allow", "Action": [ "emr-containers:GetManagedEndpointSessionCredentials" ], "Resource": [ "arn:aws:emr-containers:<region>:<account-id>:/virtualclusters/<virtual-cluster-id>/endpoints/<managed-endpoint-id>" ], "Condition": { "StringEquals": { "emr-containers:ExecutionRoleArn": [ "arn:aws:iam::<account-id>:role/<emr-on-eks-execution-role>" ] } } }, { "Sid":"AllowSecretManagerListSecrets", "Action":[ "secretsmanager:ListSecrets" ], "Resource":"*", "Effect":"Allow" }, { "Sid":"AllowSecretCreationWithEMRTagsAndEMRStudioPrefix", "Effect":"Allow", "Action":"secretsmanager:CreateSecret", "Resource":"arn:aws:secretsmanager:*:*:secret:emr-studio-*", "Condition":{ "StringEquals":{ "aws:RequestTag/for-use-with-amazon-emr-managed-policies":"true" } } }, { "Sid":"AllowAddingTagsOnSecretsWithEMRStudioPrefix", "Effect":"Allow", "Action":"secretsmanager:TagResource", "Resource":"arn:aws:secretsmanager:*:*:secret:emr-studio-*" }, { "Sid":"AllowClusterTemplateRelatedIntermediateActions", "Action":[ "servicecatalog:DescribeProduct", "servicecatalog:DescribeProductView", "servicecatalog:DescribeProvisioningParameters", "servicecatalog:ProvisionProduct", "servicecatalog:SearchProducts", "servicecatalog:UpdateProvisionedProduct", "servicecatalog:ListProvisioningArtifacts", "servicecatalog:ListLaunchPaths", "servicecatalog:DescribeRecord", "cloudformation:DescribeStackResources" ], "Resource":"*", "Effect":"Allow" }, { "Sid":"AllowPassingServiceRoleForWorkspaceCreation", "Action":"iam:PassRole", "Resource":[ "arn:aws:iam::*:role/<your-emr-studio-service-role>" ], "Effect":"Allow" }, { "Sid":"AllowS3ListAndLocationPermissions", "Action":[ "s3:ListAllMyBuckets", "s3:ListBucket", "s3:GetBucketLocation" ], "Resource":"arn:aws:s3:::*", "Effect":"Allow" }, { "Sid":"AllowS3ReadOnlyAccessToLogs", "Action":[ "s3:GetObject" ], "Resource":[ "arn:aws:s3:::aws-logs-<aws-account-id>-<region>/elasticmapreduce/*" ], "Effect":"Allow" }, { "Sid":"AllowConfigurationForWorkspaceCollaboration", "Action":[ "elasticmapreduce:UpdateEditor", "elasticmapreduce:PutWorkspaceAccess", "elasticmapreduce:DeleteWorkspaceAccess", "elasticmapreduce:ListWorkspaceAccessIdentities" ], "Resource":"*", "Effect":"Allow", "Condition":{ "StringEquals":{ "elasticmapreduce:ResourceTag/creatorUserId":"${aws:userId}" } } }, { "Sid":"DescribeNetwork", "Effect":"Allow", "Action":[ "ec2:DescribeVpcs", "ec2:DescribeSubnets", "ec2:DescribeSecurityGroups" ], "Resource":"*" }, { "Sid":"ListIAMRoles", "Effect":"Allow", "Action":[ "iam:ListRoles" ], "Resource":"*" }, { "Sid": "AllowServerlessActions", "Action": [ "emr-serverless:CreateApplication", "emr-serverless:UpdateApplication", "emr-serverless:DeleteApplication", "emr-serverless:ListApplications", "emr-serverless:GetApplication", "emr-serverless:StartApplication", "emr-serverless:StopApplication", "emr-serverless:StartJobRun", "emr-serverless:CancelJobRun", "emr-serverless:ListJobRuns", "emr-serverless:GetJobRun", "emr-serverless:GetDashboardForJobRun", "emr-serverless:AccessInteractiveEndpoints" ], "Resource": "*", "Effect": "Allow" }, { "Sid": "AllowPassingRuntimeRoleForRunningServerlessJob", "Action": "iam:PassRole", "Resource": "arn:aws:iam::*:role/serverless-runtime-role", "Effect": "Allow" } ] }

다음 고급 사용자 정책은 모든 EMR Studio 작업을 허용하며, 사용자는 클러스터 템플릿을 사용하거나 EMR 클러스터 구성을 제공하여 새 Amazon 클러스터를 생성할 수 있습니다.

중요

예제 정책에는 IAM 인증 모드를 사용할 때 사용자에게 허용해야 하는 CreateStudioPresignedUrl 권한이 포함되어 있지 않습니다. 자세한 내용은 EMR스튜디오에 사용자 또는 그룹 배정 단원을 참조하십시오.

예제 정책에는 태그 기반 액세스 제어 (TBAC) 를 적용하는 Condition 요소가 포함되어 있으므로 Studio의 예제 서비스 역할과 함께 정책을 사용할 수 있습니다. EMR 자세한 내용은 EMRStudio 서비스 역할을 생성하십시오. 단원을 참조하십시오.

{ "Version":"2012-10-17", "Statement":[ { "Sid":"AllowEMRBasicActions", "Action":[ "elasticmapreduce:CreateEditor", "elasticmapreduce:DescribeEditor", "elasticmapreduce:ListEditors", "elasticmapreduce:StartEditor", "elasticmapreduce:StopEditor", "elasticmapreduce:DeleteEditor", "elasticmapreduce:OpenEditorInConsole", "elasticmapreduce:AttachEditor", "elasticmapreduce:DetachEditor", "elasticmapreduce:CreateRepository", "elasticmapreduce:DescribeRepository", "elasticmapreduce:DeleteRepository", "elasticmapreduce:ListRepositories", "elasticmapreduce:LinkRepository", "elasticmapreduce:UnlinkRepository", "elasticmapreduce:DescribeCluster", "elasticmapreduce:ListInstanceGroups", "elasticmapreduce:ListBootstrapActions", "elasticmapreduce:ListClusters", "elasticmapreduce:ListSteps", "elasticmapreduce:CreatePersistentAppUI", "elasticmapreduce:DescribePersistentAppUI", "elasticmapreduce:GetPersistentAppUIPresignedURL", "elasticmapreduce:GetOnClusterAppUIPresignedURL" ], "Resource":"*", "Effect":"Allow" }, { "Sid":"AllowEMRContainersBasicActions", "Action":[ "emr-containers:DescribeVirtualCluster", "emr-containers:ListVirtualClusters", "emr-containers:DescribeManagedEndpoint", "emr-containers:ListManagedEndpoints", "emr-containers:DescribeJobRun", "emr-containers:ListJobRuns" ], "Resource":"*", "Effect":"Allow" }, { "Sid": "AllowRetrievingManagedEndpointCredentials", "Effect": "Allow", "Action": [ "emr-containers:GetManagedEndpointSessionCredentials" ], "Resource": [ "arn:aws:emr-containers:<region>:<account-id>:/virtualclusters/<virtual-cluster-id>/endpoints/<managed-endpoint-id>" ], "Condition": { "StringEquals": { "emr-containers:ExecutionRoleArn": [ "arn:aws:iam::<account-id>:role/<emr-on-eks-execution-role>" ] } } }, { "Sid":"AllowSecretManagerListSecrets", "Action":[ "secretsmanager:ListSecrets" ], "Resource":"*", "Effect":"Allow" }, { "Sid":"AllowSecretCreationWithEMRTagsAndEMRStudioPrefix", "Effect":"Allow", "Action":"secretsmanager:CreateSecret", "Resource":"arn:aws:secretsmanager:*:*:secret:emr-studio-*", "Condition":{ "StringEquals":{ "aws:RequestTag/for-use-with-amazon-emr-managed-policies":"true" } } }, { "Sid":"AllowAddingTagsOnSecretsWithEMRStudioPrefix", "Effect":"Allow", "Action":"secretsmanager:TagResource", "Resource":"arn:aws:secretsmanager:*:*:secret:emr-studio-*" }, { "Sid":"AllowClusterTemplateRelatedIntermediateActions", "Action":[ "servicecatalog:DescribeProduct", "servicecatalog:DescribeProductView", "servicecatalog:DescribeProvisioningParameters", "servicecatalog:ProvisionProduct", "servicecatalog:SearchProducts", "servicecatalog:UpdateProvisionedProduct", "servicecatalog:ListProvisioningArtifacts", "servicecatalog:ListLaunchPaths", "servicecatalog:DescribeRecord", "cloudformation:DescribeStackResources" ], "Resource":"*", "Effect":"Allow" }, { "Sid":"AllowEMRCreateClusterAdvancedActions", "Action":[ "elasticmapreduce:RunJobFlow" ], "Resource":"*", "Effect":"Allow" }, { "Sid":"AllowPassingServiceRoleForWorkspaceCreation", "Action":"iam:PassRole", "Resource":[ "arn:aws:iam::*:role/<your-emr-studio-service-role>", "arn:aws:iam::*:role/EMR_DefaultRole_V2", "arn:aws:iam::*:role/EMR_EC2_DefaultRole" ], "Effect":"Allow" }, { "Sid":"AllowS3ListAndLocationPermissions", "Action":[ "s3:ListAllMyBuckets", "s3:ListBucket", "s3:GetBucketLocation" ], "Resource":"arn:aws:s3:::*", "Effect":"Allow" }, { "Sid":"AllowS3ReadOnlyAccessToLogs", "Action":[ "s3:GetObject" ], "Resource":[ "arn:aws:s3:::aws-logs-<aws-account-id>-<region>/elasticmapreduce/*" ], "Effect":"Allow" }, { "Sid":"AllowConfigurationForWorkspaceCollaboration", "Action":[ "elasticmapreduce:UpdateEditor", "elasticmapreduce:PutWorkspaceAccess", "elasticmapreduce:DeleteWorkspaceAccess", "elasticmapreduce:ListWorkspaceAccessIdentities" ], "Resource":"*", "Effect":"Allow", "Condition":{ "StringEquals":{ "elasticmapreduce:ResourceTag/creatorUserId":"${aws:userId}" } } }, { "Sid" : "SageMakerDataWranglerForEMRStudio", "Effect" : "Allow", "Action" : [ "sagemaker:CreatePresignedDomainUrl", "sagemaker:DescribeDomain", "sagemaker:ListDomains", "sagemaker:ListUserProfiles" ], "Resource":"*" }, { "Sid":"DescribeNetwork", "Effect":"Allow", "Action":[ "ec2:DescribeVpcs", "ec2:DescribeSubnets", "ec2:DescribeSecurityGroups" ], "Resource":"*" }, { "Sid":"ListIAMRoles", "Effect":"Allow", "Action":[ "iam:ListRoles" ], "Resource":"*" }, { "Sid": "AllowServerlessActions", "Action": [ "emr-serverless:CreateApplication", "emr-serverless:UpdateApplication", "emr-serverless:DeleteApplication", "emr-serverless:ListApplications", "emr-serverless:GetApplication", "emr-serverless:StartApplication", "emr-serverless:StopApplication", "emr-serverless:StartJobRun", "emr-serverless:CancelJobRun", "emr-serverless:ListJobRuns", "emr-serverless:GetJobRun", "emr-serverless:GetDashboardForJobRun", "emr-serverless:AccessInteractiveEndpoints" ], "Resource": "*", "Effect": "Allow" }, { "Sid": "AllowPassingRuntimeRoleForRunningServerlessJob", "Action": "iam:PassRole", "Resource": "arn:aws:iam::*:role/serverless-runtime-role", "Effect": "Allow" }, { "Sid": "AllowCodeWhisperer", "Effect": "Allow", "Action": [ "codewhisperer:GenerateRecommendations" ], "Resource": "*" }, { "Sid": "AllowAthenaSQL", "Action": [ "athena:StartQueryExecution", "athena:StopQueryExecution", "athena:GetQueryExecution", "athena:GetQueryRuntimeStatistics", "athena:GetQueryResults", "athena:ListQueryExecutions", "athena:BatchGetQueryExecution", "athena:GetNamedQuery", "athena:ListNamedQueries", "athena:BatchGetNamedQuery", "athena:UpdateNamedQuery", "athena:DeleteNamedQuery", "athena:ListDataCatalogs", "athena:GetDataCatalog", "athena:ListDatabases", "athena:GetDatabase", "athena:ListTableMetadata", "athena:GetTableMetadata", "athena:ListWorkGroups", "athena:GetWorkGroup", "athena:CreateNamedQuery", "athena:GetPreparedStatement", "glue:CreateDatabase", "glue:DeleteDatabase", "glue:GetDatabase", "glue:GetDatabases", "glue:UpdateDatabase", "glue:CreateTable", "glue:DeleteTable", "glue:BatchDeleteTable", "glue:UpdateTable", "glue:GetTable", "glue:GetTables", "glue:BatchCreatePartition", "glue:CreatePartition", "glue:DeletePartition", "glue:BatchDeletePartition", "glue:UpdatePartition", "glue:GetPartition", "glue:GetPartitions", "glue:BatchGetPartition", "kms:ListAliases", "kms:ListKeys", "kms:DescribeKey", "lakeformation:GetDataAccess", "s3:GetBucketLocation", "s3:GetBucketLocation", "s3:GetObject", "s3:ListBucket", "s3:ListBucketMultipartUploads", "s3:ListMultipartUploadParts", "s3:AbortMultipartUpload", "s3:PutObject", "s3:PutBucketPublicAccessBlock", "s3:ListAllMyBuckets" ], "Resource": "*", "Effect": "Allow" } ] }

다음 사용자 정책에는 Studio Workspaces와 함께 EMR EMR 서버리스 대화형 응용 프로그램을 사용하는 데 필요한 최소 사용자 권한이 포함되어 있습니다.

EMRStudio를 EMR 사용하는 서버리스 대화형 애플리케이션에 대한 사용자 권한이 있는 이 예제 정책에서는 다음과 같은 플레이스홀더를 교체하십시오.serverless-runtime-role 그리고 emr-studio-service-role 올바른 EMRStudio 서비스 역할과 EMR 서버리스 런타임 역할을 사용하십시오.

{ "Version": "2012-10-17", "Statement": [ { "Sid": "AllowServerlessActions", "Action": [ "emr-serverless:CreateApplication", "emr-serverless:UpdateApplication", "emr-serverless:DeleteApplication", "emr-serverless:ListApplications", "emr-serverless:GetApplication", "emr-serverless:StartApplication", "emr-serverless:StopApplication", "emr-serverless:StartJobRun", "emr-serverless:CancelJobRun", "emr-serverless:ListJobRuns", "emr-serverless:GetJobRun", "emr-serverless:GetDashboardForJobRun", "emr-serverless:AccessInteractiveEndpoints" ], "Resource": "*", "Effect": "Allow" }, { "Sid": "AllowEMRBasicActions", "Action": [ "elasticmapreduce:CreateEditor", "elasticmapreduce:DescribeEditor", "elasticmapreduce:ListEditors", "elasticmapreduce:UpdateStudio", "elasticmapreduce:StartEditor", "elasticmapreduce:StopEditor", "elasticmapreduce:DeleteEditor", "elasticmapreduce:OpenEditorInConsole", "elasticmapreduce:AttachEditor", "elasticmapreduce:DetachEditor", "elasticmapreduce:CreateStudio", "elasticmapreduce:DescribeStudio", "elasticmapreduce:DeleteStudio", "elasticmapreduce:ListStudios", "elasticmapreduce:CreateStudioPresignedUrl" ], "Resource": "*", "Effect": "Allow" }, { "Sid": "AllowPassingRuntimeRoleForRunningEMRServerlessJob", "Action": "iam:PassRole", "Resource": "arn:aws:iam::*:role/serverless-runtime-role", "Effect": "Allow" }, { "Sid": "AllowPassingServiceRoleForWorkspaceCreation", "Action": "iam:PassRole", "Resource": "arn:aws:iam::*:role/emr-studio-service-role", "Effect": "Allow" }, { "Sid": "AllowS3ListAndGetPermissions", "Action": [ "s3:ListAllMyBuckets", "s3:ListBucket", "s3:GetBucketLocation", "s3:GetObject" ], "Resource": "arn:aws:s3:::*", "Effect": "Allow" }, { "Sid":"DescribeNetwork", "Effect":"Allow", "Action":[ "ec2:DescribeVpcs", "ec2:DescribeSubnets", "ec2:DescribeSecurityGroups" ], "Resource":"*" }, { "Sid": "ListIAMRoles", "Effect": "Allow", "Action": [ "iam:ListRoles" ], "Resource": "*" } ] }

AWS Identity and Access Management EMRStudio 사용자의 권한

다음 표에는 사용자가 수행할 수 있는 각 Amazon EMR Studio 작업이 포함되어 있으며 해당 IAM 작업을 수행하는 데 필요한 최소 작업이 나열되어 있습니다. EMRStudio의 IAM 권한 정책 (IAM인증 사용 시) 또는 사용자 역할 세션 정책 (IAMID 센터 인증 사용 시) 에서 이러한 작업을 허용할 수 있습니다.

이 표에는 EMR Studio의 각 예제 권한 정책에 허용된 작업도 표시됩니다. 권한 정책 예제에 대한 자세한 내용은 EMRStudio 사용자를 위한 권한 정책을 생성하십시오. 섹션을 참조하세요.

작업 기본 중급 고급 관련 작업
Workspace 생성 및 삭제
"elasticmapreduce:CreateEditor", "elasticmapreduce:DescribeEditor", "elasticmapreduce:ListEditors", "elasticmapreduce:DeleteEditor"
협업 패널을 보고, Workspace 협업을 활성화하며, 공동 작업자를 추가합니다. 자세한 내용은 WorkSpaces 협업에 대한 소유권 설정을 참조하세요.
"elasticmapreduce:UpdateEditor", "elasticmapreduce:PutWorkspaceAccess", "elasticmapreduce:DeleteWorkspaceAccess", "elasticmapreduce:ListWorkspaceAccessIdentities"
새 EMR 클러스터를 생성할 때는 Studio와 동일한 계정의 Amazon S3 Control 스토리지 버킷 목록을 확인하고, 웹 UI를 사용하여 애플리케이션을 디버깅할 때는 컨테이너 로그에 액세스하십시오.
"s3:ListAllMyBuckets", "s3:ListBucket", "s3:GetBucketLocation", "s3:GetObject"
Workspace에 액세스
"elasticmapreduce:DescribeEditor", "elasticmapreduce:ListEditors", "elasticmapreduce:StartEditor", "elasticmapreduce:StopEditor", "elasticmapreduce:OpenEditorInConsole"
Workspace와 연결된 기존 Amazon EMR 클러스터를 연결 또는 분리합니다.
"elasticmapreduce:AttachEditor", "elasticmapreduce:DetachEditor", "elasticmapreduce:ListClusters", "elasticmapreduce:DescribeCluster", "elasticmapreduce:ListInstanceGroups", "elasticmapreduce:ListBootstrapActions"
EMR클러스터에서 EKS Amazon 연결 또는 분리
"elasticmapreduce:AttachEditor", "elasticmapreduce:DetachEditor", "emr-containers:ListVirtualClusters", "emr-containers:DescribeVirtualCluster", "emr-containers:ListManagedEndpoints", "emr-containers:DescribeManagedEndpoint", "emr-containers:GetManagedEndpointSessionCredentials"
Workspace와 연결된 EMR 서버리스 애플리케이션을 연결 또는 분리합니다. 아니요
"elasticmapreduce:AttachEditor", "elasticmapreduce:DetachEditor", "emr-serverless:GetApplication", "emr-serverless:StartApplication", "emr-serverless:ListApplications", "emr-serverless:GetDashboardForJobRun", "emr-serverless:AccessInteractiveEndpoints", "iam:PassRole"

EMR서버리스 작업 런타임 역할을 전달하려면 PassRole 권한이 필요합니다. 자세한 내용은 Amazon EMR 서버리스 사용 설명서의 Job 런타임 역할을 참조하십시오.

영구 애플리케이션 사용자 EC2 인터페이스가 있는 EMR 작업에서 Amazon 디버깅
"elasticmapreduce:CreatePersistentAppUI", "elasticmapreduce:DescribePersistentAppUI", "elasticmapreduce:GetPersistentAppUIPresignedURL", "elasticmapreduce:ListClusters", "elasticmapreduce:ListSteps", "elasticmapreduce:DescribeCluster", "s3:ListBucket", "s3:GetObject"
클러스터 내 애플리케이션 사용자 인터페이스를 사용하여 EMR EC2 작업에서 Amazon 디버깅
"elasticmapreduce:GetOnClusterAppUIPresignedURL"
Spark 히스토리 서버를 사용하여 EKS 작업 실행 EMR 시 Amazon을 디버깅합니다.
"elasticmapreduce:CreatePersistentAppUI", "elasticmapreduce:DescribePersistentAppUI", "elasticmapreduce:GetPersistentAppUIPresignedURL", "emr-containers:ListVirtualClusters", "emr-containers:DescribeVirtualCluster", "emr-containers:ListJobRuns", "emr-containers:DescribeJobRun", "s3:ListBucket", "s3:GetObject"
Git 리포지토리 생성 및 삭제
"elasticmapreduce:CreateRepository", "elasticmapreduce:DeleteRepository", "elasticmapreduce:ListRepositories", "elasticmapreduce:DescribeRepository", "secretsmanager:CreateSecret", "secretsmanager:ListSecrets", "secretsmanager:TagResource"
Git 리포지토리 연결 또는 연결 해제
"elasticmapreduce:LinkRepository", "elasticmapreduce:UnlinkRepository", "elasticmapreduce:ListRepositories", "elasticmapreduce:DescribeRepository"
사전 정의된 클러스터 템플릿에서 새 클러스터 생성 아니요
"servicecatalog:SearchProducts", "servicecatalog:DescribeProduct", "servicecatalog:DescribeProductView", "servicecatalog:DescribeProvisioningParameters", "servicecatalog:ProvisionProduct", "servicecatalog:UpdateProvisionedProduct", "servicecatalog:ListProvisioningArtifacts", "servicecatalog:DescribeRecord", "servicecatalog:ListLaunchPaths", "cloudformation:DescribeStackResources", "elasticmapreduce:ListClusters", "elasticmapreduce:DescribeCluster"
클러스터 구성을 제공하여 새 클러스터를 생성하세요. 아니요 아니요
"elasticmapreduce:RunJobFlow", "iam:PassRole", "elasticmapreduce:ListClusters", "elasticmapreduce:DescribeCluster"
IAM인증 모드를 사용할 때 Studio에 사용자를 할당하십시오. 아니요 아니요 아니요
"elasticmapreduce:CreateStudioPresignedUrl"
네트워크 객체를 설명합니다.
{ "Version": "2012-10-17", "Statement": [ { "Sid": "DescribeNetwork", "Effect": "Allow", "Action": [ "ec2:DescribeVpcs", "ec2:DescribeSubnets", "ec2:DescribeSecurityGroups" ], "Resource": "*" } ] }
IAM역할을 나열하십시오.
{ "Version": "2012-10-17", "Statement": [ { "Sid": "ListIAMRoles", "Effect": "Allow", "Action": [ "iam:ListRoles" ], "Resource": "*" } ] }
Amazon EMR Studio에서 SageMaker Studio에 연결하고 데이터 랭글러 비주얼 인터페이스를 사용하십시오. 아니요 아니요
"sagemaker:CreatePresignedDomainUrl", "sagemaker:DescribeDomain", "sagemaker:ListDomains", "sagemaker:ListUserProfiles"
CodeWhisperer EMR스튜디오에서 Amazon을 사용하세요. 아니요 아니요
"codewhisperer:GenerateRecommendations"
스튜디오에서 Amazon Athena SQL 에디터에 액세스할 수 있습니다. EMR 이 목록에는 Athena의 모든 기능을 사용하는 데 필요한 일부 권한이 포함되지 않았을 수 있습니다. 대부분의 up-to-date 목록은 Athena 전체 액세스 정책을 참조하십시오. 아니요 아니요
"athena:StartQueryExecution", "athena:StopQueryExecution", "athena:GetQueryExecution", "athena:GetQueryRuntimeStatistics", "athena:GetQueryResults", "athena:ListQueryExecutions", "athena:BatchGetQueryExecution", "athena:GetNamedQuery", "athena:ListNamedQueries", "athena:BatchGetNamedQuery", "athena:UpdateNamedQuery", "athena:DeleteNamedQuery", "athena:ListDataCatalogs", "athena:GetDataCatalog", "athena:ListDatabases", "athena:GetDatabase", "athena:ListTableMetadata", "athena:GetTableMetadata", "athena:ListWorkGroups", "athena:GetWorkGroup", "athena:CreateNamedQuery", "athena:GetPreparedStatement", "glue:CreateDatabase", "glue:DeleteDatabase", "glue:GetDatabase", "glue:GetDatabases", "glue:UpdateDatabase", "glue:CreateTable", "glue:DeleteTable", "glue:BatchDeleteTable", "glue:UpdateTable", "glue:GetTable", "glue:GetTables", "glue:BatchCreatePartition", "glue:CreatePartition", "glue:DeletePartition", "glue:BatchDeletePartition", "glue:UpdatePartition", "glue:GetPartition", "glue:GetPartitions", "glue:BatchGetPartition", "kms:ListAliases", "kms:ListKeys", "kms:DescribeKey", "lakeformation:GetDataAccess", "s3:GetBucketLocation", "s3:GetBucketLocation", "s3:GetObject", "s3:ListBucket", "s3:ListBucketMultipartUploads", "s3:ListMultipartUploadParts", "s3:AbortMultipartUpload", "s3:PutObject", "s3:PutBucketPublicAccessBlock", "s3:ListAllMyBuckets"