This repository was archived by the owner on Jul 16, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 43
NotebookPlatform construct potentially building resources ID with tokens #570
Copy link
Copy link
Open
Labels
emr eksComponents used in EMR on EKS abstractionsComponents used in EMR on EKS abstractionsenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomers
Description
The method addUser() in the NotebookPlatformconstruct is using the identity_name parameter in some resources ID. If the username is a token that is resolved at deploy time, CDK fails.
Here is a typical example that is failing:
notebook_user = iam.User(self, 'NotebookUser', user_name='my-user')
# Notebook to user association
exec_roles = notebook_platform.add_user([ara.NotebookUserOptions(
identity_name=notebook_user.user_name,
notebook_managed_endpoints=[ ara.NotebookManagedEndpointOptions(
emr_on_eks_version= ara.EmrVersion.V6_9,
execution_policy= exec_policy,
managed_endpoint_name="test"
)])
])
Workaround: replace the identity_name value by the actual name you provide to the User construct and add a CDK node dependency between them
notebook_user = iam.User(self, 'NotebookUser', user_name='my-user')
# Notebook to user association
exec_roles = notebook_platform.add_user([ara.NotebookUserOptions(
identity_name='my-user',
notebook_managed_endpoints=[ ara.NotebookManagedEndpointOptions(
emr_on_eks_version= ara.EmrVersion.V6_9,
execution_policy= exec_policy,
managed_endpoint_name="test"
)])
])
# Get the Role created by the notebook platform
exec_role=exec_roles[0]
exec_role.node.add_dependency(notebook_user)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
emr eksComponents used in EMR on EKS abstractionsComponents used in EMR on EKS abstractionsenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomers