few-pillow-1133
03/12/2024, 11:12 AMopts=ResourceOptions(depends_on=[xxx])
seems to be giving a new type of error ``TypeError: Expected opts2 to be a InvokeOptions instance``adventurous-butcher-54166
03/12/2024, 11:37 AMResourceOptions.merge(opts1=x, opts2=y)
somewhere?few-pillow-1133
03/12/2024, 11:49 AMadventurous-butcher-54166
03/12/2024, 11:50 AMfew-pillow-1133
03/12/2024, 11:51 AMlambda args: aws.iam.get_policy_document(
version='2012-10-17',
# version='2008-10-17',
policy_id='PolicyForCloudFrontPrivateContent',
statements=[
aws.iam.GetPolicyDocumentStatementArgs(
sid=1,
effect='Allow',
actions=["s3:GetObject"],
resources=[f'{args[0]}/*'],
principals=[
aws.iam.GetPolicyDocumentStatementPrincipalArgs(
type='AWS',
identifiers=[args[1].iam_arn],
)
]
)
],
opts=ResourceOptions(depends_on=[cf])
)
cf
is CloudFront Resource in this caseadventurous-butcher-54166
03/12/2024, 12:08 PM